[BioPython] build errors. "recompile with -fPIC" Biopython1.30
and CVS, Python2.3, SuSE 9.1, AMD64 . Solution Found
Michiel Jan Laurens de Hoon
mdehoon at ims.u-tokyo.ac.jp
Thu Jan 20 23:23:37 EST 2005
Hi Metzidis,
Thanks for the patch. It seems though that removing the hacks completely would
break compilation under Python 2.2, which is still supported by Biopython. The
problem can be solved more easily by removing lines 201-202 in setup.py:
elif build: # fix for 2.3, only if we are making C++ modules
self.compiler.compiler_so = self.compiler.compiler_cxx
Could you try and see if that fixes the compilation problem on your machine?
Compilation of KDTree is likely to be switched off by default in future versions
of biopython because of recurring compilation problems on various problems, but
it would be nice to fix setup.py as much as possible anyway for people who want
to use it.
--Michiel.
Metzidis Anthony wrote:
> Hello everyone,
>
>
>
> My Biopython (both version 1.30 and CVS) build failed with the error
> "recompile with -fPIC" on the file Bio/KDTree/KDTree.o.
>
>
>
> I'm using BioPython CVS and 1.30, Python 2.3 on SuSE 9.1, AMD64.
>
>
>
> I discovered that the problem was caused by some old hacks in setup.py
> that altered the compilation of some c++ extensions. Those hacks were
> relevant to Python 2.2 (according to the documentation), but conflicted
> with python 2.3
>
>
>
> The solution was to remove those 'hacks'. After that, the build
> proceeded successfully.
>
>
>
> I've attached a patch to the current CVS version of setup.py. It seems
> to apply to biopython 1.30 as well.
>
>
>
> Perhaps one of the developers could integrate the ideas in the patch
> into the code.
>
>
>
> Hope this helps someone!
>
>
>
> Have a great day!
>
>
>
> Best,
>
> Tony
>
>
>
>
>
>
>
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> BioPython mailing list - BioPython at biopython.org
> http://biopython.org/mailman/listinfo/biopython
--
Michiel de Hoon, Assistant Professor
University of Tokyo, Institute of Medical Science
Human Genome Center
4-6-1 Shirokane-dai, Minato-ku
Tokyo 108-8639
Japan
http://bonsai.ims.u-tokyo.ac.jp/~mdehoon
More information about the BioPython
mailing list