Bugzilla – Bug 1130
'-fpermissive' should be added to CFLAGS while configuring ns-3.7
Last modified: 2011-08-09 16:17:45 UTC
It fails with the following error: ../src/devices/mesh/mesh-wifi-interface-mac.cc:695:37: error: cannot call constructor 'ns3::MeshWifiInterfaceMac::Statistics::Statistics' directly ../src/devices/mesh/mesh-wifi-interface-mac.cc:695:37: error: for a function-style cast, remove the redundant '::Statistics' ------------------------------------------------------------------------ System info: ~/repos/ns-3-allinone/ns-3.7$ gcc --version gcc (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2 ~/repos/ns-3-allinone/ns-3.7$ uname -a Linux Arrakis 2.6.38-9-generic #43-Ubuntu SMP Thu Apr 28 15:25:15 UTC 2011 i686 i686 i386 GNU/Linux ------------------------------------------------------------------------ Also, I am not sure whether it fits with 'mesh' module, or in the 'general' category. I am supposing this is an issue with gcc versions, which will probably apply to the whole package. ~ musically_ut
The compiler errors goes away if '-fpermissive' is passed in CXXFLAGS to waf. This is a compiler version issue.
Which build has failed (debug, optimized, release), and could you send me what ./waf configure has shown?
(In reply to comment #2) > Which build has failed (debug, optimized, release), and could you send me what > ./waf configure has shown? It was the release build (I think), obtained by: $ ./download.py -n ns-3.7 Also, $ ./waf configure Checking for program g++,c++ : ok /usr/bin/g++ Checking for program cpp : ok /usr/bin/cpp Checking for program ar : ok /usr/bin/ar Checking for program ranlib : ok /usr/bin/ranlib Checking for g++ : ok ... ---- Summary of optional NS-3 features: Threading Primitives : enabled Real Time Simulator : enabled Emulated Net Device : enabled Tap Bridge : enabled GtkConfigStore : not enabled (library 'gtk+-2.0 >= 2.12' not found) XmlIo : enabled SQlite stats data output : not enabled (library 'sqlite3' not found) Network Simulation Cradle : enabled Python Bindings : not enabled (PyBindGen version not correct and newer version could not be retrieved) Use sudo to set suid bit : not enabled (option --enable-sudo not selected) Build examples and samples : enabled Static build : not enabled (option --enable-static not selected) GNU Scientific Library (GSL) : not enabled (GSL not found) 'configure' finished successfully (6.758s) ------ Hope that helps. Should I paste the entire summary here? ~ Utkarsh.
Did you try ns-3.11 (or 3.10, where there is no modular build)? If it works, I will close this bug. I have seen that you use ns-3.7 just now
The other versions compile without this problem. I think this bug can be closed safely if '-fpermissive' is added to CFLAGS while configuring ns-3.7.
closing as we no longer support ns-3.7