Closed wangs0622 closed 5 years ago
I have solved this problem. The main reason is that my protoc
version is 2.6.1, it must be greater than 3.0。 After I update this protoc
manually, I can build successfully.
I have a similar error, but after updating protoc, the error still exists. [1795/1863] Compiling scratch/opengym/sim.cc ../scratch/opengym/sim.cc:23:32: fatal error: ns3/opengym-module.h: No such file or directory compilation terminated.
I have a similar error, but after updating protoc, the error still exists. [1795/1863] Compiling scratch/opengym/sim.cc ../scratch/opengym/sim.cc:23:32: fatal error: ns3/opengym-module.h: No such file or directory compilation terminated.
The same as your errors, though I have upgrade to the latest protobuf manually. It seems the opengym module is not built as it is supposed to.
here is my ./waf configure
output,
Setting top to : /mnt/sdb1/ns3-gym
Setting out to : /mnt/sdb1/ns3-gym/build
Checking for 'gcc' (C compiler) : /usr/bin/gcc
Checking for cc version : 6.5.0
Checking for 'g++' (C++ compiler) : /usr/bin/g++
Checking for compilation flag -Wl,--soname=foo support : ok
Checking for compilation flag -std=c++11 support : ok
Checking for program 'python' : /usr/bin/python3
Checking for python version >= 2.3 : 3.5.2
python-config : /usr/bin/python3-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 : not found
Checking for python module 'pybindgen' : 0.21.0
Checking for pybindgen version : 0.21.0
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_58
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+-3.0' : not found
Checking for 'libxml-2.0' : not found
checking for uint128_t : not found
checking for __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 library zmq : not found
Checking for library protobuf : yes
Checking for program 'protoc' : /usr/local/bin/protoc
Checking for protoc version : 3.12.3
Checking for 'sqlite3' : not found
Checking for header linux/if_tun.h : yes
Checking for python module 'gi' : 3.20.0
Checking for python module 'gi.repository.GObject' : ok
Checking for python module 'cairo' : ok
Checking for python module 'pygraphviz' : not found
Checking for python module 'gi.repository.Gtk' : ok
Checking for python module 'gi.repository.Gdk' : ok
Checking for python module 'gi.repository.Pango' : ok
Checking for python module 'gi.repository.GooCanvas' : not found
Checking for program 'sudo' : /usr/bin/sudo
Checking for program 'valgrind' : not found
Checking for 'gsl' : not found
python-config : not found
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' : not found
---- Summary of optional NS-3 features:
Build profile : debug
Build directory :
BRITE Integration : not enabled (BRITE not enabled (see option --with-brite))
DES Metrics event collection : not enabled (defaults to disabled)
Emulation FdNetDevice : enabled
Examples : not enabled (defaults to disabled)
File descriptor NetDevice : enabled
GNU Scientific Library (GSL) : not enabled (GSL not found)
Gcrypt library : not enabled (libgcrypt not found: you can use libgcrypt-config to find its location.)
GtkConfigStore : not enabled (library 'gtk+-3.0 >= 3.0' not found)
MPI Support : not enabled (option --enable-mpi not selected)
NS-3 Click Integration : not enabled (nsclick not enabled (see option --with-nsclick))
NS-3 OpenFlow Integration : not enabled (OpenFlow not enabled (see option --with-openflow))
Network Simulation Cradle : not enabled (NSC not found (see option --with-nsc))
PlanetLab FdNetDevice : not enabled (PlanetLab operating system not detected (see option --force-planetlab))
PyViz visualizer : not enabled (Missing python modules: pygraphviz, gi.repository.GooCanvas)
Python API Scanning Support : not enabled (Missing 'pygccxml' Python module)
Python Bindings : enabled
Real Time Simulator : enabled
SQlite stats data output : not enabled (library 'sqlite3' not found)
Tap Bridge : enabled
Tap FdNetDevice : enabled
Tests : not enabled (defaults to disabled)
Threading Primitives : enabled
Use sudo to set suid bit : not enabled (option --enable-sudo not selected)
XmlIo : not enabled (library 'libxml-2.0 >= 2.7' not found)
'configure' finished successfully (5.253s)
And the /src/opengym/model/ns3gym/ns3gym/messages_pb2.py
is not generated when I run ./waf configure
before. After configuration, I run pip install ./src/opengym/model/ns3gym
and get this error message "Protocol Buffer messages are missing. Please run ./waf configure to generate the file").
I removed the scratch
dir and the other modules are built successfully, except opengym
. Do you have any idea why it is not built? I have run ./waf clean
before the cofiguration.
Modules built:
antenna aodv applications
bridge buildings config-store
core csma csma-layout
dsdv dsr energy
fd-net-device flow-monitor internet
internet-apps lr-wpan lte
mesh mobility mpi
netanim (no Python) network nix-vector-routing
olsr point-to-point point-to-point-layout
propagation sixlowpan spectrum
stats tap-bridge test (no Python)
topology-read traffic-control uan
virtual-net-device wave wifi
wimax
Modules not built (see ns-3 tutorial for explanation):
brite click openflow
opengym visualizer
@Forsworns , have you solved the issue (open gym). I have face the exact same error.
I have solved this problem. The main reason is that my
protoc
version is 2.6.1, it must be greater than 3.0。 After I update thisprotoc
manually, I can build successfully.
I have the same question,when I update the'protoc',it can't build correctly,still.
My protoc version is greater than 3(3.6.0),but i still face the problem....sad
I also have the same issue with Opengym-module.h it does not exist after building.
Hope the creator can help us resolve this.
I have a similar error, but after updating protoc, the error still exists. [1795/1863] Compiling scratch/opengym/sim.cc ../scratch/opengym/sim.cc:23:32: fatal error: ns3/opengym-module.h: No such file or directory compilation terminated.
Have you solved this problem? I also have this problem. How can I solve it?
Sorry for the late response, I have not worked on that project for a long time...
To be honest, I gave up and didn't use ns3-gym finally. Instead, I directly communicate with python code by Python/C API
if you can read Chinese and interested how to do this, here is my notes written during implement that.
As for
error message "Protocol Buffer messages are missing. Please run ./waf configure to generate the file"). of ns3-gym
I cannot remember this. I can only find some clues in my notes mentioned above: check your zmq version, protoc location, try to leave anaconda environment ...
Sorry for the late response, I have not worked on that project for a long time...
To be honest, I gave up and didn't use ns3-gym finally. Instead, I directly communicate with python code by Python/C API
if you can read Chinese and interested how to do this, here is my notes written during implement that.
As for
error message "Protocol Buffer messages are missing. Please run ./waf configure to generate the file"). of ns3-gym
I cannot remember this. I can only find some clues in my notes mentioned above: check your zmq version, protoc location, try to leave anaconda environment ...
Thank you very much for your reply. I didn't install zmq. This problem has been solved, but there are other problems during the test
when I build ns3-gym by the
./waf build
, I get an error like:In file included from ../scratch/linear-mesh-2/mygym.cc:21:0: ../scratch/linear-mesh-2/mygym.h:26:32: fatal error: ns3/opengym-module.h: No such file or directory compilation terminated. Waf: Leaving directory '/home/wangs0622/ns_3_workspace/ns3-gym/build' Build failed -> task in 'linear-mesh-2' failed with exit status 1 (run with -v to display more information)
And I found the
opengym-module.h
is used by many files inscratch
directory. But theopengym-module.h
is not existed in thebuild/ns/
directory. So I think the error reason is that I don't have theopengym-module.h
file.How to deal with it? and where can I get this header file? Thank you~