Hello,
I am developing a custom user-space routing protocol in C++ with multiple header and source files.
If I try to run my program on DCE, it shows the following error:
cdsn@cdsn-ns3-1:~/repos/dce/source/ns-3-dce$ ./waf --run "dce-bhshin-test"
Waf: Entering directory `/home/cdsn/repos/dce/source/ns-3-dce/build'
--------------------------------------------------------------------
Python bindings compilation
--------------------------------------------------------------------
[ 10/375] lib/pkgconfig/libns3-dev-netlink-debug.pc: -> build/lib/pkgconfig/libns3-dev-netlink-debug.pc
[118/375] lib/pkgconfig/libns3-dev-dce-debug.pc: -> build/lib/pkgconfig/libns3-dev-dce-debug.pc
Waf: Leaving directory `/home/cdsn/repos/dce/source/ns-3-dce/build'
'build' finished successfully (0.398s)
assert failed. cond="handle != 0", msg="Could not open elf-cache/0/sina-0.2 elf-cache/0/sina-0.2: symbol isspace, version GLIBC_2.2.5 not defined in file 0001.so.6 with link time reference", file=../model/cooja-loader-factory.cc, line=236
terminate called without an active exception
Command ['/home/cdsn/repos/dce/source/ns-3-dce/build/myscripts/bhshin-test/bin/dce-bhshin-test'] terminated with signal SIGIOT. Run it under a debugger to get more information (./waf --run <program> --command-template="gdb --args %s <args>").
In the simulation configuration file (myscripts/dce-bhshin-test/dce-bhshin-test.cc), I created only one node and just executed my C++ application which is almost the same as the "dce-sleep" example. I attach my simulation configuration file.
My C++ application is created as follows:
- I need to use multi threading so that multiple different control packets are exchanged with different periods. So, I added "-pthread, -lpthread, -Wl,--no-as-needed" flags.
- I used some C++11 features, and I compiled it with the flag "-std=c++11".
g++ -fPIC -std=c++11 -c -o traffic_monitor/tcpdmon.o traffic_monitor/tcpdmon.cc
g++ -fPIC -std=c++11 -c -o traffic_monitor/traffic_monitor.o traffic_monitor/traffic_monitor.cc
g++ -fPIC -std=c++11 -c -o flow/flow_type.o flow/flow_type.cc
g++ -fPIC -std=c++11 -c -o flow/flow.o flow/flow.cc
g++ -fPIC -std=c++11 -c -o flow/flow_stat.o flow/flow_stat.cc
g++ -fPIC -std=c++11 -c -o flow/flow_entry.o flow/flow_entry.cc
g++ -fPIC -std=c++11 -c -o traffic_monitor/packet_info.o traffic_monitor/packet_info.cc
g++ -fPIC -std=c++11 -c -o config.o config.cc
g++ -fPIC -std=c++11 -c -o main.o main.cc
g++ -o sina-0.2 -pie -rdynamic -pthread -lpthread -Wl,--no-as-needed -std=c++11 traffic_monitor/tcpdmon.o traffic_monitor/traffic_monitor.o flow/flow_type.o flow/flow.o flow/flow_stat.o flow/flow_entry.o traffic_monitor/packet_info.o config.o main.o
My environment is as follows:
OS: Ubuntu 14.04 (amd64)
DCE version: 1.9
g++/gcc version: 4.8.4-2ubuntu1~14.04.3
I tested the executable "sina-0.2" and it is working well in the physical linux (Ubuntu 14.04 amd64).
But If I copy the program into dce/source/ns-3-dce/build/bin_dce/ and run it, the above GLIBC error happens.
How can I fix it?