./build.py --enable-examples --enable-tests error

2,442 views
Skip to first unread message

Since R

unread,
Dec 21, 2016, 4:59:21 PM12/21/16
to ns-3-users
Build failed
 -> task in 'ns3-test-test' failed (exit status 4):
    {task 140331545416656: cxx traced-callback-typedef-test-suite.cc -> traced-callback-typedef-test-suite.cc.4.o}
['/usr/bin/g++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-std=c++11', '-Wno-error=deprecated-declarations', '-fstrict-aliasing', '-Wstrict-aliasing', '-I../src/test', '-fPIC', '-pthread', '-pthread', '-I.', '-I..', '-I/usr/include/gtk-2.0', '-I/usr/lib/x86_64-linux-gnu/gtk-2.0/include', '-I/usr/include/gio-unix-2.0', '-I/usr/include/cairo', '-I/usr/include/pango-1.0', '-I/usr/include/atk-1.0', '-I/usr/include/pixman-1', '-I/usr/include/libpng12', '-I/usr/include/gdk-pixbuf-2.0', '-I/usr/include/harfbuzz', '-I/usr/include/glib-2.0', '-I/usr/lib/x86_64-linux-gnu/glib-2.0/include', '-I/usr/include/freetype2', '-I/usr/include/libxml2', '-DNS3_BUILD_PROFILE_DEBUG', '-DNS3_ASSERT_ENABLE', '-DNS3_LOG_ENABLE', '-DHAVE_SYS_IOCTL_H=1', '-DHAVE_IF_NETS_H=1', '-DHAVE_NET_ETHERNET_H=1', '-DHAVE_PACKET_H=1', '-DHAVE_IF_TUN_H=1', '-DHAVE_GSL=1', '-DHAVE_SQLITE3=1', '-DHAVE_GTK2=1', '-DHAVE_LIBXML2=1', '-DNS_TEST_SOURCEDIR="src/test/traced"', '../src/test/traced/traced-callback-typedef-test-suite.cc', '-c', '-o', '/home/sanno/Desktop/ns3/ns-allinone-3.26/ns-3.26/build/src/test/traced/traced-callback-typedef-test-suite.cc.4.o']

Please help. I am trying to build ns3 and getting that error

Tom Henderson

unread,
Dec 21, 2016, 5:11:55 PM12/21/16
to ns-3-...@googlegroups.com
Please tell us a bit more about your system (which OS version are you
using), and whether you modified the code at all.

Please cd into the ./ns-3.26 directory and type:
./waf build -vvv

there to obtain more context around this build error.

- Tom

Ramadhani S. Sinde

unread,
Dec 21, 2016, 5:26:45 PM12/21/16
to ns-3-...@googlegroups.com
I am using Ubuntu 16.04 LTS installed in Vimware;
After typing ./waf build -vvv, I get the following error
 File "./waf", line 165, in <module>
    Scripting.waf_entry_point(cwd, VERSION, wafdir)
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Scripting.py", line 110, in waf_entry_point
    run_commands()
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Scripting.py", line 171, in run_commands
    ctx=run_command(cmd_name)
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Scripting.py", line 162, in run_command
    ctx.execute()
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Scripting.py", line 383, in execute
    return execute_method(self)
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Build.py", line 107, in execute
    self.execute_build()
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Build.py", line 114, in execute_build
    self.compile()
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Tools/errcheck.py", line 126, in check_compile
    ret=self.orig_compile()
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Build.py", line 185, in compile
    raise Errors.BuildError(self.producer.error)
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Errors.py", line 25, in __init__
    WafError.__init__(self,self.format_error())

 
Build failed
 -> task in 'ns3-test-test' failed (exit status 4):
    {task 140130850490448: cxx traced-callback-typedef-test-suite.cc -> traced-callback-typedef-test-suite.cc.4.o}
['/usr/bin/g++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-std=c++11', '-Wno-error=deprecated-declarations', '-fstrict-aliasing', '-Wstrict-aliasing', '-I../src/test', '-fPIC', '-pthread', '-pthread', '-I.', '-I..', '-I/usr/include/gtk-2.0', '-I/usr/lib/x86_64-linux-gnu/gtk-2.0/include', '-I/usr/include/gio-unix-2.0', '-I/usr/include/cairo', '-I/usr/include/pango-1.0', '-I/usr/include/atk-1.0', '-I/usr/include/pixman-1', '-I/usr/include/libpng12', '-I/usr/include/gdk-pixbuf-2.0', '-I/usr/include/harfbuzz', '-I/usr/include/glib-2.0', '-I/usr/lib/x86_64-linux-gnu/glib-2.0/include', '-I/usr/include/freetype2', '-I/usr/include/libxml2', '-DNS3_BUILD_PROFILE_DEBUG', '-DNS3_ASSERT_ENABLE', '-DNS3_LOG_ENABLE', '-DHAVE_SYS_IOCTL_H=1', '-DHAVE_IF_NETS_H=1', '-DHAVE_NET_ETHERNET_H=1', '-DHAVE_PACKET_H=1', '-DHAVE_IF_TUN_H=1', '-DHAVE_GSL=1', '-DHAVE_SQLITE3=1', '-DHAVE_GTK2=1', '-DHAVE_LIBXML2=1', '-DNS_TEST_SOURCEDIR="src/test/traced"', '../src/test/traced/traced-callback-typedef-test-suite.cc', '-c', '-o', '/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/build/src/test/traced/traced-callback-typedef-test-suite.cc.4.o']
  File "./waf", line 165, in <module>
    Scripting.waf_entry_point(cwd, VERSION, wafdir)
  File "/home/sinde/Desktop/ns3/ns-allinone-3.26/ns-3.26/.waf-1.8.19-b1fc8f7baef51bd2db4c2971909a568d/waflib/Scripting.py", line 114, in waf_entry_point
    Logs.error(e.msg)




- Tom

--
Posting to this group should follow these guidelines https://www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting
--- You received this message because you are subscribed to a topic in the Google Groups "ns-3-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ns-3-users/US3TGxCu_Ro/unsubscribe.
To unsubscribe from this group and all its topics, send an email to ns-3-users+unsubscribe@googlegroups.com.
To post to this group, send email to ns-3-...@googlegroups.com.
Visit this group at https://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/d/optout.

Tom Henderson

unread,
Dec 22, 2016, 11:04:18 AM12/22/16
to ns-3-...@googlegroups.com
I was not able to reproduce your problem by taking the following steps
on an Ubuntu 16.04 LTS virtual machine:

$ wget http://www.nsnam.org/release/ns-allinone-3.26.tar.bz2
$ tar xjf ns-allinone-3.26.tar.bz2
$ cd ns-allinone-3.26/
$ ./build.py --enable-examples --enable-tests

ns-3.26 builds successfully for me based on the above.

If you send me (off list) the following file:

ns-3.26/build/config.log

I can have a further look at your configuration.

- Tom

Ramadhani S. Sinde

unread,
Dec 30, 2016, 3:19:22 PM12/30/16
to ns-3-...@googlegroups.com
Hi Tom,

It's me once again I'm writing from Tanzania.

First of all I would like to thank you a lot for your effort and support. Actually you are correct because even myself I followed your steps above and I got no error at all, but that is when I'm using office desktop. When I decided to follow the same procedures on my Macbook Pro installed the Linux 16.04 LTS or 14.04 LTS still I'm getting errors. Actually its very strange even I'm even trying to think may be is not possible to run ns3 on Mac in any how, because I also installed ns3 on my Mac (not on fusion) and it gives the following errors. 

In file included from ../examples/wireless/wifi-tcp.cc:39:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:35:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double DbmToW (double dbm)

                             ^

./ns3/wifi-utils.h:37:10: note: non-constexpr function 'pow' cannot be used in a constant expression

  return std::pow (10.0, dbm / 10.0) / 1000.0;

                   ^

/usr/include/math.h:443:15: note: declared here

extern double pow(double, double);

                       ^

In file included from ../examples/wireless/wifi-tcp.cc:39:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:47:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double DbToRatio (double db)

                             ^

./ns3/wifi-utils.h:49:10: note: non-constexpr function 'pow' cannot be used in a constant expression

  return std::pow (10.0, db / 10.0);

                   ^

/usr/include/math.h:443:15: note: declared here

extern double pow(double, double);

                       ^

In file included from ../examples/wireless/wifi-tcp.cc:39:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:59:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double WToDbm (double w)

                             ^

./ns3/wifi-utils.h:61:17: note: non-constexpr function 'log10' cannot be used in a constant expression

  return 10.0 * std::log10 (w * 1000.0);

                       ^

/usr/include/math.h:391:15: note: declared here

extern double log10(double);

                       ^

In file included from ../examples/wireless/wifi-tcp.cc:39:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:71:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double RatioToDb (double ratio)

                             ^

./ns3/wifi-utils.h:73:17: note: non-constexpr function 'log10' cannot be used in a constant expression

  return 10.0 * std::log10 (ratio);

                       ^

/usr/include/math.h:391:15: note: declared here

extern double log10(double);

                       ^

4 errors generated.


In file included from ../examples/wireless/mixed-bg-network.cc:23:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:35:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double DbmToW (double dbm)

                             ^

./ns3/wifi-utils.h:37:10: note: non-constexpr function 'pow' cannot be used in a constant expression

  return std::pow (10.0, dbm / 10.0) / 1000.0;

                   ^

/usr/include/math.h:443:15: note: declared here

extern double pow(double, double);

                       ^

In file included from ../examples/wireless/mixed-bg-network.cc:23:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:47:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double DbToRatio (double db)

                             ^

./ns3/wifi-utils.h:49:10: note: non-constexpr function 'pow' cannot be used in a constant expression

  return std::pow (10.0, db / 10.0);

                   ^

/usr/include/math.h:443:15: note: declared here

extern double pow(double, double);

                       ^

In file included from ../examples/wireless/mixed-bg-network.cc:23:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:59:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double WToDbm (double w)

                             ^

./ns3/wifi-utils.h:61:17: note: non-constexpr function 'log10' cannot be used in a constant expression

  return 10.0 * std::log10 (w * 1000.0);

                       ^

/usr/include/math.h:391:15: note: declared here

extern double log10(double);

                       ^

In file included from ../examples/wireless/mixed-bg-network.cc:23:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:71:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double RatioToDb (double ratio)

                            ^

./ns3/wifi-utils.h:73:17: note: non-constexpr function 'log10' cannot be used in a constant expression

  return 10.0 * std::log10 (ratio);

                      ^

/usr/include/math.h:391:15: note: declared here

extern double log10(double);

                       ^

4 errors generated.


In file included from ../examples/wireless/wifi-aggregation.cc:23:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:35:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double DbmToW (double dbm)

                            ^

./ns3/wifi-utils.h:37:10: note: non-constexpr function 'pow' cannot be used in a constant expression

  return std::pow (10.0, dbm / 10.0) / 1000.0;

                   ^

/usr/include/math.h:443:15: note: declared here

extern double pow(double, double);

                       ^

In file included from ../examples/wireless/wifi-aggregation.cc:23:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:47:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double DbToRatio (double db)

                             ^

./ns3/wifi-utils.h:49:10: note: non-constexpr function 'pow' cannot be used in a constant expression

  return std::pow (10.0, db / 10.0);

                   ^

/usr/include/math.h:443:15: note: declared here

extern double pow(double, double);

                      ^

In file included from ../examples/wireless/wifi-aggregation.cc:23:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:59:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double WToDbm (double w)

                            ^

./ns3/wifi-utils.h:61:17: note: non-constexpr function 'log10' cannot be used in a constant expression

  return 10.0 * std::log10 (w * 1000.0);

                      ^

/usr/include/math.h:391:15: note: declared here

extern double log10(double);

                       ^

In file included from ../examples/wireless/wifi-aggregation.cc:23:

In file included from ./ns3/wifi-module.h:94:

./ns3/wifi-utils.h:71:18: error: constexpr function never produces a constant expression [-Winvalid-constexpr]

constexpr double RatioToDb (double ratio)

                             ^

./ns3/wifi-utils.h:73:17: note: non-constexpr function 'log10' cannot be used in a constant expression

  return 10.0 * std::log10 (ratio);

                       ^

/usr/include/math.h:391:15: note: declared here

extern double log10(double);

                       ^

4 errors generated.


Waf: Leaving directory `/Users/applemacbooks_tz/repos/ns-3-allinone/ns-3-dev/build'

Build failed

 -> task in 'wifi-tcp' failed (exit status 1): 

{task 4528561552: cxx wifi-tcp.cc -> wifi-tcp.cc.27.o}

['/usr/bin/clang++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-Wno-unused-local-typedefs', '-Wno-potentially-evaluated-expression', '-std=c++11', '-I.', '-I..', '-I/usr/include/libxml2', '-DNS3_BUILD_PROFILE_DEBUG', '-DNS3_ASSERT_ENABLE', '-DNS3_LOG_ENABLE', '-DHAVE_SYS_IOCTL_H=1', '-DHAVE_IF_NETS_H=1', '-DHAVE_NET_ETHERNET_H=1', '-DHAVE_SQLITE3=1', '-DHAVE_LIBXML2=1', '../examples/wireless/wifi-tcp.cc', '-c', '-o', '/Users/applemacbooks_tz/repos/ns-3-allinone/ns-3-dev/build/examples/wireless/wifi-tcp.cc.27.o']

 -> task in 'mixed-bg-network' failed (exit status 1): 

{task 4528560656: cxx mixed-bg-network.cc -> mixed-bg-network.cc.26.o}

['/usr/bin/clang++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-Wno-unused-local-typedefs', '-Wno-potentially-evaluated-expression', '-std=c++11', '-I.', '-I..', '-I/usr/include/libxml2', '-DNS3_BUILD_PROFILE_DEBUG', '-DNS3_ASSERT_ENABLE', '-DNS3_LOG_ENABLE', '-DHAVE_SYS_IOCTL_H=1', '-DHAVE_IF_NETS_H=1', '-DHAVE_NET_ETHERNET_H=1', '-DHAVE_SQLITE3=1', '-DHAVE_LIBXML2=1', '../examples/wireless/mixed-bg-network.cc', '-c', '-o', '/Users/applemacbooks_tz/repos/ns-3-allinone/ns-3-dev/build/examples/wireless/mixed-bg-network.cc.26.o']

 -> task in 'wifi-aggregation' failed (exit status 1): 

{task 4528549584: cxx wifi-aggregation.cc -> wifi-aggregation.cc.23.o}

['/usr/bin/clang++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-Wno-unused-local-typedefs', '-Wno-potentially-evaluated-expression', '-std=c++11', '-I.', '-I..', '-I/usr/include/libxml2', '-DNS3_BUILD_PROFILE_DEBUG', '-DNS3_ASSERT_ENABLE', '-DNS3_LOG_ENABLE', '-DHAVE_SYS_IOCTL_H=1', '-DHAVE_IF_NETS_H=1', '-DHAVE_NET_ETHERNET_H=1', '-DHAVE_SQLITE3=1', '-DHAVE_LIBXML2=1', '../examples/wireless/wifi-aggregation.cc', '-c', '-o', '/Users/applemacbooks_tz/repos/ns-3-allinone/ns-3-dev/build/examples/wireless/wifi-aggregation.cc.23.o']

Traceback (most recent call last):

  File "./build.py", line 171, in <module>

    sys.exit(main(sys.argv))

  File "./build.py", line 162, in main

    build_ns3(config, build_examples, build_tests, args, build_options)

  File "./build.py", line 82, in build_ns3

    run_command([sys.executable, "waf", "build"] + build_options)

  File "/Users/applemacbooks_tz/repos/ns-3-allinone/util.py", line 25, in run_command

    raise CommandError("Command %r exited with code %i" % (argv, retval))

util.CommandError: Command ['/usr/local/opt/python/bin/python2.7', 'waf', 'build'] exited with code 1


Above errors are from MacOS X El-Capitan. I will send you errors when I'm trying to run the same from VMware Fusion (installed Ubuntu 14.04 LTS ns3.25, I decided to go to low version of ns3.25 and Ubuntu 14.04 LTS not the latest one).




- Tom

Errors_From_MacOS.docx

Tom Henderson

unread,
Dec 30, 2016, 3:32:30 PM12/30/16
to ns-3-...@googlegroups.com
On 12/30/2016 12:19 PM, Ramadhani S. Sinde wrote:
> Hi Tom,
>
> It's me once again I'm writing from Tanzania.
>
> First of all I would like to thank you a lot for your effort and
> support. Actually you are correct because even myself I followed your
> steps above and I got no error at all, but that is when I'm using
> office desktop. When I decided to follow the same procedures on my
> Macbook Pro installed the Linux 16.04 LTS or 14.04 LTS still I'm
> getting errors. Actually its very strange even I'm even trying to
> think may be is not possible to run ns3 on Mac in any how, because I
> also installed ns3 on my Mac (not on fusion) and it gives the
> following errors.

You appear to have downloaded ns-3-dev in the past day or so when there
was a problematic commit causing these errors. Please try again with
the latest version.

- Tom

Ramadhani S. Sinde

unread,
Dec 30, 2016, 3:33:24 PM12/30/16
to ns-3-...@googlegroups.com
Following errors when I'm running from UBUNTU installed on Mac

sinde@ubuntu:~/Desktop/ns3/ns-allinone-3.25$ ./build.py --enable-examples --enable-tests
# Build NetAnim
Entering directory `netanim-3.107'
 =>  qmake -v
QMake version 2.01a
Using Qt version 4.8.6 in /usr/lib/x86_64-linux-gnu
qmake found
 =>  qmake NetAnim.pro
 =>  make
make: Nothing to be done for `first'.
Leaving directory `netanim-3.107'
# Building examples (by user request)
# Building tests (by user request)
# Build NS-3
Entering directory `./ns-3.25'
 =>  /usr/bin/python waf configure --enable-examples --enable-tests --with-pybindgen ../pybindgen-0.17.0.post49+ng0e4e3bc
Setting top to                           : /home/sinde/Desktop/ns3/ns-allinone-3.25/ns-3.25 
Setting out to                           : /home/sinde/Desktop/ns3/ns-allinone-3.25/ns-3.25/build 
Checking for 'gcc' (C compiler)          : /usr/bin/gcc 
Checking for cc version                  : 4.8.4 
Checking for 'g++' (C++ compiler)        : /usr/bin/g++ 
Checking for compilation flag -Wl,--soname=foo support : ok 
Checking for program 'python'                          : /usr/bin/python 
Checking for python version                            : (2, 7, 6, 'final', 0) 
python-config                                          : /usr/bin/python-config 
Asking python-config for pyembed '--cflags --libs --ldflags' flags : yes 
Testing pyembed configuration                                      : yes 
Asking python-config for pyext '--cflags --libs --ldflags' flags   : yes 
Testing pyext configuration                                        : yes 
Checking for compilation flag -fvisibility=hidden support          : ok 
Checking for compilation flag -Wno-array-bounds support            : ok 
Checking for pybindgen location                                    : ../pybindgen-0.17.0.post49+ng0e4e3bc (given) 
Checking for python module 'pybindgen'                             : 0.17.0.post49+ng0e4e3bc 
Checking for pybindgen version                                     : 0.17.0.post49+ng0e4e3bc 
Checking for code snippet                                          : yes 
Checking for types uint64_t and unsigned long equivalence          : no 
Checking for code snippet                                          : no 
Checking for types uint64_t and unsigned long long equivalence     : yes 
Checking for the apidefs that can be used for Python bindings      : gcc-LP64 
Checking for internal GCC cxxabi                                   : complete 
Checking for python module 'pygccxml'                              : not found 
Checking boost includes                                            : 1_54 
Checking boost libs                                                : ok 
Checking for boost linkage                                         : ok 
Checking for click location                                        : not found 
Checking for program 'pkg-config'                                  : /usr/bin/pkg-config 
Checking for 'gtk+-2.0' >= 2.12                                    : yes 
Checking for 'libxml-2.0' >= 2.7                                   : yes 
Checking for type uint128_t                                        : not found 
Checking for type __uint128_t                                      : yes 
Checking high precision implementation                             : 128-bit integer (default) 
Checking for header stdint.h                                       : yes 
Checking for header inttypes.h                                     : yes 
Checking for header sys/inttypes.h                                 : not found 
Checking for header sys/types.h                                    : yes 
Checking for header sys/stat.h                                     : yes 
Checking for header dirent.h                                       : yes 
Checking for header stdlib.h                                       : yes 
Checking for header signal.h                                       : yes 
Checking for header pthread.h                                      : yes 
Checking for header stdint.h                                       : yes 
Checking for header inttypes.h                                     : yes 
Checking for header sys/inttypes.h                                 : not found 
Checking for library rt                                            : yes 
Checking for header sys/ioctl.h                                    : yes 
Checking for header net/if.h                                       : yes 
Checking for header net/ethernet.h                                 : yes 
Checking for header linux/if_tun.h                                 : yes 
Checking for header netpacket/packet.h                             : yes 
Checking for NSC location                                          : not found 
Checking for OpenFlow location                                     : not found 
Checking for 'sqlite3'                                             : yes 
Checking for header linux/if_tun.h                                 : yes 
Checking for python module 'gtk'                                   : ok 
Checking for python module 'goocanvas'                             : 0.14.1 
Checking for python module 'pygraphviz'                            : 1.2 
Checking for program 'sudo'                                        : /usr/bin/sudo 
Checking for program 'valgrind'                                    : /usr/bin/valgrind 
Checking for 'gsl'                                                 : yes 
python-config                                                      : not found 
Checking for compilation flag -Wno-error=deprecated-d... support   : ok 
Checking for compilation flag -Wno-error=deprecated-d... support   : ok 
Checking for compilation flag -fstrict-aliasing support            : ok 
Checking for compilation flag -fstrict-aliasing support            : ok 
Checking for compilation flag -Wstrict-aliasing support            : ok 
Checking for compilation flag -Wstrict-aliasing support            : ok 
Checking for program 'doxygen'                                     : /usr/bin/doxygen 
---- Summary of optional NS-3 features:
Build profile                 : debug
Build directory               : 
Python Bindings               : enabled
Python API Scanning Support   : not enabled (Missing 'pygccxml' Python module)
BRITE Integration             : not enabled (BRITE not enabled (see option --with-brite))
NS-3 Click Integration        : not enabled (nsclick not enabled (see option --with-nsclick))
GtkConfigStore                : enabled
XmlIo                         : enabled
Threading Primitives          : enabled
Real Time Simulator           : enabled
File descriptor NetDevice     : enabled
Tap FdNetDevice               : enabled
Emulation FdNetDevice         : enabled
PlanetLab FdNetDevice         : not enabled (PlanetLab operating system not detected (see option --force-planetlab))
Network Simulation Cradle     : not enabled (NSC not found (see option --with-nsc))
MPI Support                   : not enabled (option --enable-mpi not selected)
NS-3 OpenFlow Integration     : not enabled (OpenFlow not enabled (see option --with-openflow))
SQlite stats data output      : enabled
Tap Bridge                    : enabled
PyViz visualizer              : enabled
Use sudo to set suid bit      : not enabled (option --enable-sudo not selected)
Build tests                   : enabled
Build examples                : enabled
GNU Scientific Library (GSL)  : enabled
Gcrypt library                : not enabled (libgcrypt not found: you can use libgcrypt-config to find its location.)
'configure' finished successfully (3.110s)
 =>  /usr/bin/python waf build
Waf: Entering directory `/home/sinde/Desktop/ns3/ns-allinone-3.25/ns-3.25/build'
[2525/2577] Linking build/scratch/subdir/subdir
scratch/subdir/scratch-simulator-subdir.cc.4.o: In function `main':
/home/sinde/Desktop/ns3/ns-allinone-3.25/ns-3.25/build/../scratch/subdir/scratch-simulator-subdir.cc:25: multiple definition of `main'
scratch/subdir/first.cc.4.o:/home/sinde/Desktop/ns3/ns-allinone-3.25/ns-3.25/build/../scratch/subdir/first.cc:29: first defined here
collect2: error: ld returned 1 exit status

Waf: Leaving directory `/home/sinde/Desktop/ns3/ns-allinone-3.25/ns-3.25/build'
Build failed
 -> task in 'subdir' failed (exit status 1): 
{task 140479537241360: cxxprogram first.cc.4.o,scratch-simulator-subdir.cc.4.o -> subdir}
['/usr/bin/g++', '-pthread', '-pthread', 'scratch/subdir/first.cc.4.o', 'scratch/subdir/scratch-simulator-subdir.cc.4.o', '-o', '/home/sinde/Desktop/ns3/ns-allinone-3.25/ns-3.25/build/scratch/subdir/subdir', '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--no-as-needed', '-L.', '-lns3.25-test-debug', '-lns3.25-lr-wpan-debug', '-lns3.25-netanim-debug', '-lns3.25-lte-debug', '-lns3.25-spectrum-debug', '-lns3.25-antenna-debug', '-lns3.25-aodv-debug', '-lns3.25-applications-debug', '-lns3.25-csma-layout-debug', '-lns3.25-dsdv-debug', '-lns3.25-dsr-debug', '-lns3.25-flow-monitor-debug', '-lns3.25-internet-apps-debug', '-lns3.25-mesh-debug', '-lns3.25-wimax-debug', '-lns3.25-nix-vector-routing-debug', '-lns3.25-olsr-debug', '-lns3.25-point-to-point-layout-debug', '-lns3.25-sixlowpan-debug', '-lns3.25-tap-bridge-debug', '-lns3.25-visualizer-debug', '-lns3.25-wave-debug', '-lns3.25-internet-debug', '-lns3.25-bridge-debug', '-lns3.25-point-to-point-debug', '-lns3.25-mpi-debug', '-lns3.25-traffic-control-debug', '-lns3.25-wifi-debug', '-lns3.25-buildings-debug', '-lns3.25-propagation-debug', '-lns3.25-uan-debug', '-lns3.25-mobility-debug', '-lns3.25-energy-debug', '-lns3.25-config-store-debug', '-lns3.25-csma-debug', '-lns3.25-fd-net-device-debug', '-lns3.25-virtual-net-device-debug', '-lns3.25-topology-read-debug', '-lns3.25-network-debug', '-lns3.25-stats-debug', '-lns3.25-core-debug', '-lrt', '-lgsl', '-lgslcblas', '-lm', '-lsqlite3', '-lgtk-x11-2.0', '-lgdk-x11-2.0', '-latk-1.0', '-lgio-2.0', '-lpangoft2-1.0', '-lpangocairo-1.0', '-lgdk_pixbuf-2.0', '-lcairo', '-lpango-1.0', '-lfontconfig', '-lgobject-2.0', '-lglib-2.0', '-lfreetype', '-lxml2']
Traceback (most recent call last):
  File "./build.py", line 171, in <module>
    sys.exit(main(sys.argv))
  File "./build.py", line 162, in main
    build_ns3(config, build_examples, build_tests, args, build_options)
  File "./build.py", line 82, in build_ns3
    run_command([sys.executable, "waf", "build"] + build_options)
  File "/home/sinde/Desktop/ns3/ns-allinone-3.25/util.py", line 25, in run_command
    raise CommandError("Command %r exited with code %i" % (argv, retval))
util.CommandError: Command ['/usr/bin/python', 'waf', 'build'] exited with code 1


I hope you get my point, but remember everything is running smooth on my Windows Desktop, Again this Mac has 8GB of RAM core i5 2.7 GHz Processor.
errors_from_Ubuntu.docx

Tom Henderson

unread,
Dec 30, 2016, 7:36:44 PM12/30/16
to ns-3-...@googlegroups.com
This is a separate error unrelated to the below.

You appear to have copied the tutorial program 'first.cc' into the scratch/subdir/ directory, and the linker is complaining that you have two main() functions in that directory as a result.

You received this message because you are subscribed to the Google Groups "ns-3-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ns-3-users+...@googlegroups.com.

Ramadhani S. Sinde

unread,
Dec 31, 2016, 4:34:26 AM12/31/16
to ns-3-...@googlegroups.com
Thank you very much I removed first.cc file from scratch/subdir and everything is working smoothly. 

One more problem still I don't know how to fix those errors in Mac, although you suggested that I'm using the old version of ns-3-dev and it's better to download the new one. 

I used the following link to download it


where I won't able to change the version of ns-3-dev 

To unsubscribe from this group and stop receiving emails from it, send an email to ns-3-users+unsubscribe@googlegroups.com.

To post to this group, send email to ns-3-...@googlegroups.com.
Visit this group at https://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/d/optout.

Tom Henderson

unread,
Dec 31, 2016, 11:39:53 AM12/31/16
to ns-3-...@googlegroups.com
On 12/31/2016 01:34 AM, Ramadhani S. Sinde wrote:
Thank you very much I removed first.cc file from scratch/subdir and everything is working smoothly. 

One more problem still I don't know how to fix those errors in Mac, although you suggested that I'm using the old version of ns-3-dev and it's better to download the new one. 

I used the following link to download it


where I won't able to change the version of ns-3-dev

cd into the ns-3-dev/ directory and type 'hg pull -u' to update to the tip of the repository

Ramadhani S. Sinde

unread,
Dec 31, 2016, 11:41:56 AM12/31/16
to ns-3-...@googlegroups.com
Thank you very much I'll try this.

Ramadhani S. Sinde

unread,
Dec 31, 2016, 11:55:20 AM12/31/16
to ns-3-...@googlegroups.com
Amazing it's working! Thank you very Much! 

Let me try to run first.cc 

keerthiga shanmugam

unread,
Jan 24, 2018, 5:09:58 AM1/24/18
to ns-3-users
Hi,
please do look at my config.log file too. me too got same build failed error while running examples and tests in ns-3.27 in ubuntu 14.04. I hereby attach my config.log file
config.log

Tommaso Pecorella

unread,
Jan 25, 2018, 12:22:01 AM1/25/18
to ns-3-users
Upgrade to gcc 4.9 (or better).

T.

Ramadhani S. Sinde

unread,
Jun 28, 2018, 5:54:45 PM6/28/18
to ns-3-...@googlegroups.com
Hi Tommaso,

How are you?

I remember to contact you for help on ns3. I got some other challenges (coding errors). Please help.

--
Error.png
Reply all
Reply to author
Forward
0 new messages