Boost logo

Boost Testing :

From: Boris Gubenko (Boris.Gubenko_at_[hidden])
Date: 2005-11-18 23:40:13


Markus,

>
> Strange. Does the generated Makefile contain a target for the bz2
> dynamic lib?
>

No.

> Just to make sure, you did "make install" after making the
> python distro?
>

Yes, but install just moves files, it does not *build* anything.

What, I think, is happening is: bz2 module is based on bz2module.c.The
.c module requires header bzlib.h which is not on the include path --
this header does not come with python distribution, it is part of bzip2
distribution. As a result, bz2 module was not built and autodetecting
script setup.py did not add it as extension. From the script:

        # Gustavo Niemeyer's bz2 module.
        if (self.compiler.find_library_file(lib_dirs, 'bz2')):
            exts.append( Extension('bz2', ['bz2module.c'],
                                   libraries = ['bz2']) )

I'll check this theory on Monday by putting bzlib.h on the include path
(cannot log onto testdrive machine now). If configure still does not
add bz2module.c to the makefile, I'll try to add it to Modules/Setup.

Thanks for the help,
  Boris

----- Original Message -----
From: "Markus Schöpflin" <markus.schoepflin_at_[hidden]>
To: <boost-testing_at_[hidden]>
Sent: Friday, November 18, 2005 5:40 PM
Subject: Re: [Boost-testing] "bz2 module is not available" error
fromregression.py

> Boris Gubenko <Boris.Gubenko <at> hp.com> writes:
>
>>
>> Hi, Markus
>>
>> >
>> > Did you scan the python build log for anything suspicious concerning
>> > the
>> > bz2 module? It comes with python since 2.3, IIRC.
>> >
>>
>> Nothing suspicious.
>
> Strange. Does the generated Makefile contain a target for the bz2 dynamic
> lib?
>
>>
>> > What happens when you fire up python and type "import bz2"?
>> >
>>
>> It says: "ImportError: No module named bz2".
>
> Then your python doesn't have the bz2 module.
>
>> This import command does succeed on a Tru64 TestDrive machine you are
>> using, as expected. Your version of python is slightly different than
>> mine: 2.4.1 (yours) vs. 2.4.2 (mine). I will try 2.4.1 release.
>
> I don't think this will help.
>
>> I noticed, that bzip2 is not installed on the system. I've built
>> and installed it. I then rebuilt python with aCC -- did not help.
>> I then rebuilt it with gcc -- did not help.
>>
>> Did you do anything special when building/installing python? Like I
>> said in the previous mail, I just did 'configure "CC=aCC"' followed
>> by 'make'. And with gcc, I did 'configure "CC=gcc" "CXX=gcc"' Did you
>> do something different?
>
> Not that I could remember but I'll have to check on Monday to be sure.
>
>>
>> This is what 'find . -name "bz2*"' reports on my system:
>>
>> ./Lib/encodings/bz2_codec.py
>> ./Modules/bz2module.c
>> ./PC/VC6/bz2.dsp
>> ./PCbuild/bz2.vcproj
>
> This was from the python source dir? Are there any build results anywhere?
>
>> This is what it reports on your system:
>>
>> ./lib/python2.4/encodings/bz2_codec.py
>> ./lib/python2.4/encodings/bz2_codec.pyc
>> ./lib/python2.4/encodings/bz2_codec.pyo
>
> The following is the dynamic library that implements the bz2
> functionality. If
> you don't have this, it won't work.
>
>> ./lib/python2.4/lib-dynload/bz2.so
>
> And this from the python install dir I guess, so it doesn't exactly make
> sense
> to compare those. Just to make sure, you did "make install" after making
> the
> python distro?
>
>>
>> Does it shed any light?
>>
>
> Not really, sorry. Need more input. ;-)
>
>> Thanks,
>> Boris
>
> You're welcome!
>
> Markus
>
>
> _______________________________________________
> Boost-Testing mailing list
> Boost-Testing_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-testing
>
>


Boost-testing list run by mbergal at meta-comm.com