|
Bugzilla – Full Text Bug Listing |
| Summary: | Can't build ns-3-dev with g++ 4.7.2 (error in fd-net-device/helper/tap-creator.cc) | ||
|---|---|---|---|
| Product: | ns-3 | Reporter: | Lalith Suresh <suresh.lalith> |
| Component: | emulation | Assignee: | ns-bugs <ns-bugs> |
| Status: | RESOLVED FIXED | ||
| Severity: | major | CC: | aquereilhac |
| Priority: | P2 | ||
| Version: | ns-3-dev | ||
| Hardware: | All | ||
| OS: | All | ||
| Attachments: | Fix | ||
|
Description
Lalith Suresh
2013-03-28 12:13:07 UTC
(In reply to comment #0) > Created attachment 1547 [details] > Fix > > (I can't find a 'fd-net-device' component in bugzilla, so I'll add it under > emulation for now.) > > Here's what I get when I try to build ns-3-dev. > > > $: uname -a > Linux irule 3.5.0-26-generic #42-Ubuntu SMP Fri Mar 8 23:20:06 UTC 2013 i686 > i686 i686 GNU/Linux > > $: g++ --version > g++ (Ubuntu/Linaro 4.7.2-2ubuntu1) 4.7.2 > Copyright (C) 2012 Free Software Foundation, Inc. > This is free software; see the source for copying conditions. There is NO > warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. > > $: hg tip > changeset: 9272:32d40ab86df5 > tag: tip > user: Vedran Miletić <rivanvx@gmail.com> > date: Thu Mar 28 10:31:56 2013 +0100 > summary: Fix INCLUDE_GUARD in create-module.py > > $: ./waf configure --disable-python --enable-examples > --enable-modules=applications > $: ./waf build > > ... > [945/953] cxx: src/fd-net-device/helper/creator-utils.cc -> > build/src/fd-net-device/helper/creator-utils.cc.4.o > ../src/fd-net-device/helper/tap-creator.cc: In function ‘int main(int, > char**)’: > ../src/fd-net-device/helper/tap-creator.cc:299:16: error: converting to > non-pointer type ‘int’ from NULL [-Werror=conversion-null] > ../src/fd-net-device/helper/tap-creator.cc:360:7: error: NULL used in > arithmetic [-Werror=pointer-arith] > cc1plus: all warnings being treated as errors > Waf: Leaving directory > `/home/lalith/programming/click-merge/final/fd-net-device-test/build' > Build failed > -> task in 'tap-creator' failed (exit status 1): > {task 156864620: cxx tap-creator.cc -> tap-creator.cc.4.o} > ['/usr/bin/g++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', > '-Wno-error=deprecated-declarations', '-fstrict-aliasing', '-Wstrict-aliasing', > '-DNS3_ASSERT_ENABLE', '-DNS3_LOG_ENABLE', '-DHAVE_SYS_IOCTL_H=1', > '-DHAVE_IF_NETS_H=1', '-DHAVE_TAP_CREATOR=1', '-DHAVE_PACKET_H=1', > '-DHAVE_RAW_SOCKET_CREATOR=1', '-DHAVE_IF_TUN_H=1', > '../src/fd-net-device/helper/tap-creator.cc', '-c', '-o', > 'src/fd-net-device/helper/tap-creator.cc.4.o'] > ... > > > Patch attached. Thank you for the patch. I have added the fix in changeset 98c7f435b0a3. Could you please try compiling again and confirm whether it now works? Works in MacOSX (the build, don't have time to check the fd-net-device right now) I reviewed this last night. It works fine for me, so I'll close this bug until someone else reports some issue. |