Marco, Your problem may comes from the compiler used to build pythonOCC. You should try to add the following lines at the top of the environment.py script:
os.environ['CC'] = 'g++' os.environ['CPP'] = 'g++' This tells distutils to use the 'g++' compiler/linker rather than 'gcc'. I successfully tested this tweak on my Ubuntu 8.04 system. Thomas Nawijn, M. a écrit : > Dear all, > > After about 4 hours of frustration I give up for today with building > pythonOCC on Fedora 9. The error messages direct me into places (architecture > specific compiler directories) were I do not want to go. I am almost sure the > problem is trivial (like a missing/wrong pre-processor -DDefine), but I > cannot figure it out. > > Time to take a break and build a minimalistic SWIG wrapper from scratch. > > For the brave, I copied the start of the error message below. The compiler is > complaining about "stdexcept" include file. The file actually exists on my > system, but if I add a proper "-I/foo/bar" the trouble gets bigger and bigger > taking me deeper into the guts of the gcc compiler. I can compile a trivial > OCC C++ source file without any problem, so I guess there is nothing > fundamentally wrong. > > Any ideas? Did anybody successfully compile with gcc-4.X.X on a 64 bit system? > > My settings: > - Linux mercury 2.6.27.5-41.fc9.x86_64 #1 SMP > - pythonOCC (latest from SVN) > - gcc 4.3.0 > - GCC-XML version 0.9.0 > - pyplusplus 1.0.0 > - pygccxml 1.0.0 > > > Regards, > > Marco > > > > > Building pythonOCC 20081125 > === Processing module Standard_Type === > 1 headers parsed by GCCXML > INFO Parsing source file "Wrapper.hxx" ... > INFO gccxml cmd: /usr/local/bin/gccxml -I"." -I"/opt/occ/inc" > -D"HAVE_CONFIG_H" -D"HAVE_LIMITS_H" -D"CSFDB" -D"OCC_CONVERT_SIGNALS" -D"LIN" > -D"LININTEL" -D"_GNU_SOURCE=1" "Wrapper.hxx" -fxml="/tmp/tmp6FoUkB.xml" > INFO GCCXML version - 0.9 > /usr/lib/python2.5/site-packages/pygccxml/parser/scanner.py:337: UserWarning: > unable to find out array size from expression "" > warnings.warn( msg ) > No handles defined. > ####### class Standard_Type ########## > Inherits from Standard_Transient > ####### class Standard_Transient ########## > Standard_Type > ### Member functions for class Standard_Transient ### > operator new method not exportable > operator new method not exportable > operator delete method not exportable > Standard_Transient added. > Standard_Transient added. > ~Standard_Transient added. > Delete added. > HashCode added. > ShallowDump added. > DynamicType added. > IsInstance added. > IsInstance added. > IsKind added. > IsKind added. > This added. > GetRefCount added. > ### Member functions for class Standard_Type ### > operator= method not exportable > Standard_Type added. > Name added. > Size added. > Standard_Type added. > Standard_Type added. > Standard_Type added. > Standard_Type added. > SubType added. > SubType added. > IsImported added. > IsPrimitive added. > IsEnumeration added. > IsClass added. > NumberOfParent added. > NumberOfAncestor added. > ShallowDump added. > ShallowDump added. > Print added. > operator<< method not exportable > DynamicType added. > ~Standard_Type added. > running build > running build_ext > building '_OCC' extension > swigging ./SWIG_src/OCC.i to ./SWIG_src/OCC_wrap.c > swig -python -fcompact -c++ -DHAVE_LIMITS_H -DHAVE_CONFIG_H -DCSFDB > -DOCC_CONVERT_SIGNALS -DLIN -DLININTEL -D_GNU_SOURCE=1 -o > ./SWIG_src/OCC_wrap.c ./SWIG_src/OCC.i > gcc -pthread -fno-strict-aliasing -DNDEBUG -O2 -g -pipe -Wall > -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector > --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fPIC > -I/opt/occ/inc -I./Visualization -I/usr/include/python2.5 -c > ./SWIG_src/OCC_wrap.c -o build/temp.linux-x86_64-2.5/./SWIG_src/OCC_wrap.o -O0 > ./SWIG_src/OCC_wrap.c:2532:21: error: stdexcept: No such file or directory > ******************************************************************************************************* > The NLR disclaimer (http://www.nlr.nl/emaildisclaimer) is valid for NLR > e-mail messages. > ******************************************************************************************************* > > > _______________________________________________ > Minerva-pythonocc mailing list > Minerva-pythonocc@gna.org > https://mail.gna.org/listinfo/minerva-pythonocc > > _______________________________________________ Minerva-pythonocc mailing list Minerva-pythonocc@gna.org https://mail.gna.org/listinfo/minerva-pythonocc