Hi everyone,
I'm having trouble installing Cantera on a 64 bit ubuntu machine.
I understand that the error might have to do with adding the -fPIC
option in the make files. I added that option in preconfig file,
and that took care of quite a few errors I was getting. I feel
that the current message might have to do with similar changes to
the make files for the sundials package. But, I'm not sure and in
any case, I'm not sure where to make the changes.
I'd appreciate your help.
Regards,
Bhupinder
Here's the error message:
singh@bsingh-desktop:~/BHUPI/software/cantera-1.7/cantera-1.7.0/Cantera/python$
sudo make
touch src/pycantera.cpp
(CXX="g++"; export CXX; CC="g++"; export CC; /usr/bin/python2.5
setup.py build)
running build
running build_py
running build_ext
building 'Cantera._cantera' extension
creating build/temp.linux-x86_64-2.5
creating build/temp.linux-x86_64-2.5/src
g++ -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall
-Wstrict-prototypes -fPIC -I../../build/include -Isrc
-I../clib/src -I/usr/include/python2.5 -c src/pycantera.cpp -o
build/temp.linux-x86_64-2.5/src/pycantera.o
cc1plus: warning: command line option "-Wstrict-prototypes" is
valid for Ada/C/ObjC but not for C++
src/pycantera.cpp: In function ???void init_cantera()???:
src/pycantera.cpp:89: warning: deprecated conversion from string
constant to ???char*???
g++ -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions
build/temp.linux-x86_64-2.5/src/pycantera.o
-L/home/bsingh/BHUPI/software/cantera-1.7/cantera-1.7.0/build/lib/x86_64-unknown\
-linux-gnu
-L/home/bsingh/BHUPI/software/cantera-1.7/cantera-1.7.0/build/lib/x86_64-unknown\
-linux-gnu
-L/home/bsingh/sundials/lib -lclib -lzeroD -loneD -ltransport
-lcantera -lconverters -lctlapack -lctblas -lsundials_cvodes
-lsundials_nvecserial -lctmath -ltpx -lctf2c -lctf2c -lm -l-fPIC
-o build/lib.linux-x86_64-2.5/Cantera/_cantera.so
/usr/bin/ld: /usr/local/lib/libsundials_cvodes.a(cvodes.o):
relocation R_X86_64_32 against `a local symbol' can not be used
when making a shared object; recompile with -fPIC
/usr/local/lib/libsundials_cvodes.a: could not read symbols: Bad
value
collect2: ld returned 1 exit status
error: command 'g++' failed with exit status 1
make: *** [_build] Error 1
bsingh@bsingh-desktop:~/BHUPI/software/cantera-1.7/cantera-1.7.0/Cantera/python$
sudo chmod 777 Makefile
--------------
Changes that I had to make to get rid of some errors:
1. added
#include <stdlib.h>
to stringUtils.h
in
/home/bsingh/BHUPI/software/cantera-1.7/cantera-1.7.0/Cantera/src
2. added
#include<string.h>
to ctml.h
in
/home/bsingh/BHUPI/software/cantera-1.7/cantera-1.7.0/Cantera/src
3. Modified (added -fPIC options)
preconfig
in /home/bsingh/BHUPI/software/cantera-1.7/cantera-1.7.0
# C++ compiler flags
CXXFLAGS=${CXXFLAGS:="-O3 -Wall -fPIC"}
FFLAGS=${FFLAGS:='-O -fPIC'}
-------------------------
On Wed Jan 09 10:29:57 EST 2008, Dave Goodwin
<dgoodwin@...> wrote:
> try this: edit file "setup.py" in Cantera/python, and comment out
> the "try" and "except" statements, and the body of the "except"
> block. Then run it again. You'll still get the error, but
> you'll get a more detailed error message that hopefully reveals
> what the problem is.
>
> Dave
>
>
> On Jan 9, 2008, at 6:44 AM, scheskis wrote:
>
>> I am trying to install cantera (last CVS update) on SUSE 10.3
>> 64bit.
>> "Make" command finished with the following error:
>> ...
>> running build
>> running build_py
>> running build_ext
>> setup.py:108: DeprecationWarning: raising a string exception is
>> deprecated
>> raise 'Error encountered while building or installing the
>> Cantera
>> python modules!'
>> Traceback (most recent call last):
>> File "setup.py", line 108, in <module>
>> raise 'Error encountered while building or installing the
>> Cantera
>> python modules!'
>> Error encountered while building or installing the Cantera
>> python modules!
>> make[1]: *** [_build] Error 1
>> make[1]: Leaving directory
>> `/home/sergey/src/cantera_1/cantera/Cantera/python'
>> make: *** [python] Error 2.
>>
>> I would appreciate any help. May be somebody can advice how to
>> debug
>> this error.
>>
>> Thanks
>> Sergey Cheskis.
>>
>>
>>
>>
>>
>> Yahoo! Groups Links
>>
>>
>>
>
>
--
Bhupinder Singh
Department of Mechanical and Aerospace Engineering
University of Florida
Gainesville
Ph: 352-392-4442 (O)
352-328-4486 (Cell)