ns3-visualizer fails, ns-3.29 will not build (Ubuntu 18.04) (Installed with Bake)

570 views
Skip to first unread message

Shubham Kumar

unread,
Jul 9, 2019, 1:03:38 PM7/9/19
to ns-3-users
Hello!

I've been trying to build ns-3.29 on Ubuntu run on VMware. I followed the instructions step-by-step on https://www.nsnam.org/wiki/Installation#Installation after downloading all pre-requisites. 

Everything was OK when I ran bake.py check.

Upon building (bake.py deploy), the following happened:

Downloading, building and installing the selected modules and dependencies.
Please, be patient, this may take a while!
 >> Searching for system dependency qt - OK
 >> Searching for system dependency g++ - OK
 >> Searching for system dependency setuptools - OK
 >> Searching for system dependency libgoocanvas2 - OK
 >> Searching for system dependency gi-cairo - OK
 >> Searching for system dependency pygobject - OK
 >> Searching for system dependency pygraphviz - OK
 >> Searching for system dependency python-dev - OK
 >> Downloading pybindgen-0.19.0.post4+ng823d8b2 (target directory:pybindgen) - (Nothing to do, source directory already exists) - OK
 >> Downloading netanim-3.108 - (Nothing to do, source directory already exists) - OK
 >> Downloading ns-3.29 - (Nothing to do, source directory already exists) - OK
 >> Building pybindgen-0.19.0.post4+ng823d8b2 - OK
 >> Building netanim-3.108 - OK
 >> Building ns-3.29 - Problem
 > Error:  Critical dependency, module "ns-3.29" failed 
   For more information call Bake with --debug and/or -v, -vvv, for full verbose mode (bake --help)

 Upon running bake.py --debug build -v, the following was outputted:

 >> Building pybindgen-0.19.0.post4+ng823d8b2 -  /usr/bin/python3 --version dir=None
    > mkdir -p /home/ubuntu/build/lib
 /usr/bin/python3 /home/ubuntu/source/pybindgen/setup.py build --build-base=/home/ubuntu/source/pybindgen/objdir dir=/home/ubuntu/source/pybindgen
 /usr/bin/python3 /home/ubuntu/source/pybindgen/setup.py install --install-base=/home/ubuntu/build --install-purelib=/home/ubuntu/build/lib --install-scripts=/home/ubuntu/build/scripts --install-headers=/home/ubuntu/build/include --install-data=/home/ubuntu/build/data dir=/home/ubuntu/source/pybindgen

 >> Built pybindgen-0.19.0.post4+ng823d8b2 - OK
 >> Building netanim-3.108 -     > cd /home/ubuntu/source/netanim-3.108;qmake NetAnim.pro
 mkdir /home/ubuntu/source/netanim-3.108 dir=/home/ubuntu/source/netanim-3.108
  -> LD_LIBRARY_PATH /home/ubuntu/build/lib 
 make dir=/home/ubuntu/source/netanim-3.108
  -> LD_LIBRARY_PATH /home/ubuntu/build/lib 
 make install dir=/home/ubuntu/source/netanim-3.108
  -> LD_LIBRARY_PATH /home/ubuntu/build/lib 

 >> Built netanim-3.108 - OK
 >> Building ns-3.29 -  /usr/bin/python3 /home/ubuntu/source/ns-3.29/waf configure --prefix=/home/ubuntu/build --enable-examples --enable-tests dir=/home/ubuntu/source/ns-3.29
  -> LD_LIBRARY_PATH /home/ubuntu/build/lib 
 /usr/bin/python3 /home/ubuntu/source/ns-3.29/waf dir=/home/ubuntu/source/ns-3.29
  -> LD_LIBRARY_PATH /home/ubuntu/build/lib 

 >> Building ns-3.29 - Problem
   > Subprocess failed with error 1: ['/usr/bin/python3', '/home/ubuntu/source/ns-3.29/waf']

bake.Exceptions.TaskError: Subprocess failed with error 1: ['/usr/bin/python3', '/home/ubuntu/source/ns-3.29/waf']

  File "/home/ubuntu/bake/bake/Module.py", line 427, in build
    self._build.build(env, jobs)
  File "/home/ubuntu/bake/bake/ModuleBuild.py", line 416, in build
    env=self._env(env.objdir))
  File "/home/ubuntu/bake/bake/ModuleEnvironment.py", line 540, in run
    raise TaskError('Subprocess failed with error %d: %s' % (retcode, str(args)))
 > Error:  Critical dependency, module "ns-3.29" failed 

bake.Dependencies.DependencyUnmet: (<bake.Module.Module object at 0x7f082b748198>, 'failed')

  File "/home/ubuntu/bake/bake/Bake.py", line 687, in _iterate
    deps.resolve(targets)
  File "/home/ubuntu/bake/bake/Dependencies.py", line 198, in resolve
    self._resolve_serial(targets, callback)
  File "/home/ubuntu/bake/bake/Dependencies.py", line 433, in _resolve_serial
    finished = self._resolve_one_iteration(targets, callback)
  File "/home/ubuntu/bake/bake/Dependencies.py", line 411, in _resolve_one_iteration
    raise DependencyUnmet(i.dst(), tailError)

Lastly, running bake.py --debug build -vv returned this (it was very long so I have only included the error part): 

Waf: Leaving directory `/home/ubuntu/source/ns-3.29/build'
Build failed
 -> task in 'ns3-visualizer' failed with exit status 1 (run with -v to display more information)

 >> Building ns-3.29 - Problem
   > Subprocess failed with error 1: ['/usr/bin/python3', '/home/ubuntu/source/ns-3.29/waf']

bake.Exceptions.TaskError: Subprocess failed with error 1: ['/usr/bin/python3', '/home/ubuntu/source/ns-3.29/waf']

  File "/home/ubuntu/bake/bake/Module.py", line 427, in build
    self._build.build(env, jobs)
  File "/home/ubuntu/bake/bake/ModuleBuild.py", line 416, in build
    env=self._env(env.objdir))
  File "/home/ubuntu/bake/bake/ModuleEnvironment.py", line 540, in run
    raise TaskError('Subprocess failed with error %d: %s' % (retcode, str(args)))
 > Error:  Critical dependency, module "ns-3.29" failed 

bake.Dependencies.DependencyUnmet: (<bake.Module.Module object at 0x7f53e8b7b198>, 'failed')

  File "/home/ubuntu/bake/bake/Bake.py", line 687, in _iterate
    deps.resolve(targets)
  File "/home/ubuntu/bake/bake/Dependencies.py", line 198, in resolve
    self._resolve_serial(targets, callback)
  File "/home/ubuntu/bake/bake/Dependencies.py", line 433, in _resolve_serial
    finished = self._resolve_one_iteration(targets, callback)
  File "/home/ubuntu/bake/bake/Dependencies.py", line 411, in _resolve_one_iteration
    raise DependencyUnmet(i.dst(), tailError)

I've searched previous threads, but all of them used Waf to build.

I'm sorry if any of this was unclear, I am still very new to Linux and unfamiliar with the terminal. 
Any help would appreciated! Let me know if anything else is needed! Thanks! 


Tom Henderson

unread,
Jul 9, 2019, 7:07:32 PM7/9/19
to ns-3-...@googlegroups.com
Please cd into the ns-3.29 directory and run './waf build' directly from
there, and report how it is failing.

- 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 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
> <mailto:ns-3-users+...@googlegroups.com>.
> To post to this group, send email to ns-3-...@googlegroups.com
> <mailto:ns-3-...@googlegroups.com>.
> Visit this group at https://groups.google.com/group/ns-3-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ns-3-users/20aa305d-0dff-4e98-b975-90fd7aa88b61%40googlegroups.com
> <https://groups.google.com/d/msgid/ns-3-users/20aa305d-0dff-4e98-b975-90fd7aa88b61%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout.

Shubham Kumar

unread,
Jul 9, 2019, 7:12:12 PM7/9/19
to ns-3-users


Thank you for your response. I tried waf a couple hours back and it worked! Sorry for not updating.

Little curious as to why './bake.py deploy' didn't work. But oh well! 

Tom Henderson

unread,
Jul 9, 2019, 8:11:53 PM7/9/19
to ns-3-...@googlegroups.com


On 7/9/19 6:12 PM, Shubham Kumar wrote:


Thank you for your response. I tried waf a couple hours back and it worked! Sorry for not updating.

Little curious as to why './bake.py deploy' didn't work. But oh well!

I just started over with 'deploy' and it also worked for me.  Deploy is just a wrapper to 'download' plus 'build', and 'build' of ns-3.29 just calls 'waf build'.

- Tom

Siman

unread,
Oct 31, 2020, 1:46:45 AM10/31/20
to ns-3-users
Hi there,

I encounter the same error with kumars, using `bake.py deploy` and build failed. I tried the solution given by Tom in this thread,  but still build failed even when I ran `./waf build` under ns-3.29 directory. Any help would be appreciated! Thanks in advance.

Upon building (bake.py build), the following happened:

>> Building netanim-3.108 -     > cd /Users/siman/ProgramManager/bake/source/netanim-3.108;qmake NetAnim.pro

 mkdir /Users/siman/ProgramManager/bake/source/netanim-3.108 dir=/Users/siman/ProgramManager/bake/source/netanim-3.108

 make dir=/Users/siman/ProgramManager/bake/source/netanim-3.108

 make install dir=/Users/siman/ProgramManager/bake/source/netanim-3.108


 >> Built netanim-3.108 - OK

 >> Building pybindgen-0.19.0.post4+ng823d8b2 -  /opt/anaconda3/bin/python3 --version dir=None

    > mkdir -p /Users/siman/ProgramManager/bake/build/lib

 /opt/anaconda3/bin/python3 /Users/siman/ProgramManager/bake/source/pybindgen/setup.py build --build-base=/Users/siman/ProgramManager/bake/source/pybindgen/objdir dir=/Users/siman/ProgramManager/bake/source/pybindgen

 /opt/anaconda3/bin/python3 /Users/siman/ProgramManager/bake/source/pybindgen/setup.py install --install-base=/Users/siman/ProgramManager/bake/build --install-purelib=/Users/siman/ProgramManager/bake/build/lib --install-scripts=/Users/siman/ProgramManager/bake/build/scripts --install-headers=/Users/siman/ProgramManager/bake/build/include --install-data=/Users/siman/ProgramManager/bake/build/data dir=/Users/siman/ProgramManager/bake/source/pybindgen


 >> Built pybindgen-0.19.0.post4+ng823d8b2 - OK

 >> Building ns-3.29 -  /opt/anaconda3/bin/python3 /Users/siman/ProgramManager/bake/source/ns-3.29/waf configure --prefix=/Users/siman/ProgramManager/bake/build --enable-examples --enable-tests dir=/Users/siman/ProgramManager/bake/source/ns-3.29

 /opt/anaconda3/bin/python3 /Users/siman/ProgramManager/bake/source/ns-3.29/waf dir=/Users/siman/ProgramManager/bake/source/ns-3.29


 >> Building ns-3.29 - Problem

   > Subprocess failed with error 1: ['/opt/anaconda3/bin/python3', '/Users/siman/ProgramManager/bake/source/ns-3.29/waf']

 > Error:  Critical dependency, module "ns-3.29" failed 

   For more information call Bake with --debug and/or -v, -vvv, for full verbose mode (bake --help)


Then, I entered ns-3.29 directory, and tried ./waf build -v, it showed (only included error parts):

In file included from ../src/internet/helper/ipv6-routing-helper.cc:23:

In file included from ./ns3/simulator.h:26:

./ns3/make-event.h:665:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2, U3);

                   ^

./ns3/make-event.h:699:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2, U3, U4);

                   ^

./ns3/make-event.h:633:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2);

                   ^

./ns3/make-event.h:665:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2, U3);

                   ^

4 errors generated.


In file included from ../src/internet/helper/ipv4-routing-helper.cc:23:

In file included from ./ns3/simulator.h:26:

./ns3/make-event.h:665:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2, U3);

                   ^

./ns3/make-event.h:699:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2, U3, U4);

                   ^

./ns3/make-event.h:633:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2);

                   ^

./ns3/make-event.h:665:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2, U3);

                   ^

4 errors generated.


In file included from ../src/internet/model/ipv6-interface.cc:33:

In file included from ../src/internet/model/icmpv6-l4-protocol.h:33:

In file included from ../src/internet/model/ndisc-cache.h:32:

In file included from ./ns3/timer.h:302:

In file included from ./ns3/timer-impl.h:24:

In file included from ./ns3/simulator.h:26:

./ns3/make-event.h:665:20: error: unused typedef 'F' [-Werror,-Wunused-local-typedef]

    typedef void (*F)(U1, U2, U3);

                   ^

1 error generated.


Waf: Leaving directory `/Users/siman/ProgramManager/bake/source/ns-3.29/build'

Build failed

 -> task in 'ns3-internet' failed with exit status 1: 

{task 140369866933712: cxx ipv6-routing-helper.cc -> ipv6-routing-helper.cc.1.o}

['/usr/bin/clang++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-std=c++11', '-fPIC', '-I.', '-I..', '-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', '../src/internet/helper/ipv6-routing-helper.cc', '-c', '-o/Users/siman/ProgramManager/bake/source/ns-3.29/build/src/internet/helper/ipv6-routing-helper.cc.1.o', '-I/usr/local/opt/qt/include']

 -> task in 'ns3-internet' failed with exit status 1: 

{task 140369866933328: cxx ipv4-routing-helper.cc -> ipv4-routing-helper.cc.1.o}

['/usr/bin/clang++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-std=c++11', '-fPIC', '-I.', '-I..', '-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', '../src/internet/helper/ipv4-routing-helper.cc', '-c', '-o/Users/siman/ProgramManager/bake/source/ns-3.29/build/src/internet/helper/ipv4-routing-helper.cc.1.o', '-I/usr/local/opt/qt/include']

 -> task in 'ns3-internet' failed with exit status 1: 

{task 140369866827984: cxx ipv6-interface.cc -> ipv6-interface.cc.1.o}

['/usr/bin/clang++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-std=c++11', '-fPIC', '-I.', '-I..', '-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', '../src/internet/model/ipv6-interface.cc', '-c', '-o/Users/siman/ProgramManager/bake/source/ns-3.29/build/src/internet/model/ipv6-interface.cc.1.o', '-I/usr/local/opt/qt/include']


Reply all
Reply to author
Forward
0 new messages