Bugzilla – Bug 658
python bindings do not build for gcc-4.4.0
Last modified: 2009-08-30 01:04:08 UTC
Python bindings do not build for gcc-4.4.0 (Fedora Core 11): [615/707] cxx: build/debug/bindings/python/ns3module.cc -> build/debug/bindings/python/ns3module_3.o [616/707] cxx: bindings/python/ns3module_helpers.cc -> build/debug/bindings/python/ns3module_helpers_3.o In file included from /usr/include/python2.6/pyconfig.h:4, from /usr/include/python2.6/Python.h:8, from debug/bindings/python/ns3module.h:3, from ../bindings/python/ns3module_helpers.cc:2: /usr/include/python2.6/pyconfig-32.h:1022:1: error: "_POSIX_C_SOURCE" redefined In file included from /usr/include/stdint.h:26, from debug/ns3/ref-count-base.h:26, from ../bindings/python/ns3module_helpers.cc:1: /usr/include/features.h:158:1: error: this is the location of the previous definition In file included from /usr/include/python2.6/pyconfig.h:4, from /usr/include/python2.6/Python.h:8, from debug/bindings/python/ns3module.h:3, from ../bindings/python/ns3module_helpers.cc:2: /usr/include/python2.6/pyconfig-32.h:1031:1: error: "_XOPEN_SOURCE" redefined In file included from /usr/include/stdint.h:26, from debug/ns3/ref-count-base.h:26, from ../bindings/python/ns3module_helpers.cc:1: /usr/include/features.h:160:1: error: this is the location of the previous definition Waf: Leaving directory `/tmp/ns-3-allinone/ns-3-dev/build' Build failed -> task failed (err #1): {task: cxx ns3module_helpers.cc -> ns3module_helpers_3.o}
Created attachment 551 [details] the gcc can't build helper.cc
Apparently, all you have to do is switch the order of the 2 #include lines at the top of ns-3.5/bindings/python/ns3module_helpers.cc to fix this.
this was previously fixed but not closed