free5G / free5GRAN

free5GRAN is an open-source 5G RAN stack. The current version includes a receiver which decodes MIB & SIB1 data. It also acts as a cell scanner. free5GRAN works in SA mode.
Apache License 2.0
96 stars 40 forks source link

Build fail, sorry, unimplemented: non-trivial designated initializers not supported #13

Closed gmg2719 closed 3 years ago

gmg2719 commented 3 years ago

Describe the bug A clear and concise description of what the bug is. Build failure To Reproduce Just try to use make command, the following failure occurs:

Scanning dependencies of target free5GRAN [ 99%] Building CXX object CMakeFiles/free5GRAN.dir/src/main.cc.o [100%] Building CXX object CMakeFiles/free5GRAN.dir/src/phy/phy.cpp.o /home/nano/free5GRAN-master-B210/src/phy/phy.cpp: In member function ‘int phy::init(free5GRAN::synchronization_object&, std::condition_variable&)’: /home/nano/free5GRAN-master-B210/src/phy/phy.cpp:373:49: sorry, unimplemented: non-trivial designated initializers not supported .shiftIndex = pci}}; ^ /home/nano/free5GRAN-master-B210/src/phy/phy.cpp:373:49: sorry, unimplemented: non-trivial designated initializers not supported /home/nano/free5GRAN-master-B210/src/phy/phy.cpp:373:49: sorry, unimplemented: non-trivial designated initializers not supported /home/nano/free5GRAN-master-B210/src/phy/phy.cpp:373:49: sorry, unimplemented: non-trivial designated initializers not supported /home/nano/free5GRAN-master-B210/src/phy/phy.cpp:373:49: sorry, unimplemented: non-trivial designated initializers not supported CMakeFiles/free5GRAN.dir/build.make:86: recipe for target 'CMakeFiles/free5GRAN.dir/src/phy/phy.cpp.o' failed make[2]: [CMakeFiles/free5GRAN.dir/src/phy/phy.cpp.o] Error 1 CMakeFiles/Makefile2:142: recipe for target 'CMakeFiles/free5GRAN.dir/all' failed make[1]: [CMakeFiles/free5GRAN.dir/all] Error 2 Makefile:129: recipe for target 'all' failed make: *** [all] Error 2

Screenshots

System:

Additional context Add any other context about the problem here.

adejavel commented 3 years ago

Hello, which version of gcc are you using ?

gmg2719 commented 3 years ago

gcc verison is :

gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0 Copyright (C) 2017 Free Software Foundation, Inc.

gmg2719 commented 3 years ago

I try to upgrade my gcc to gcc (Ubuntu 9.3.0-11ubuntu0~18.04.1) 9.3.0 , but the error still remains. what gcc version need ? In fact , I compiled pass in all your formal code before last month. I don't know why I can't compile this version of your code.

adejavel commented 3 years ago

We will investigate. We do not have the issue here. Thanks for reporting

gmg2719 commented 3 years ago

I finnally solve it. After I upgrade my gcc to gcc-9. When I type gcc -v , it returns version 9.3.0. But when I type g++ -v, it returns still version 7.5.0. I think this is the problem, so I try to let ubuntu point to g++-9 when type g++. After this effort, build free5GRAN is OK now.

adejavel commented 3 years ago

Thanks for your reply. We will investigate which gcc/g++ version is best for compiling