SysSec-KAIST / LTESniffer

An Open-source LTE Downlink/Uplink Eavesdropper
GNU Affero General Public License v3.0
1.8k stars 184 forks source link

Help with this build error, using ubuntu 23.10 #42

Closed wannerguzman closed 1 year ago

wannerguzman commented 1 year ago

[ 1%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/at/at_interface.c.o [ 1%] Building CXX object srsRAN-build/lib/src/support/CMakeFiles/support.dir/emergency_handlers.cc.o [ 1%] Building CXX object srsRAN-build/lib/src/asn1/CMakeFiles/srsran_asn1.dir/liblte_common.cc.o [ 1%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/test/devices/sierra_wireless_em7565/test_at.c.o [ 1%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/at/at_interface_mock.c.o [ 2%] Building CXX object srsRAN-build/lib/src/asn1/CMakeFiles/srsran_asn1.dir/liblte_mme.cc.o /home/charon/LTESniffer-LTESniffer-v2.0.0/build/cmnalib-src/src/cmnalib/src/at/at_interface_mock.c: In function ‘at_interface_command_mock’: /home/charon/LTESniffer-LTESniffer-v2.0.0/build/cmnalib-src/src/cmnalib/src/at/at_interface_mock.c:94:5: warning: ignoring return value of ‘fscanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 94 | fscanf(h->file, "%" TOSTRING(AT_INTERFACE_MAX_COMMAND_STRING_LENGTH) "[^" LINE_SEPARATOR "]" LINE_SEPARATOR, tty_cmd_from_file); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/devices/at_sierra_wireless_em7565.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/at/at_interface.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/at/at_interface_mock.c.o /home/charon/LTESniffer-LTESniffer-v2.0.0/build/cmnalib-src/src/cmnalib/src/at/at_interface_mock.c: In function ‘at_interface_command’: /home/charon/LTESniffer-LTESniffer-v2.0.0/build/cmnalib-src/src/cmnalib/src/at/at_interface_mock.c:94:5: warning: ignoring return value of ‘fscanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 94 | fscanf(h->file, "%" TOSTRING(AT_INTERFACE_MAX_COMMAND_STRING_LENGTH) "[^" LINE_SEPARATOR "]" LINE_SEPARATOR, tty_cmd_from_file); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/devices/at_sierra_wireless_em7565.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/devices/at_sierra_wireless_mc7455.c.o In file included from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/bundled/fmt/format.h:44, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/bundled/fmt/ostream.h:13, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/bundled/fmt/printf.h:14, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/detail/log_backend.h:25, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/log_channel.h:25, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/logger.h:25, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/srslog.h:26, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/support/srsran_assert.h:26, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/src/support/emergency_handlers.cc:23: /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/bundled/fmt/core.h:1307:44: error: field ‘value’ has incomplete type ‘std::array<char, 256>’ 1307 | std::array<char, max_pool_string_size> value; | ^~~~~ In file included from /usr/include/c++/13/bits/unique_ptr.h:36, from /usr/include/c++/13/memory:78, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/detail/support/any.h:25, from /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/include/srsran/srslog/srslog.h:25: /usr/include/c++/13/tuple:2005:45: note: declaration of ‘struct std::array<char, 256>’ 2005 | template<typename _Tp, size_t _Nm> struct array; | ^~~~~ make[2]: [srsRAN-build/lib/src/support/CMakeFiles/support.dir/build.make:76: srsRAN-build/lib/src/support/CMakeFiles/support.dir/emergency_handlers.cc.o] Error 1 make[1]: [CMakeFiles/Makefile2:7901: srsRAN-build/lib/src/support/CMakeFiles/support.dir/all] Error 2 make[1]: * Waiting for unfinished jobs.... [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/devices/at_sierra_wireless_mc7455.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/devices/enumerate.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/devices/enumerate.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/traffic/traffic_curl.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/traffic/traffic_curl.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/util/conversion.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/util/device_enumerator.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/util/gps_transform.c.o [ 2%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/util/conversion.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/util/info.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/util/logger.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/util/network_interface.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/util/tokenfind.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/util/device_enumerator.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/testlib.dir/src/util/trace_logger.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/util/gps_transform.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/util/info.c.o [ 3%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/util/logger.c.o [ 4%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/util/network_interface.c.o [ 4%] Linking C executable testlib [ 4%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/util/tokenfind.c.o /usr/bin/cc -O2 -g -DNDEBUG -rdynamic CMakeFiles/testlib.dir/test/devices/sierra_wireless_em7565/test_at.c.o CMakeFiles/testlib.dir/src/at/at_interface.c.o CMakeFiles/testlib.dir/src/at/at_interface_mock.c.o CMakeFiles/testlib.dir/src/devices/at_sierra_wireless_em7565.c.o CMakeFiles/testlib.dir/src/devices/at_sierra_wireless_mc7455.c.o CMakeFiles/testlib.dir/src/devices/enumerate.c.o CMakeFiles/testlib.dir/src/traffic/traffic_curl.c.o CMakeFiles/testlib.dir/src/util/conversion.c.o CMakeFiles/testlib.dir/src/util/device_enumerator.c.o CMakeFiles/testlib.dir/src/util/gps_transform.c.o CMakeFiles/testlib.dir/src/util/info.c.o CMakeFiles/testlib.dir/src/util/logger.c.o CMakeFiles/testlib.dir/src/util/network_interface.c.o CMakeFiles/testlib.dir/src/util/tokenfind.c.o CMakeFiles/testlib.dir/src/util/trace_logger.c.o -o testlib -L/usr/lib/x86_64-linux-gnu/libcurl.so -Wl,-rpath,/usr/lib/x86_64-linux-gnu/libcurl.so -lglib-2.0 -ludev -lcurl -lm [ 4%] Building C object cmnalib-build/src/cmnalib/CMakeFiles/cmnalib_obj.dir/src/util/trace_logger.c.o [ 4%] Building CXX object srsRAN-build/lib/src/asn1/CMakeFiles/srsran_asn1.dir/gtpc.cc.o [ 4%] Built target testlib [ 4%] Built target cmnalib_obj /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/src/asn1/liblte_mme.cc: In function ‘LIBLTE_ERROR_ENUM liblte_mme_unpack_network_name_ie(uint8, LIBLTE_MME_NETWORK_NAME_STRUCT)’: /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/src/asn1/liblte_mme.cc:2093:20: error: ‘tmp_char’ may be used uninitialized [-Werror=maybe-uninitialized] 2093 | if (tmp_char == 0x0A || tmp_char == 0x0D || (tmp_char >= 0x20 && tmp_char <= 0x3F) || | ~~~^~~~~ /home/charon/LTESniffer-LTESniffer-v2.0.0/build/srsRAN-src/lib/src/asn1/liblte_mme.cc:2033:21: note: ‘tmp_char’ was declared here 2033 | char tmp_char; | ^~~~ cc1plus: all warnings being treated as errors make[2]: [srsRAN-build/lib/src/asn1/CMakeFiles/srsran_asn1.dir/build.make:90: srsRAN-build/lib/src/asn1/CMakeFiles/srsran_asn1.dir/liblte_mme.cc.o] Error 1 make[1]: * [CMakeFiles/Makefile2:3884: srsRAN-build/lib/src/asn1/CMakeFiles/srsran_asn1.dir/all] Error 2 make: *** [Makefile:156: all] Error 2

hdtuanss commented 1 year ago

Hi, I think the problem might be the incompatibility between srsRAN lib, cmath lib and Ubuntu 23.10. Please use Ubuntu 18.04/20.04/22.04 as they are tested. Thanks

wannerguzman commented 1 year ago

Will Do thanks!