Merge remote-tracking branch 'origin/develop' into ldpc-decoder-codegen
Conflicts: cmake_targets/build_oai openair1/PHY/CODING/nrLDPC_decoder/nrLDPC_cnProc.h openair1/PHY/CODING/nrLDPC_decoder/nrLDPC_decoder.c openair1/PHY/CODING/nrLDPC_decoder/nrLDPC_init_mem.h openair1/PHY/CODING/nrLDPC_decoder/nrLDPC_types.h openair1/PHY/NR_REFSIG/ptrs_nr.c
This commit is contained in:
+99
-502
File diff suppressed because it is too large
Load Diff
@@ -409,7 +409,6 @@ set(emm_HDR
|
||||
add_library(emm ${emm_SRC} ${emm_HDR})
|
||||
|
||||
target_include_directories(emm PRIVATE
|
||||
${OPENAIR_DIR}/common/utils/msc
|
||||
${OPENAIR_DIR}/common/utils
|
||||
${OPENAIR_DIR}/openair2/COMMON
|
||||
${OPENAIR_NAS_DIR}/UE
|
||||
@@ -693,7 +692,6 @@ include_directories(
|
||||
${OPENAIR_TARGETS}/COMMON
|
||||
${OPENAIR_NAS_DIR}/UE
|
||||
${OPENAIR_DIR}/common/utils
|
||||
${OPENAIR_DIR}/common/utils/msc
|
||||
${OPENAIR3_DIR}/COMMON
|
||||
${OPENAIR3_DIR}/SECU
|
||||
${OPENAIR_NAS_DIR}/src
|
||||
|
||||
@@ -1069,12 +1069,12 @@
|
||||
<pre_exec>$OPENAIR_DIR/cmake_targets/autotests/tools/free_mem.bash</pre_exec>
|
||||
<pre_exec_args></pre_exec_args>
|
||||
<main_exec> $OPENAIR_DIR/targets/bin/nr_pbchsim.Rel15</main_exec>
|
||||
<main_exec_args>-s0 -S1 -n1000 -R106
|
||||
-s0 -S1 -n10 -I -R106
|
||||
-s0 -S1 -n1000 -R217
|
||||
-s0 -S1 -n10 -I -R217
|
||||
-s0 -S1 -n1000 -R273
|
||||
-s0 -S1 -n10 -I -R273</main_exec_args>
|
||||
<main_exec_args>-s-11 -S-8 -n10 -R106
|
||||
-s-11 -S-8 -n10 -o8000 -I -R106
|
||||
-s-11 -S-8 -n10 -R217
|
||||
-s-11 -S-8 -n10 -o8000 -I -R217
|
||||
-s-11 -S-8 -n10 -R273
|
||||
-s-11 -S-8 -n10 -o8000 -I -R273</main_exec_args>
|
||||
<tags>nr_pbchsim.test1 nr_pbchsim.test2 nr_pbchsim.test3 nr_pbchsim.test4 nr_pbchsim.test5 nr_pbchsim.test6</tags>
|
||||
<search_expr_true>PBCH test OK</search_expr_true>
|
||||
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
|
||||
@@ -1093,17 +1093,18 @@
|
||||
(Test8: 217 PRB 100 PDSCH-PRBs 110 PDSCH-Offset),
|
||||
(Test9: 106 PRBs 50 PDSCH-PRBs MCS Index 27),
|
||||
(Test10: 106 PRBs 50 PDSCH-PRBs MCS Index 16),
|
||||
(Test11: HARQ test 25% TP (4 rounds),
|
||||
(Test12: HARQ test 33% TP (3 rounds),
|
||||
(Test13: HARQ test 50% TP (2 rounds),
|
||||
(Test14: 3 PTRS, 8 Interpolated Symbols),
|
||||
(Test15: 6 PTRS, 5 Interpolated Symbols),
|
||||
(Test16: 11 PTRS, 0 Interpolated Symbols),
|
||||
(Test17: Mapping type A, 2 DMRS Symbols),
|
||||
(Test18: Mapping type A, 3 DMRS Symbols),
|
||||
(Test19: Mapping type B, 4 DMRS Symbols),
|
||||
(Test20: 4x4 MIMO, 1 Layer),
|
||||
(Test21: 4x4 MIMO, 2 Layers)</desc>
|
||||
(Test11: 106 MCS-TABLE 256 QAM MCS Index 26),
|
||||
(Test12: HARQ test 25% TP 4 rounds),
|
||||
(Test13: HARQ test 33% TP 3 rounds),
|
||||
(Test14: HARQ test 50% TP 2 rounds),
|
||||
(Test15: 3 PTRS, 8 Interpolated Symbols),
|
||||
(Test16: 6 PTRS, 5 Interpolated Symbols),
|
||||
(Test17: 11 PTRS, 0 Interpolated Symbols),
|
||||
(Test18: Mapping type A, 2 DMRS Symbols),
|
||||
(Test19: Mapping type A, 3 DMRS Symbols),
|
||||
(Test20: Mapping type B, 4 DMRS Symbols),
|
||||
(Test21: 4x4 MIMO, 1 Layer),
|
||||
(Test22: 4x4 MIMO, 2 Layers)</desc>
|
||||
<pre_compile_prog></pre_compile_prog>
|
||||
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
|
||||
<compile_prog_args> --phy_simulators -c </compile_prog_args>
|
||||
@@ -1118,8 +1119,9 @@
|
||||
-n100 -R217 -b100 -s5
|
||||
-n100 -R217 -a80 -s5
|
||||
-n100 -R217 -a110 -s5 -b100
|
||||
-n100 -e27 -s30
|
||||
-n100 -e16 -s10
|
||||
-n100 -e27 -s30
|
||||
-n100 -e16 -s10
|
||||
-n100 -q1 -e26 -s30
|
||||
-n100 -s1 -t25
|
||||
-n100 -s1 -t33
|
||||
-n100 -s1 -t50
|
||||
@@ -1131,7 +1133,7 @@
|
||||
-n100 -s2 -U 2 1 3
|
||||
-n10 -s20 -U 3 0 0 2 -gR -x1 -y4 -z4
|
||||
-n10 -s20 -U 3 0 0 2 -gR -x2 -y4 -z4</main_exec_args>
|
||||
<tags>nr_dlsim.test1 nr_dlsim.test2 nr_dlsim.test3 nr_dlsim.test4 nr_dlsim.test5 nr_dlsim.test6 nr_dlsim.test7 nr_dlsim.test8 nr_dlsim.test9 nr_dlsim.test10 nr_dlsim.test11 nr_dlsim.test12 nr_dlsim.test13 nr_dlsim.test14 nr_dlsim.test15 nr_dlsim.test16 nr_dlsim.test17 nr_dlsim.test18 nr_dlsim.test19 nr_dlsim.test20 nr_dlsim.test21</tags>
|
||||
<tags>nr_dlsim.test1 nr_dlsim.test2 nr_dlsim.test3 nr_dlsim.test4 nr_dlsim.test5 nr_dlsim.test6 nr_dlsim.test7 nr_dlsim.test8 nr_dlsim.test9 nr_dlsim.test10 nr_dlsim.test11 nr_dlsim.test12 nr_dlsim.test13 nr_dlsim.test14 nr_dlsim.test15 nr_dlsim.test16 nr_dlsim.test17 nr_dlsim.test18 nr_dlsim.test19 nr_dlsim.test20 nr_dlsim.test21 nr_dlsim.test22</tags>
|
||||
<search_expr_true>PDSCH test OK</search_expr_true>
|
||||
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
|
||||
<nruns>3</nruns>
|
||||
|
||||
@@ -165,19 +165,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -165,19 +165,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -165,19 +165,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -165,19 +165,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -165,19 +165,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -165,19 +165,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -182,19 +182,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -182,19 +182,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -182,19 +182,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -184,19 +184,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -184,19 +184,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -184,19 +184,12 @@ eNBs =
|
||||
log_config :
|
||||
{
|
||||
global_log_level ="info";
|
||||
global_log_verbosity ="medium";
|
||||
hw_log_level ="info";
|
||||
hw_log_verbosity ="medium";
|
||||
phy_log_level ="info";
|
||||
phy_log_verbosity ="medium";
|
||||
mac_log_level ="info";
|
||||
mac_log_verbosity ="high";
|
||||
rlc_log_level ="info";
|
||||
rlc_log_verbosity ="medium";
|
||||
pdcp_log_level ="info";
|
||||
pdcp_log_verbosity ="medium";
|
||||
rrc_log_level ="info";
|
||||
rrc_log_verbosity ="medium";
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
+97
-125
@@ -39,50 +39,47 @@ conf_nvram_path=$OPENAIR_DIR/openair3/NAS/TOOLS/ue_eurecom_test_sfr.conf
|
||||
|
||||
XFORMS="True"
|
||||
SKIP_SHARED_LIB_FLAG="False"
|
||||
UE_EXPANSION="False"
|
||||
PRINT_STATS="False"
|
||||
VCD_TIMING="False"
|
||||
DEADLINE_SCHEDULER_FLAG_USER=""
|
||||
CPU_AFFINITY_FLAG_USER="False" #Only valid when low-latency flag is set to False
|
||||
REL="Rel15"
|
||||
HW="None"
|
||||
TP="Ethernet"
|
||||
EPC=0
|
||||
VERBOSE_CI=0
|
||||
VERBOSE_COMPILE=0
|
||||
CFLAGS_PROCESSOR_USER=""
|
||||
RUN_GROUP=0
|
||||
TEST_CASE_GROUP=""
|
||||
BUILD_DIR=ran_build
|
||||
BUILD_DOXYGEN=0
|
||||
BUILD_COVERITY_SCAN=0
|
||||
T_TRACER="True"
|
||||
DISABLE_HARDWARE_DEPENDENCY="False"
|
||||
CMAKE_BUILD_TYPE="RelWithDebInfo"
|
||||
CMAKE_CMD="$CMAKE"
|
||||
UE_AUTOTEST_TRACE="False"
|
||||
UE_DEBUG_TRACE="False"
|
||||
UE_TIMING_TRACE="False"
|
||||
NOAVX512="False"
|
||||
USRP_REC_PLAY="False"
|
||||
BUILD_ECLIPSE=0
|
||||
NR="False"
|
||||
ITTI_SIM="False"
|
||||
SANITIZE_ADDRESS="False"
|
||||
OPTIONAL_LIBRARIES="telnetsrv enbscope uescope nrscope msc"
|
||||
OPTIONAL_LIBRARIES="telnetsrv enbscope uescope nrscope"
|
||||
RU=0
|
||||
trap handle_ctrl_c INT
|
||||
CMAKE_C_FLAGS=()
|
||||
CMAKE_CXX_FLAGS=()
|
||||
|
||||
function print_help() {
|
||||
echo_info "
|
||||
This program installs OpenAirInterface Software
|
||||
You should have ubuntu 16.xx or 18.04 updated
|
||||
Options
|
||||
This script compiles OpenAirInterface Software, and can install dependencies
|
||||
for a number of distributions (Ubuntu 18-22, Fedora, RHEL7/8).
|
||||
Options:
|
||||
--arch-native
|
||||
Passes -march=native to the compiler.
|
||||
-c | --clean
|
||||
Erase all files to make a rebuild from start
|
||||
-C | --clean-all
|
||||
Erase all files made by previous compilations, installations
|
||||
--clean-kernel
|
||||
Erase previously installed features in kernel: iptables, drivers, ...
|
||||
--cmake-opt
|
||||
Pass the supplied option verbatim to cmake.
|
||||
-d | --build-dir
|
||||
Sets build directory (will be <oai-root>/cmake_targets/<build-dir>/build)
|
||||
-I | --install-external-packages
|
||||
Installs required packages such as LibXML, asn1.1 compiler, freediameter, ...
|
||||
This option will require root password
|
||||
@@ -194,6 +191,10 @@ function main() {
|
||||
until [ -z "$1" ]
|
||||
do
|
||||
case "$1" in
|
||||
--arch-native)
|
||||
CMAKE_C_FLAGS+=("-march=native")
|
||||
CMAKE_CXX_FLAGS+=("-march=native")
|
||||
shift;;
|
||||
-c | --clean)
|
||||
CLEAN=1
|
||||
shift;;
|
||||
@@ -204,6 +205,12 @@ function main() {
|
||||
clean_kernel
|
||||
echo_info "Erased iptables config and removed modules from kernel"
|
||||
shift;;
|
||||
--cmake-opt)
|
||||
CMAKE_CMD="$CMAKE_CMD $2"
|
||||
shift 2;;
|
||||
-d | --build-dir)
|
||||
BUILD_DIR=$2
|
||||
shift 2;;
|
||||
-I | --install-external-packages)
|
||||
INSTALL_EXTERNAL=1
|
||||
echo_info "Will install external packages"
|
||||
@@ -278,7 +285,7 @@ function main() {
|
||||
echo_info "Will compile NR UE"
|
||||
shift;;
|
||||
--mu)
|
||||
UE_EXPANSION="True"
|
||||
CMAKE_CMD="$CMAKE_CMD -DUE_EXPANSION=True -DPRE_SCD_THREAD=True"
|
||||
echo_info "Will compile with UE_EXPANSION"
|
||||
shift;;
|
||||
--UE-conf-nvram)
|
||||
@@ -302,7 +309,9 @@ function main() {
|
||||
*)
|
||||
echo_fatal "Unknown HW type $HW: exit..."
|
||||
esac
|
||||
echo_info "Setting hardware to: $HW"
|
||||
echo_info "Setting hardware to: $HW"
|
||||
#CMAKE_CMD="$CMAKE_CMD -DRF_BOARD=\"${HW}\""
|
||||
CMAKE_CMD="$CMAKE_CMD -DRF_BOARD=${HW}"
|
||||
shift 2;;
|
||||
-t | --transport)
|
||||
TP=$2
|
||||
@@ -326,7 +335,7 @@ function main() {
|
||||
shift 2;;
|
||||
-V | --vcd)
|
||||
echo_info "Setting gtk-wave output"
|
||||
VCD_TIMING=1
|
||||
CMAKE_CMD="$CMAKE_CMD -DENABLE_VCD_FIFO=True"
|
||||
EXE_ARGUMENTS="$EXE_ARGUMENTS -V"
|
||||
shift;;
|
||||
-x | --xforms)
|
||||
@@ -351,8 +360,8 @@ function main() {
|
||||
echo_info "Will compile with verbose instructions"
|
||||
shift;;
|
||||
--cflags_processor)
|
||||
CFLAGS_PROCESSOR_USER=$2
|
||||
echo_info "Setting CPU FLAGS from USER to: $CFLAGS_PROCESSOR_USER"
|
||||
CMAKE_CMD="$CMAKE_CMD -DCFLAGS_PROCESSOR_USER=\"$2\""
|
||||
echo_info "Setting CPU FLAGS from USER to: $2"
|
||||
shift 2;;
|
||||
--build-doxygen)
|
||||
BUILD_DOXYGEN=1
|
||||
@@ -364,22 +373,26 @@ function main() {
|
||||
shift;;
|
||||
--disable-deadline)
|
||||
DEADLINE_SCHEDULER_FLAG_USER="False"
|
||||
CMAKE_CMD="$CMAKE_CMD -DDEADLINE_SCHEDULER=False"
|
||||
echo_info "Disabling the usage of deadline scheduler"
|
||||
shift 1;;
|
||||
--enable-deadline)
|
||||
DEADLINE_SCHEDULER_FLAG_USER="True"
|
||||
CMAKE_CMD="$CMAKE_CMD -DDEADLINE_SCHEDULER=True"
|
||||
echo_info "Enabling the usage of deadline scheduler"
|
||||
shift 1;;
|
||||
--enable-cpu-affinity)
|
||||
CPU_AFFINITY_FLAG_USER="True"
|
||||
CMAKE_CMD="$CMAKE_CMD -DCPU_AFFINITY=True"
|
||||
echo_info "Enabling CPU Affinity (only valid when not using deadline scheduler)"
|
||||
shift 1;;
|
||||
--disable-cpu-affinity)
|
||||
CPU_AFFINITY_FLAG_USER="False"
|
||||
CMAKE_CMD="$CMAKE_CMD -DCPU_AFFINITY=False"
|
||||
echo_info "Disabling CPU Affinity (only valid when not using deadline scheduler)"
|
||||
shift 1;;
|
||||
--disable-T-Tracer)
|
||||
T_TRACER="False"
|
||||
CMAKE_CMD="$CMAKE_CMD -DT_TRACER=False"
|
||||
echo_info "Disabling the T tracer"
|
||||
shift 1;;
|
||||
--disable-hardware-dependency)
|
||||
@@ -387,15 +400,15 @@ function main() {
|
||||
DISABLE_HARDWARE_DEPENDENCY="True"
|
||||
shift 1;;
|
||||
--ue-autotest-trace)
|
||||
UE_AUTOTEST_TRACE="True"
|
||||
CMAKE_CMD="$CMAKE_CMD -DUE_AUTOTEST_TRACE=True"
|
||||
echo_info "Enabling autotest specific trace for UE"
|
||||
shift 1;;
|
||||
--ue-trace)
|
||||
UE_DEBUG_TRACE="True"
|
||||
CMAKE_CMD="$CMAKE_CMD -DUE_DEBUG_TRACE=False"
|
||||
echo_info "Enabling UE trace for debug"
|
||||
shift 1;;
|
||||
--ue-timing)
|
||||
UE_TIMING_TRACE="True"
|
||||
CMAKE_CMD="$CMAKE_CMD -DUE_TIMING_TRACE=True"
|
||||
echo_info "Enabling UE timing trace"
|
||||
shift 1;;
|
||||
--uhd-images-dir)
|
||||
@@ -426,10 +439,6 @@ function main() {
|
||||
fi
|
||||
fi
|
||||
shift 2;;
|
||||
--usrp-recplay)
|
||||
USRP_REC_PLAY="True"
|
||||
echo_info "Enabling USRP record playback mode"
|
||||
shift 1;;
|
||||
--noavx512)
|
||||
NOAVX512="True"
|
||||
echo_info "Disabling AVX512"
|
||||
@@ -438,16 +447,16 @@ function main() {
|
||||
SKIP_SHARED_LIB_FLAG="True"
|
||||
echo_info "Skipping build of shared libraries, rfsimulator and transport protocol libraries"
|
||||
shift;;
|
||||
--ninja)
|
||||
CMAKE_CMD="$CMAKE_CMD -GNinja"
|
||||
MAKE_CMD=ninja
|
||||
shift;;
|
||||
--sanitize-address | -fsanitize=address)
|
||||
SANITIZE_ADDRESS=True
|
||||
shift;;
|
||||
--ittiSIM)
|
||||
--ninja)
|
||||
CMAKE_CMD="$CMAKE_CMD -GNinja"
|
||||
MAKE_CMD=ninja
|
||||
shift;;
|
||||
--sanitize-address | -fsanitize=address)
|
||||
CMAKE_CMD="$CMAKE_CMD -DSANITIZE_ADDRESS=True"
|
||||
shift;;
|
||||
--ittiSIM)
|
||||
ittiSIM=1
|
||||
ITTI_SIM="True"
|
||||
CMAKE_CMD="$CMAKE_CMD -DITTI_SIM=True"
|
||||
echo_info "Will compile itti simulator"
|
||||
shift;;
|
||||
-h | --help)
|
||||
@@ -473,9 +482,6 @@ function main() {
|
||||
fi
|
||||
fi
|
||||
|
||||
CMAKE_CMD="$CMAKE_CMD .."
|
||||
echo_info "CMAKE_CMD=$CMAKE_CMD"
|
||||
|
||||
########################################################
|
||||
# Check validity of HW and TP parameters for eNB / gNB #
|
||||
########################################################
|
||||
@@ -515,6 +521,7 @@ function main() {
|
||||
#Disable CPU Affinity for deadline scheduler
|
||||
if [ "$DEADLINE_SCHEDULER_FLAG_USER" = "True" ] ; then
|
||||
CPU_AFFINITY_FLAG_USER="False"
|
||||
CMAKE_CMD="$CMAKE_CMD -DCPU_AFFINITY=False"
|
||||
fi
|
||||
|
||||
echo_info "Flags for Deadline scheduler: $DEADLINE_SCHEDULER_FLAG_USER"
|
||||
@@ -577,8 +584,7 @@ function main() {
|
||||
#fi
|
||||
fi
|
||||
echo_info "Installing protobuf/protobuf-c for flexran agent support"
|
||||
install_protobuf_from_source
|
||||
install_protobuf_c_from_source
|
||||
install_protobuf_c
|
||||
echo_success "protobuf/protobuf-c installation successful"
|
||||
fi
|
||||
|
||||
@@ -587,53 +593,6 @@ function main() {
|
||||
check_install_additional_tools
|
||||
fi
|
||||
|
||||
|
||||
|
||||
echo_info "3. building the compilation directives ..."
|
||||
|
||||
DIR=$OPENAIR_DIR/cmake_targets
|
||||
if [ "$T_TRACER" = "False" ] ; then
|
||||
build_dir=ran_build_noLOG
|
||||
else
|
||||
build_dir=ran_build
|
||||
fi
|
||||
|
||||
[ "$CLEAN" = "1" ] && rm -rf $DIR/$build_dir/build
|
||||
mkdir -p $DIR/$build_dir/build
|
||||
|
||||
# configuration module libraries, one currently available, using libconfig
|
||||
config_libconfig_shlib=params_libconfig
|
||||
|
||||
# first generate the CMakefile in the right directory
|
||||
# softmodem compilation
|
||||
|
||||
cmake_file=$DIR/$build_dir/CMakeLists.txt
|
||||
echo "cmake_minimum_required(VERSION 2.8)" > $cmake_file
|
||||
echo "project (OpenAirInterface)" >> $cmake_file
|
||||
echo "set ( CMAKE_BUILD_TYPE $CMAKE_BUILD_TYPE )" >> $cmake_file
|
||||
echo "set ( CFLAGS_PROCESSOR_USER \"$CFLAGS_PROCESSOR_USER\" )" >> $cmake_file
|
||||
echo "set ( UE_EXPANSION $UE_EXPANSION )" >> $cmake_file
|
||||
# echo "set ( PHY_TX_THREAD $UE_EXPANSION )" >> $cmake_file
|
||||
echo "set ( PRE_SCD_THREAD $UE_EXPANSION )" >> $cmake_file
|
||||
echo "set ( ENABLE_VCD_FIFO $VCD_TIMING )" >> $cmake_file
|
||||
echo "set ( RF_BOARD \"${HW}\")" >> $cmake_file
|
||||
echo "set ( TRANSP_PRO \"${TP}\")" >> $cmake_file
|
||||
echo "set ( PACKAGE_NAME \"${exec}\")" >> $cmake_file
|
||||
echo "set ( DEADLINE_SCHEDULER \"${DEADLINE_SCHEDULER_FLAG_USER}\" )" >> $cmake_file
|
||||
echo "set ( CPU_AFFINITY \"${CPU_AFFINITY_FLAG_USER}\" )" >> $cmake_file
|
||||
echo "set ( T_TRACER $T_TRACER )" >> $cmake_file
|
||||
echo "set ( UE_AUTOTEST_TRACE $UE_AUTOTEST_TRACE )" >> $cmake_file
|
||||
echo "set ( UE_DEBUG_TRACE $UE_DEBUG_TRACE )" >> $cmake_file
|
||||
echo "set ( UE_TIMING_TRACE $UE_TIMING_TRACE )" >> $cmake_file
|
||||
echo "set ( USRP_REC_PLAY $USRP_REC_PLAY )" >> $cmake_file
|
||||
echo "set ( NOAVX512 $NOAVX512 )" >> $cmake_file
|
||||
echo "set ( SKIP_SHARED_LIB_FLAG $SKIP_SHARED_LIB_FLAG )" >> $cmake_file
|
||||
echo "set ( ITTI_SIM $ITTI_SIM )" >> $cmake_file
|
||||
echo "set ( SANITIZE_ADDRESS $SANITIZE_ADDRESS )" >> $cmake_file
|
||||
echo 'include(${CMAKE_CURRENT_SOURCE_DIR}/../CMakeLists.txt)' >> $cmake_file
|
||||
cd $DIR/$build_dir/build
|
||||
eval $CMAKE_CMD
|
||||
|
||||
execlist=""
|
||||
if [ "$eNB" = "1" ] ; then
|
||||
execlist="$execlist lte-softmodem"
|
||||
@@ -653,15 +612,33 @@ function main() {
|
||||
if [ "$nrUE" = 1 ] ; then
|
||||
execlist="$execlist nr-uesoftmodem"
|
||||
fi
|
||||
|
||||
if [ "$ittiSIM" = "1" ] ; then
|
||||
execlist="$execlist nr-ittisim"
|
||||
fi
|
||||
|
||||
if [[ "$execlist" == "" && "$SIMUS_PHY" != "1" ]]; then
|
||||
echo_success "installing dependencies successful"
|
||||
exit
|
||||
fi
|
||||
|
||||
echo_info "3. building the compilation directives ..."
|
||||
|
||||
DIR=$OPENAIR_DIR/cmake_targets
|
||||
|
||||
[ "$CLEAN" = "1" ] && rm -rf $DIR/$BUILD_DIR/build
|
||||
mkdir -p $DIR/$BUILD_DIR/build
|
||||
|
||||
cd $DIR/$BUILD_DIR/build
|
||||
if [[ ${#CMAKE_C_FLAGS[@]} > 0 ]]; then CMAKE_CMD="$CMAKE_CMD -DCMAKE_C_FLAGS=\"${CMAKE_C_FLAGS[*]}\""; fi
|
||||
if [[ ${#CMAKE_CXX_FLAGS[@]} > 0 ]]; then CMAKE_CMD="$CMAKE_CMD -DCMAKE_CXX_FLAGS=\"${CMAKE_CXX_FLAGS[*]}\""; fi
|
||||
CMAKE_CMD="$CMAKE_CMD -DNOAVX512=\"${NOAVX512[*]}\""
|
||||
echo_info "running $CMAKE_CMD"
|
||||
eval $CMAKE_CMD ../..
|
||||
|
||||
for f in $execlist ; do
|
||||
echo_info "Compiling $f..."
|
||||
compilations \
|
||||
$build_dir $f \
|
||||
$BUILD_DIR $f \
|
||||
$f $dbin/$f.$REL
|
||||
done
|
||||
|
||||
@@ -670,13 +647,16 @@ function main() {
|
||||
|
||||
if [ "$SKIP_SHARED_LIB_FLAG" = "False" ]; then
|
||||
echo_info "Building shared libraries common to UE and gNB"
|
||||
|
||||
# configuration module libraries, one currently available, using libconfig
|
||||
config_libconfig_shlib=params_libconfig
|
||||
|
||||
compilations \
|
||||
$build_dir $config_libconfig_shlib \
|
||||
$BUILD_DIR $config_libconfig_shlib \
|
||||
lib$config_libconfig_shlib.so $dbin/lib$config_libconfig_shlib.so
|
||||
|
||||
compilations \
|
||||
$build_dir coding \
|
||||
$BUILD_DIR coding \
|
||||
libcoding.so $dbin/libcoding.so
|
||||
|
||||
fi
|
||||
@@ -689,7 +669,7 @@ function main() {
|
||||
then
|
||||
echo_info "Building ue_ip module"
|
||||
compilations \
|
||||
$build_dir ue_ip \
|
||||
$BUILD_DIR ue_ip \
|
||||
CMakeFiles/ue_ip/ue_ip.ko $dbin/ue_ip.ko
|
||||
else
|
||||
echo_info "Bypassing ue_ip build"
|
||||
@@ -706,7 +686,7 @@ function main() {
|
||||
mkdir -p $DIR/nas_sim_tools/build
|
||||
cd $DIR/nas_sim_tools/build
|
||||
|
||||
eval $CMAKE_CMD
|
||||
eval $CMAKE_CMD ..
|
||||
compilations \
|
||||
nas_sim_tools usim \
|
||||
usim $dbin/usim
|
||||
@@ -720,16 +700,16 @@ function main() {
|
||||
# generate USIM data
|
||||
if [ -f $dbin/conf2uedata ]; then
|
||||
install_nas_tools $conf_nvram_path $gen_nvram_path "$dlog/conf2uedata.txt"
|
||||
echo_info "Copying UE specific part to $DIR/$build_dir/build"
|
||||
cp -Rvf $dbin/.ue_emm.nvram0 $DIR/$build_dir/build
|
||||
cp -Rvf $dbin/.ue.nvram0 $DIR/$build_dir/build
|
||||
cp -Rvf $dbin/.usim.nvram0 $DIR/$build_dir/build
|
||||
echo_info "Copying UE specific part to $DIR/$BUILD_DIR/build"
|
||||
cp -Rvf $dbin/.ue_emm.nvram0 $DIR/$BUILD_DIR/build
|
||||
cp -Rvf $dbin/.ue.nvram0 $DIR/$BUILD_DIR/build
|
||||
cp -Rvf $dbin/.usim.nvram0 $DIR/$BUILD_DIR/build
|
||||
else
|
||||
echo_warning "not generated UE NAS files: binaries not found"
|
||||
fi
|
||||
fi
|
||||
|
||||
cd $DIR/$build_dir/build
|
||||
cd $DIR/$BUILD_DIR/build
|
||||
|
||||
##################
|
||||
# PHY simulators #
|
||||
@@ -747,9 +727,6 @@ function main() {
|
||||
compilations \
|
||||
ran_build coding \
|
||||
libcoding.so $dbin/libcoding.so
|
||||
# compilations \
|
||||
# lte-simulators $config_libconfig_shlib \
|
||||
# lib$config_libconfig_shlib.so $dbin/lib$config_libconfig_shlib.so
|
||||
fi
|
||||
|
||||
###################
|
||||
@@ -771,14 +748,14 @@ function main() {
|
||||
if [ "$HW" = "EXMIMO" ] ; then
|
||||
echo_info "Compiling Express MIMO 2 board drivers"
|
||||
compilations \
|
||||
$build_dir openair_rf \
|
||||
$BUILD_DIR openair_rf \
|
||||
CMakeFiles/openair_rf/openair_rf.ko $dbin/openair_rf.ko
|
||||
compilations \
|
||||
$build_dir updatefw \
|
||||
$BUILD_DIR updatefw \
|
||||
updatefw $dbin/updatefw
|
||||
echo_info "Compiling oarf tools. The logfile for compilation is here: $dlog/oarf.txt"
|
||||
make -C $OPENAIR_DIR/cmake_targets/$build_dir/build oarf > $dlog/oarf.txt 2>&1
|
||||
cp $OPENAIR_DIR/cmake_targets/$build_dir/build/*.oct $dbin
|
||||
make -C $OPENAIR_DIR/cmake_targets/$BUILD_DIR/build oarf > $dlog/oarf.txt 2>&1
|
||||
cp $OPENAIR_DIR/cmake_targets/$BUILD_DIR/build/*.oct $dbin
|
||||
if [ -s $dbin/oarf_config_exmimo.oct ] ; then
|
||||
echo_success "oarf tools compiled"
|
||||
else
|
||||
@@ -793,7 +770,7 @@ function main() {
|
||||
if [ ! -z "$BUILD_OPTLIB" ] ; then
|
||||
for oklib in $BUILD_OPTLIB ; do
|
||||
compilations \
|
||||
$build_dir $oklib \
|
||||
$BUILD_DIR $oklib \
|
||||
lib${oklib}.so $dbin/lib${oklib}.so
|
||||
done
|
||||
fi
|
||||
@@ -867,7 +844,7 @@ function main() {
|
||||
# link liboai_device.so with the selected RF device library
|
||||
if [ "$HW" == "EXMIMO" ] ; then
|
||||
compilations \
|
||||
$build_dir oai_exmimodevif \
|
||||
$BUILD_DIR oai_exmimodevif \
|
||||
liboai_exmimodevif.so $dbin/liboai_exmimodevif.so.$REL
|
||||
|
||||
ln -sf liboai_exmimodevif.so liboai_device.so
|
||||
@@ -875,7 +852,7 @@ function main() {
|
||||
echo_info "liboai_device.so is linked to EXMIMO device library"
|
||||
elif [ "$HW" == "OAI_USRP" ] ; then
|
||||
compilations \
|
||||
$build_dir oai_usrpdevif \
|
||||
$BUILD_DIR oai_usrpdevif \
|
||||
liboai_usrpdevif.so $dbin/liboai_usrpdevif.so.$REL
|
||||
|
||||
ln -sf liboai_usrpdevif.so liboai_device.so
|
||||
@@ -884,7 +861,7 @@ function main() {
|
||||
elif [ "$HW" == "OAI_BLADERF" ] ; then
|
||||
if [ -f "/usr/include/libbladeRF.h" ] ; then
|
||||
compilations \
|
||||
$build_dir oai_bladerfdevif \
|
||||
$BUILD_DIR oai_bladerfdevif \
|
||||
liboai_bladerfdevif.so $dbin/liboai_bladerfdevif.so.$REL
|
||||
fi
|
||||
|
||||
@@ -894,7 +871,7 @@ function main() {
|
||||
elif [ "$HW" == "OAI_LMSSDR" ] ; then
|
||||
# if [ -f "/usr/include/libbladeRF.h" ] ; then
|
||||
compilations \
|
||||
$build_dir oai_lmssdrdevif \
|
||||
$BUILD_DIR oai_lmssdrdevif \
|
||||
liboai_lmssdrdevif.so $dbin/liboai_lmssdrdevif.so.$REL
|
||||
# fi
|
||||
|
||||
@@ -903,7 +880,7 @@ function main() {
|
||||
echo_info "liboai_device.so is linked to LMSSDR device library"
|
||||
elif [ "$HW" == "OAI_IRIS" ] ; then
|
||||
compilations \
|
||||
$build_dir oai_irisdevif \
|
||||
$BUILD_DIR oai_irisdevif \
|
||||
liboai_irisdevif.so $dbin/liboai_irisdevif.so.$REL
|
||||
|
||||
ln -s liboai_irisdevif.so liboai_device.so
|
||||
@@ -923,7 +900,7 @@ function main() {
|
||||
echo_info "liboai_device.so is linked to ADRV9371_ZC706 device library for Kernel $SYRIQ_KMAJ.$SYRIQ_KMIN"
|
||||
elif [ "$HW" == "OAI_AW2SORI" ] ; then
|
||||
compilations \
|
||||
$build_dir aw2sori_transpro \
|
||||
$BUILD_DIR aw2sori_transpro \
|
||||
libaw2sori_transpro.so $dbin/libaw2sori_transpro.so.$REL
|
||||
|
||||
ln -sf libaw2sori_transpro.so libthirdparty_transpro.so
|
||||
@@ -938,13 +915,8 @@ function main() {
|
||||
if [ "$SKIP_SHARED_LIB_FLAG" = "False" ]; then
|
||||
echo_info "Compiling rfsimulator"
|
||||
compilations \
|
||||
$build_dir rfsimulator \
|
||||
$BUILD_DIR rfsimulator \
|
||||
librfsimulator.so $dbin/librfsimulator.so.$REL
|
||||
|
||||
echo_info "Compiling tcp_bridge_oai"
|
||||
compilations \
|
||||
$build_dir tcp_bridge_oai \
|
||||
libtcp_bridge_oai.so $dbin/libtcp_bridge_oai.so.$REL
|
||||
fi
|
||||
|
||||
#build transport protocol libraries (currently only ETHERNET is available)
|
||||
@@ -954,7 +926,7 @@ function main() {
|
||||
rm -f $dbin/liboai_transpro.so
|
||||
if [ "$TP" == "Ethernet" ]; then
|
||||
compilations \
|
||||
$build_dir oai_eth_transpro \
|
||||
$BUILD_DIR oai_eth_transpro \
|
||||
liboai_eth_transpro.so $dbin/liboai_eth_transpro.so.$REL
|
||||
ln -sf liboai_eth_transpro.so liboai_transpro.so
|
||||
ln -sf $dbin/liboai_eth_transpro.so.$REL $dbin/liboai_transpro.so
|
||||
@@ -962,7 +934,7 @@ function main() {
|
||||
fi
|
||||
if [ "$TP" == "benetel4g" ]; then
|
||||
compilations \
|
||||
$build_dir benetel_4g \
|
||||
$BUILD_DIR benetel_4g \
|
||||
libbenetel_4g.so $dbin/libbenetel_4g.$REL
|
||||
ln -sf libbenetel_4g.so liboai_transpro.so
|
||||
ln -sf $dbin/libbenetel_4g.so.$REL $dbin/liboai_transpro.so
|
||||
@@ -970,7 +942,7 @@ function main() {
|
||||
fi
|
||||
if [ "$TP" == "benetel5g" ]; then
|
||||
compilations \
|
||||
$build_dir benetel_5g \
|
||||
$BUILD_DIR benetel_5g \
|
||||
libbenetel_5g.so $dbin/libbenetel_5g.$REL
|
||||
ln -sf libbenetel_5g.so liboai_transpro.so
|
||||
ln -sf $dbin/libbenetel_5g.so.$REL $dbin/liboai_transpro.so
|
||||
@@ -991,7 +963,7 @@ function main() {
|
||||
[ "$CLEAN" = "1" ] && rm -rf $OPENAIR_DIR/cmake_targets/doxygen/build
|
||||
mkdir -p $OPENAIR_DIR/cmake_targets/doxygen/build
|
||||
cd $OPENAIR_DIR/cmake_targets/doxygen/build
|
||||
eval $CMAKE_CMD
|
||||
eval $CMAKE_CMD ..
|
||||
make doc
|
||||
) >& $doxygen_log
|
||||
fi
|
||||
|
||||
@@ -26,7 +26,6 @@ set ( LOG_NO_THREAD True )
|
||||
set ( DEADLINE_SCHEDULER False )
|
||||
set ( MAC_CONTEXT 1 )
|
||||
set ( MAX_NUM_CCs 1 )
|
||||
set ( MESSAGE_CHART_GENERATOR False)
|
||||
set ( MSG_PRINT False )
|
||||
set ( MU_RECEIVER False )
|
||||
set ( NAS_ADDRESS_FIX False )
|
||||
|
||||
@@ -1,499 +0,0 @@
|
||||
#!/bin/bash
|
||||
#/*
|
||||
# * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
|
||||
# * contributor license agreements. See the NOTICE file distributed with
|
||||
# * this work for additional information regarding copyright ownership.
|
||||
# * The OpenAirInterface Software Alliance licenses this file to You under
|
||||
# * the OAI Public License, Version 1.1 (the "License"); you may not use this file
|
||||
# * except in compliance with the License.
|
||||
# * You may obtain a copy of the License at
|
||||
# *
|
||||
# * http://www.openairinterface.org/?page_id=698
|
||||
# *
|
||||
# * Unless required by applicable law or agreed to in writing, software
|
||||
# * distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# * See the License for the specific language governing permissions and
|
||||
# * limitations under the License.
|
||||
# *-------------------------------------------------------------------------------
|
||||
# * For more information about the OpenAirInterface (OAI) Software Alliance:
|
||||
# * contact@openairinterface.org
|
||||
# */
|
||||
|
||||
# brief
|
||||
# authors Laurent Thomas
|
||||
#
|
||||
#######################################
|
||||
|
||||
if [ ! -f /etc/os-release ]; then
|
||||
echo "No /etc/os-release file found. You're likely on an unsupported distro."
|
||||
exit 1
|
||||
fi
|
||||
OS_DISTRO=$(grep "^ID=" /etc/os-release | sed "s/ID=//" | sed "s/\"//g")
|
||||
OS_RELEASE=$(grep "^VERSION_ID=" /etc/os-release | sed "s/VERSION_ID=//" | sed "s/\"//g")
|
||||
case "$OS_DISTRO" in
|
||||
ubuntu) OS_BASEDISTRO="debian"; INSTALLER="apt"; CMAKE="cmake" ;;
|
||||
esac
|
||||
|
||||
SUDO='sudo -E'
|
||||
|
||||
###############################
|
||||
## echo and family
|
||||
###############################
|
||||
black='\E[30m'
|
||||
red='\E[31m'
|
||||
green='\E[32m'
|
||||
yellow='\E[33m'
|
||||
blue='\E[1;34m'
|
||||
magenta='\E[35m'
|
||||
cyan='\E[36m'
|
||||
white='\E[37m'
|
||||
reset_color='\E[00m'
|
||||
COLORIZE=1
|
||||
|
||||
cecho() {
|
||||
# Color-echo
|
||||
# arg1 = message
|
||||
# arg2 = color
|
||||
local default_msg="No Message."
|
||||
message=${1:-$default_msg}
|
||||
color=${2:-$green}
|
||||
[ "$COLORIZE" = "1" ] && message="$color$message$reset_color"
|
||||
echo -e "$message"
|
||||
return
|
||||
}
|
||||
|
||||
echo_error() { cecho "$* $red" ;}
|
||||
echo_fatal() { cecho "$* $red"; exit 1 ;}
|
||||
echo_warning() { cecho "$* $yellow" ;}
|
||||
echo_success() { cecho "$* $green" ;}
|
||||
echo_info() { cecho "$* $blue" ;}
|
||||
|
||||
########################
|
||||
# distribution helpers #
|
||||
########################
|
||||
|
||||
# This function return a string to identify the distribution we are running
|
||||
# Examples:
|
||||
# ubuntu16.04
|
||||
# debian8.5
|
||||
get_distribution_release() {
|
||||
echo "$OS_DISTRO$OS_RELEASE"
|
||||
}
|
||||
|
||||
check_supported_distribution() {
|
||||
case $(get_distribution_release) in
|
||||
"ubuntu20.04") return 0 ;;
|
||||
"ubuntu20.10") return 0 ;;
|
||||
"ubuntu21.04") return 0 ;;
|
||||
esac
|
||||
return 1
|
||||
}
|
||||
|
||||
##################
|
||||
# Error handlers #
|
||||
##################
|
||||
|
||||
handler_EXIT() {
|
||||
local exit_code=$?
|
||||
[ "$exit_code" -eq 0 ] || echo_error "build have failed"
|
||||
exit $exit_code
|
||||
}
|
||||
|
||||
trap handler_EXIT EXIT
|
||||
|
||||
###########################
|
||||
# Cleaners
|
||||
###########################
|
||||
|
||||
clean_kernel() {
|
||||
$SUDO modprobe ip_tables
|
||||
$SUDO modprobe x_tables
|
||||
$SUDO iptables -P INPUT ACCEPT
|
||||
$SUDO iptables -F INPUT
|
||||
$SUDO iptables -P OUTPUT ACCEPT
|
||||
$SUDO iptables -F OUTPUT
|
||||
$SUDO iptables -P FORWARD ACCEPT
|
||||
$SUDO iptables -F FORWARD
|
||||
$SUDO iptables -t nat -F
|
||||
$SUDO iptables -t mangle -F
|
||||
$SUDO iptables -t filter -F
|
||||
$SUDO iptables -t raw -F
|
||||
echo_info "Flushed iptables"
|
||||
$SUDO rmmod nasmesh > /dev/null 2>&1
|
||||
$SUDO rmmod oai_nw_drv > /dev/null 2>&1
|
||||
$SUDO rmmod openair_rf > /dev/null 2>&1
|
||||
$SUDO rmmod ue_ip > /dev/null 2>&1
|
||||
echo_info "removed drivers from kernel"
|
||||
}
|
||||
|
||||
clean_all_files() {
|
||||
set_openair_env
|
||||
rm -rf "$OPENAIR_DIR"/targets/bin/*
|
||||
dir="$OPENAIR_DIR/cmake_targets"
|
||||
rm -rf "$dir"/log/*
|
||||
rm -rf "$dir"/ran_build/build
|
||||
rm -rf "$dir"/ran_build_noLOG/build
|
||||
rm -rf "$dir"/lte-simulators/build
|
||||
rm -rf "$dir"/nas_sim_tools/build
|
||||
rm -rf "$dir"/oaisim_build_oai/build
|
||||
rm -rf "$dir"/oaisim_build_oai/CMakeLists.txt
|
||||
rm -rf "$dir"/autotests/bin
|
||||
rm -rf "$dir"/autotests/log
|
||||
rm -rf "$dir"/autotests/*/build
|
||||
}
|
||||
|
||||
############################################
|
||||
# External packages installers
|
||||
############################################
|
||||
|
||||
install_protobuf_from_source(){
|
||||
protobuf_install_log=$OPENAIR_DIR/cmake_targets/log/protobuf_install_log.txt
|
||||
echo_info "\nInstalling Google Protobuf from sources. The log file for Protobuf installation is here: $protobuf_install_log "
|
||||
(
|
||||
cd /tmp || exit
|
||||
echo "Downloading protobuf"
|
||||
#rm -rf /tmp/protobuf-2.6.1.tar.gz* /tmp/protobuf-2.6.1
|
||||
#wget https://github.com/protocolbuffers/protobuf/releases/download/v2.6.1/protobuf-2.6.1.tar.gz
|
||||
#tar -xzvf protobuf-2.6.1.tar.gz --owner $USER --group $USER --no-same-owner
|
||||
#cd protobuf-2.6.1/
|
||||
rm -rf /tmp/protobuf-cpp-3.3.0.tar.gz* /tmp/protobuf-3.3.0
|
||||
wget --tries=3 --retry-connrefused https://github.com/protocolbuffers/protobuf/releases/download/v3.3.0/protobuf-cpp-3.3.0.tar.gz
|
||||
tar -xzvf protobuf-cpp-3.3.0.tar.gz --owner "$USER" --group "$(groups | cut -d" " -f1)" --no-same-owner
|
||||
cd protobuf-3.3.0/ || exit
|
||||
./configure
|
||||
echo "Compiling protobuf"
|
||||
make -j"$(nproc)"
|
||||
$SUDO make install
|
||||
$SUDO ldconfig
|
||||
) >& "$protobuf_install_log"
|
||||
}
|
||||
|
||||
install_protobuf_c_from_source(){
|
||||
protobuf_c_install_log=$OPENAIR_DIR/cmake_targets/log/protobuf_c_install_log.txt
|
||||
echo_info "\nInstalling Google Protobuf_C from sources. The log file for Protobuf_C installation is here: $protobuf_c_install_log "
|
||||
(
|
||||
if [[ "$OS_DISTRO" == "rhel" ]] || [[ "$OS_DISTRO" == "centos" ]]; then
|
||||
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
|
||||
fi
|
||||
cd /tmp || exit
|
||||
echo "Downloading protobuf-c"
|
||||
rm -rf /tmp/protobuf-c
|
||||
git clone https://github.com/protobuf-c/protobuf-c.git
|
||||
cd protobuf-c || exit
|
||||
git checkout 2a46af42784abf86804d536f6e0122d47cfeea45
|
||||
./autogen.sh
|
||||
./configure
|
||||
echo "Compiling protobuf-c"
|
||||
make -j"$(nproc)"
|
||||
$SUDO make install
|
||||
$SUDO ldconfig
|
||||
) >& "$protobuf_c_install_log"
|
||||
}
|
||||
|
||||
install_usrp_uhd_driver_from_source(){
|
||||
uhd_install_log=$OPENAIR_DIR/cmake_targets/log/uhd_install_log.txt
|
||||
echo_info "\nInstalling UHD driver from sources. The log file for UHD driver installation is here: $uhd_install_log "
|
||||
(
|
||||
cd /tmp || exit
|
||||
echo "Downloading UHD driver"
|
||||
rm -rf /tmp/uhd
|
||||
git clone https://github.com/EttusResearch/uhd.git
|
||||
cd uhd || exit
|
||||
git checkout UHD-3.15.LTS
|
||||
mkdir -p host/build
|
||||
cd host/build || exit
|
||||
$CMAKE ../ -GNinja
|
||||
echo "Compiling UHD"
|
||||
ninja
|
||||
$SUDO ninja install
|
||||
$SUDO ldconfig
|
||||
$SUDO /usr/lib/uhd/utils/uhd_images_downloader.py
|
||||
) >& "$uhd_install_log"
|
||||
}
|
||||
|
||||
install_bladerf_driver_from_source(){
|
||||
bladerf_install_log=$OPENAIR_DIR/cmake_targets/log/bladerf_install_log.txt
|
||||
echo_info "\nInstalling BladeRF driver from sources. The log file for BladeRF driver installation is here: $bladerf_install_log "
|
||||
(
|
||||
cd /tmp || exit
|
||||
echo "Downloading BladeRF driver"
|
||||
rm -rf /tmp/bladeRF
|
||||
git clone https://github.com/Nuand/bladeRF.git
|
||||
cd bladeRF || exit
|
||||
git checkout tags/2016.06
|
||||
mkdir -p build
|
||||
cd build || exit
|
||||
$CMAKE ../
|
||||
echo "Compiling BladeRF driver"
|
||||
make -j"$(nproc)"
|
||||
$SUDO make install
|
||||
$SUDO ldconfig
|
||||
echo "Downloading FPGA and firmware images"
|
||||
cd /tmp/bladeRF || exit
|
||||
wget --tries=3 --retry-connrefused https://www.nuand.com/fx3/bladeRF_fw_latest.img
|
||||
wget --tries=3 --retry-connrefused https://www.nuand.com/fpga/hostedx40-latest.rbf
|
||||
sudo mkdir -p /usr/share/Nuand/bladeRF
|
||||
sudo mv bladeRF_fw_latest.img /usr/share/Nuand/bladeRF/bladeRF_fw.img
|
||||
sudo mv hostedx40-latest.rbf /usr/share/Nuand/bladeRF/hostedx40.rbf
|
||||
) >& "$bladerf_install_log"
|
||||
}
|
||||
|
||||
check_install_bladerf_driver(){
|
||||
if [[ "$OS_DISTRO" == "ubuntu" ]]; then
|
||||
$SUDO apt-get install -y bladerf libbladerf-dev
|
||||
$SUDO apt-get install -y bladerf-firmware-fx3
|
||||
$SUDO apt-get install -y bladerf-fpga-hostedx40
|
||||
elif [[ "$OS_BASEDISTRO" == "fedora" ]]; then
|
||||
install_bladerf_driver_from_source
|
||||
else
|
||||
echo_error "BladeRF Installer for OAI does not support automatic build. Install BladeRF compiling sources manually from BladeRF website"
|
||||
fi
|
||||
}
|
||||
|
||||
flash_firmware_bladerf() {
|
||||
$SUDO bladeRF-cli --flash-firmware /usr/share/Nuand/bladeRF/bladeRF_fw.img
|
||||
}
|
||||
|
||||
install_soapy_from_source(){
|
||||
soapy_install_log=$OPENAIR_DIR/cmake_targets/log/soapy_install_log.txt
|
||||
echo_info "\nInstalling Soapy EcoSystem from source. The log file for Soapy installation is here: $soapy_install_log "
|
||||
(
|
||||
cd /tmp || exit
|
||||
echo "Downloading SoapySDR"
|
||||
rm -rf /tmp/soapysdr
|
||||
git clone -b soapy-sdr-0.7.0 --single-branch https://github.com/pothosware/SoapySDR.git
|
||||
cd SoapySDR || exit
|
||||
#git checkout tags/release_003_010_001_001
|
||||
mkdir -p build
|
||||
cd build || exit
|
||||
$CMAKE ../
|
||||
echo "Compiling SoapySDR"
|
||||
make -j"$(nproc)"
|
||||
$SUDO make install
|
||||
$SUDO ldconfig
|
||||
cd /tmp || exit
|
||||
echo "Downloading SoapyRemote"
|
||||
rm -rf /tmp/soapyremote
|
||||
git clone -b soapy-remote-0.5.0 --single-branch https://github.com/pothosware/SoapyRemote.git
|
||||
cd SoapyRemote || exit
|
||||
#git checkout tags/release_003_010_001_001
|
||||
mkdir -p build
|
||||
cd build || exit
|
||||
cmake ../
|
||||
echo "Compiling SoapyRemote"
|
||||
make -j"$(nproc)"
|
||||
$SUDO make install
|
||||
$SUDO ldconfig
|
||||
) >& "$soapy_install_log"
|
||||
}
|
||||
|
||||
install_soapy_iris_from_source(){
|
||||
iris_install_log=$OPENAIR_DIR/cmake_targets/log/iris_install_log.txt
|
||||
echo_info "\nInstalling Iris driver from source. The log file for Iris driver installation is here: $iris_install_log "
|
||||
(
|
||||
cd /tmp || exit
|
||||
echo "Downloading SoapyIris"
|
||||
rm -rf /tmp/sklk-soapyiris
|
||||
git clone -b soapy-iris-2018.08.0.1 --single-branch https://github.com/skylarkwireless/sklk-soapyiris.git
|
||||
cd sklk-soapyiris || exit
|
||||
mkdir -p build
|
||||
cd build ||exit
|
||||
cmake ../
|
||||
echo "Compiling SoapyIris"
|
||||
make -j"$(nproc)"
|
||||
$SUDO make install
|
||||
$SUDO ldconfig
|
||||
) >& "$iris_install_log"
|
||||
}
|
||||
|
||||
check_install_soapy () {
|
||||
#if [[ "$OS_DISTRO" == "ubuntu" ]]; then
|
||||
#first we remove old installation
|
||||
$SUDO apt-get remove -y soapysdr soapysdr-server libsoapysdr-dev python-soapysdr python3-soapysdr soapysdr-module-remote || true
|
||||
#$SUDO add-apt-repository -y ppa:myriadrf/drivers
|
||||
#$SUDO apt-get update
|
||||
#$SUDO apt-get install -y soapysdr soapysdr-server libsoapysdr-dev python-soapysdr python3-soapysdr soapysdr-module-remote
|
||||
|
||||
#elif [[ "$OS_BASEDISTRO" == "fedora" ]]; then
|
||||
# $SUDO $INSTALLER -y install software-properties-common python3-software-properties python-software-properties subversion git python3 python-numpy python3-numpy cmake swig python-dev
|
||||
install_soapy_from_source
|
||||
#fi
|
||||
install_soapy_iris_from_source
|
||||
|
||||
}
|
||||
|
||||
check_install_ubuntu_packages() {
|
||||
$SUDO $INSTALLER update -y
|
||||
if [[ "$OS_DISTRO" == "ubuntu" ]]; then
|
||||
local LAPACK_LIBNAME="liblapack.so"
|
||||
local LAPACK_TARGET="/usr/lib/atlas-base/atlas/liblapack.so"
|
||||
$SUDO apt install -y software-properties-common
|
||||
case "$(get_distribution_release)" in
|
||||
"ubuntu20.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev iproute2 libconfig-dev"
|
||||
LAPACK_LIBNAME="liblapack.so-x86_64-linux-gnu"
|
||||
LAPACK_TARGET="/usr/lib/x86_64-linux-gnu/atlas/liblapack.so"
|
||||
;;
|
||||
"ubuntu21.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev iproute2 libconfig-dev"
|
||||
LAPACK_LIBNAME="liblapack.so-x86_64-linux-gnu"
|
||||
LAPACK_TARGET="/usr/lib/x86_64-linux-gnu/atlas/liblapack.so"
|
||||
;;
|
||||
esac
|
||||
$SUDO $INSTALLER install -y \
|
||||
$specific_packages \
|
||||
check \
|
||||
dialog \
|
||||
dkms \
|
||||
gawk \
|
||||
libboost-all-dev \
|
||||
libpthread-stubs0-dev \
|
||||
openvpn \
|
||||
pkg-config \
|
||||
python3-dev \
|
||||
sshfs \
|
||||
swig \
|
||||
tshark \
|
||||
uml-utilities \
|
||||
unzip \
|
||||
valgrind \
|
||||
vlan \
|
||||
exuberant-ctags \
|
||||
ntpdate \
|
||||
iperf3 \
|
||||
android-tools-adb \
|
||||
wvdial \
|
||||
sshpass \
|
||||
nscd \
|
||||
bc \
|
||||
ntp \
|
||||
python3-scipy \
|
||||
python3-matplotlib \
|
||||
bison \
|
||||
build-essential \
|
||||
cmake \
|
||||
cmake-curses-gui \
|
||||
ninja-build \
|
||||
doxygen \
|
||||
doxygen-gui \
|
||||
texlive-latex-base \
|
||||
ethtool \
|
||||
flex \
|
||||
gdb \
|
||||
git \
|
||||
graphviz \
|
||||
gtkwave \
|
||||
iperf \
|
||||
iptables \
|
||||
libxtables-dev \
|
||||
libatlas-base-dev \
|
||||
libblas-dev \
|
||||
liblapack-dev\
|
||||
liblapacke-dev\
|
||||
libffi-dev \
|
||||
libforms-bin \
|
||||
libforms-dev \
|
||||
libgcrypt20-dev \
|
||||
libgmp-dev \
|
||||
libgtk-3-dev \
|
||||
libidn2-0-dev \
|
||||
libidn11-dev \
|
||||
libmysqlclient-dev \
|
||||
libpython2.7-dev \
|
||||
libsctp1 \
|
||||
libsctp-dev \
|
||||
libssl-dev \
|
||||
libtool \
|
||||
libusb-1.0-0-dev \
|
||||
libxml2 \
|
||||
libxml2-dev \
|
||||
libxslt1-dev \
|
||||
mscgen \
|
||||
octave-signal \
|
||||
openssh-client \
|
||||
openssh-server \
|
||||
openssl \
|
||||
python3 \
|
||||
subversion \
|
||||
xmlstarlet \
|
||||
python3-pip \
|
||||
libyaml-dev \
|
||||
wget \
|
||||
libxpm-dev \
|
||||
libboost-all-dev \
|
||||
nettle-dev \
|
||||
nettle-bin \
|
||||
libreadline-dev
|
||||
fi
|
||||
|
||||
$SUDO update-alternatives --set "$LAPACK_LIBNAME" "$LAPACK_TARGET"
|
||||
|
||||
}
|
||||
|
||||
install_asn1c_from_source(){
|
||||
asn1_install_log=$OPENAIR_DIR/cmake_targets/log/asn1c_install_log.txt
|
||||
echo_info "\nInstalling ASN1. The log file for ASN1 installation is here: $asn1_install_log "
|
||||
(
|
||||
$SUDO rm -rf /tmp/asn1c
|
||||
# GIT_SSL_NO_VERIFY=true git clone https://gitlab.eurecom.fr/oai/asn1c.git /tmp/asn1c
|
||||
git clone https://gitlab.eurecom.fr/oai/asn1c.git /tmp/asn1c
|
||||
cd /tmp/asn1c || exit
|
||||
# better to use a given commit than a branch in case the branch
|
||||
# is updated and requires modifications in the source of OAI
|
||||
#git checkout velichkov_s1ap_plus_option_group
|
||||
git checkout f12568d617dbf48497588f8e227d70388fa217c9
|
||||
autoreconf -iv
|
||||
./configure
|
||||
make -j"$(nproc)"
|
||||
$SUDO make install
|
||||
cd - || exit
|
||||
$SUDO ldconfig
|
||||
) > "$asn1_install_log" 2>&1
|
||||
}
|
||||
|
||||
################################
|
||||
# set_openair_env
|
||||
###############################
|
||||
set_openair_env(){
|
||||
fullpath=$(readlink -f "${BASH_SOURCE[0]}")
|
||||
[ -f "/.$fullpath" ] || fullpath=$(readlink -f "$PWD/$fullpath")
|
||||
openair_path=${fullpath%/cmake_targets/*}
|
||||
openair_path=${openair_path%/targets/*}
|
||||
openair_path=${openair_path%/openair[123]/*}
|
||||
export OPENAIR_DIR=$openair_path
|
||||
export OPENAIR1_DIR=$openair_path/openair1
|
||||
export OPENAIR2_DIR=$openair_path/openair2
|
||||
export OPENAIR3_DIR=$openair_path/openair3
|
||||
export OPENAIR_TARGETS=$openair_path/targets
|
||||
}
|
||||
|
||||
if ! check_supported_distribution; then
|
||||
echo_error "Your distribution $(get_distribution_release) is not supported by oai !"
|
||||
exit 1
|
||||
fi
|
||||
set_openair_env
|
||||
echo_info "Installing packages"
|
||||
check_install_ubuntu_packages
|
||||
|
||||
echo_info "installing ASN.1 compiler"
|
||||
install_asn1c_from_source
|
||||
|
||||
echo_info "installing protobuf/protobuf-c for flexran agent support"
|
||||
install_protobuf_from_source
|
||||
install_protobuf_c_from_source
|
||||
|
||||
if [ "$1" == "USRP" ] ; then
|
||||
echo_info "installing packages for USRP support"
|
||||
install_usrp_uhd_driver
|
||||
fi
|
||||
if [ "$1" == "BLADERF" ] ; then
|
||||
echo_info "installing packages for BLADERF support"
|
||||
check_install_bladerf_driver
|
||||
flash_firmware_bladerf
|
||||
fi
|
||||
if [ "$1" == "IRIS" ] ; then
|
||||
echo_info "installing packages for IRIS support"
|
||||
check_install_soapy
|
||||
# flash_firmware_iris
|
||||
fi
|
||||
@@ -0,0 +1,98 @@
|
||||
###########################################
|
||||
# macros to define options as there is numerous options in oai
|
||||
################################################
|
||||
macro(add_option name val helpstr)
|
||||
if(DEFINED ${name})
|
||||
set(value ${${name}})
|
||||
else(DEFINED ${name})
|
||||
set(value ${val})
|
||||
endif()
|
||||
set(${name} ${value} CACHE STRING "${helpstr}")
|
||||
add_definitions("-D${name}=${value}")
|
||||
endmacro(add_option)
|
||||
|
||||
macro(add_boolean_option name val helpstr)
|
||||
if(DEFINED ${name})
|
||||
set(value ${${name}})
|
||||
else(DEFINED ${name})
|
||||
set(value ${val})
|
||||
endif()
|
||||
set(${name} ${value} CACHE STRING "${helpstr}")
|
||||
set_property(CACHE ${name} PROPERTY TYPE BOOL)
|
||||
if (${value})
|
||||
add_definitions("-D${name}")
|
||||
endif (${value})
|
||||
endmacro(add_boolean_option)
|
||||
|
||||
macro(add_integer_option name val helpstr)
|
||||
if(DEFINED ${name})
|
||||
set(value ${${name}})
|
||||
else(DEFINED ${name})
|
||||
set(value ${val})
|
||||
endif()
|
||||
set(${name} ${value} CACHE STRING "${helpstr}")
|
||||
add_definitions("-D${name}=${value}")
|
||||
endmacro(add_integer_option)
|
||||
|
||||
macro(add_list1_option name val helpstr)
|
||||
if(DEFINED ${name})
|
||||
set(value ${${name}})
|
||||
else(DEFINED ${name})
|
||||
set(value ${val})
|
||||
endif()
|
||||
set(${name} ${value} CACHE STRING "${helpstr}")
|
||||
set_property(CACHE ${name} PROPERTY STRINGS ${ARGN})
|
||||
if(NOT "${value}" STREQUAL "False")
|
||||
add_definitions("-D${name}=${value}")
|
||||
endif()
|
||||
endmacro(add_list1_option)
|
||||
|
||||
macro(add_list2_option name val helpstr)
|
||||
if(DEFINED ${name})
|
||||
set(value ${${name}})
|
||||
else(DEFINED ${name})
|
||||
set(value ${val})
|
||||
endif()
|
||||
set(${name} ${value} CACHE STRING "${helpstr}")
|
||||
set_property(CACHE ${name} PROPERTY STRINGS ${ARGN})
|
||||
if(NOT "${value}" STREQUAL "False")
|
||||
add_definitions("-D${value}=1")
|
||||
endif()
|
||||
endmacro(add_list2_option)
|
||||
|
||||
macro(add_list_string_option name val helpstr)
|
||||
if(DEFINED ${name})
|
||||
set(value ${${name}})
|
||||
else(DEFINED ${name})
|
||||
set(value ${val})
|
||||
endif()
|
||||
set(${name} ${value} CACHE STRING "${helpstr}")
|
||||
set_property(CACHE ${name} PROPERTY STRINGS ${ARGN})
|
||||
if(NOT "${value}" STREQUAL "False")
|
||||
add_definitions("-D${name}=\"${value}\"")
|
||||
endif()
|
||||
endmacro(add_list_string_option)
|
||||
|
||||
# this function should produce the same value as the macro MAKE_VERSION defined in the C code (file types.h)
|
||||
function(make_version VERSION_VALUE)
|
||||
math(EXPR RESULT "0")
|
||||
foreach (ARG ${ARGN})
|
||||
math(EXPR RESULT "${RESULT} * 16 + ${ARG}")
|
||||
endforeach()
|
||||
set(${VERSION_VALUE} "${RESULT}" PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
macro(compile_asn1 asn1Source asn1cCmd ResultFlag)
|
||||
# Warning: if you modify ASN.1 source file to generate new C files, cmake should be re-run instead of make
|
||||
execute_process(COMMAND ${asn1cCmd} ${asn1Source} RESULT_VARIABLE ret)
|
||||
|
||||
if (NOT ${ret} STREQUAL 0)
|
||||
message(FATAL_ERROR "${ret}: error")
|
||||
endif (NOT ${ret} STREQUAL 0)
|
||||
|
||||
add_custom_target (
|
||||
${ResultFlag} ALL
|
||||
${asn1cCmd} ${asn1Source}
|
||||
DEPENDS ${asn1Source}
|
||||
)
|
||||
endmacro(compile_asn1)
|
||||
@@ -26,7 +26,6 @@ set ( LOG_NO_THREAD True )
|
||||
set ( DEADLINE_SCHEDULER False )
|
||||
set ( MAC_CONTEXT 1 )
|
||||
set ( MAX_NUM_CCs 1 )
|
||||
set ( MESSAGE_CHART_GENERATOR False)
|
||||
set ( MSG_PRINT False )
|
||||
set ( MU_RECEIVER False )
|
||||
set ( NAS_ADDRESS_FIX False )
|
||||
|
||||
@@ -103,12 +103,12 @@ get_distribution_release() {
|
||||
check_supported_distribution() {
|
||||
local distribution=$(get_distribution_release)
|
||||
case "$distribution" in
|
||||
"ubuntu22.04") return 0 ;;
|
||||
"ubuntu21.04") return 0 ;;
|
||||
"ubuntu20.04") return 0 ;;
|
||||
"ubuntu18.04") return 0 ;;
|
||||
"ubuntu17.10") return 0 ;;
|
||||
"ubuntu17.04") return 0 ;;
|
||||
"ubuntu16.04") return 0 ;;
|
||||
"ubuntu14.04") return 0 ;;
|
||||
"fedora24") return 0 ;;
|
||||
"fedora35") return 0 ;;
|
||||
"rhel7") return 0 ;;
|
||||
"rhel7.6") return 0 ;;
|
||||
"rhel7.7") return 0 ;;
|
||||
@@ -315,6 +315,26 @@ install_protobuf_c_from_source(){
|
||||
) >& $protobuf_c_install_log
|
||||
}
|
||||
|
||||
install_protobuf_c() {
|
||||
local protobuf_packages=""
|
||||
case "$(get_distribution_release)" in
|
||||
"ubuntu18.04" | "ubuntu20.04" | "ubuntu21.04" | "ubuntu22.04")
|
||||
protobuf_packages="protobuf-c-compiler libprotobuf-c1 libprotobuf-c-dev"
|
||||
;;
|
||||
esac
|
||||
case "$OS_DISTRO" in
|
||||
"rhel" | "centos" | "fedora") # in EPEL and Fedora repos (at least as of 35)
|
||||
protobuf_packages="protobuf-c-compiler protobuf-c protobuf-c-devel"
|
||||
;;
|
||||
esac
|
||||
if [[ "$protobuf_packages" == "" ]]; then
|
||||
install_protobuf_from_source
|
||||
install_protobuf_c_from_source
|
||||
else
|
||||
$SUDO $INSTALLER -y install $protobuf_packages
|
||||
fi
|
||||
}
|
||||
|
||||
install_usrp_uhd_driver_from_source(){
|
||||
uhd_install_log=$OPENAIR_DIR/cmake_targets/log/uhd_install_log.txt
|
||||
echo_info "\nInstalling UHD driver from sources. The log file for UHD driver installation is here: $uhd_install_log "
|
||||
@@ -471,10 +491,6 @@ install_bladerf_driver_from_source(){
|
||||
|
||||
check_install_bladerf_driver(){
|
||||
if [[ "$OS_DISTRO" == "ubuntu" ]]; then
|
||||
if [ "$(get_distribution_release)" == "ubuntu14.04" ] ; then
|
||||
$SUDO add-apt-repository -y ppa:bladerf/bladerf
|
||||
$SUDO apt-get update
|
||||
fi
|
||||
$SUDO apt-get install -y bladerf libbladerf-dev
|
||||
$SUDO apt-get install -y bladerf-firmware-fx3
|
||||
$SUDO apt-get install -y bladerf-fpga-hostedx40
|
||||
@@ -574,7 +590,16 @@ check_install_soapy () {
|
||||
|
||||
check_install_additional_tools (){
|
||||
$SUDO $INSTALLER update -y
|
||||
local optional_packages=""
|
||||
if [[ "$OS_DISTRO" == "ubuntu" ]]; then
|
||||
case "$(get_distribution_release)" in
|
||||
"ubuntu16.04"| "ubuntu18.04")
|
||||
optional_packages="python-dev python-pexpect python-numpy python-scipy python-matplotlib ctags"
|
||||
;;
|
||||
"ubuntu20.04" | "ubuntu21.04" | "ubuntu22.04" )
|
||||
optional_packages="python3 python3-pip python3-dev python3-scipy python3-matplotlib universal-ctags"
|
||||
;;
|
||||
esac
|
||||
PACKAGE_LIST="\
|
||||
check \
|
||||
dialog \
|
||||
@@ -584,8 +609,6 @@ check_install_additional_tools (){
|
||||
libpthread-stubs0-dev \
|
||||
openvpn \
|
||||
pkg-config \
|
||||
python-dev \
|
||||
python-pexpect \
|
||||
sshfs \
|
||||
swig \
|
||||
tshark \
|
||||
@@ -593,18 +616,14 @@ check_install_additional_tools (){
|
||||
unzip \
|
||||
valgrind \
|
||||
vlan \
|
||||
ctags \
|
||||
ntpdate \
|
||||
iperf3 \
|
||||
android-tools-adb \
|
||||
wvdial \
|
||||
python-numpy \
|
||||
sshpass \
|
||||
nscd \
|
||||
bc \
|
||||
ntp \
|
||||
python-scipy \
|
||||
python-matplotlib"
|
||||
ntp"
|
||||
elif [[ "$OS_DISTRO" == "rhel" ]] || [[ "$OS_DISTRO" == "centos" ]]; then
|
||||
PACKAGE_LIST="\
|
||||
check \
|
||||
@@ -650,22 +669,19 @@ check_install_additional_tools (){
|
||||
valgrind \
|
||||
vconfig \
|
||||
ctags \
|
||||
ntpdate \
|
||||
ntpsec \
|
||||
iperf3 \
|
||||
wvdial \
|
||||
python-numpy \
|
||||
sshpass \
|
||||
nscd \
|
||||
python2-paramiko \
|
||||
python-paramiko \
|
||||
python-pyroute2 \
|
||||
python-netifaces \
|
||||
python2-scipy \
|
||||
python2-matplotlib"
|
||||
python-scipy \
|
||||
python-matplotlib"
|
||||
fi
|
||||
$SUDO $INSTALLER install -y $PACKAGE_LIST
|
||||
|
||||
$SUDO rm -fr /opt/ssh
|
||||
$SUDO GIT_SSL_NO_VERIFY=true git clone https://gitlab.eurecom.fr/oai/ssh.git /opt/ssh
|
||||
$SUDO $INSTALLER install -y $PACKAGE_LIST $optional_packages
|
||||
|
||||
#The packages below are already installed for Redhat distros (RHEL, CentOS, Fedora)
|
||||
if [[ "$OS_DISTRO" == "ubuntu" ]]; then
|
||||
@@ -696,25 +712,26 @@ check_install_oai_software() {
|
||||
local LAPACK_TARGET="/usr/lib/atlas-base/atlas/liblapack.so"
|
||||
$SUDO apt install -y software-properties-common
|
||||
case "$(get_distribution_release)" in
|
||||
"ubuntu14.04")
|
||||
specific_packages="libtasn1-3-dev libgnutls-dev libatlas-dev iproute libconfig8-dev"
|
||||
# For iperf3
|
||||
$SUDO add-apt-repository "deb http://archive.ubuntu.com/ubuntu trusty-backports universe"
|
||||
$SUDO apt-get update
|
||||
;;
|
||||
"ubuntu16.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls-dev libatlas-dev iproute libconfig8-dev"
|
||||
specific_packages="libtasn1-6-dev libgnutls-dev libatlas-dev iproute libconfig8-dev iptables-dev libgcrypt11-dev python-pip pydb python guile-2.0-dev"
|
||||
;;
|
||||
"ubuntu17.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev libatlas-dev iproute libconfig8-dev"
|
||||
;;
|
||||
"ubuntu17.10")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev iproute libconfig8-dev"
|
||||
"ubuntu18.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev iproute2 libconfig-dev iptables-dev libgcrypt11-dev python-pip pydb python guile-2.0-dev"
|
||||
LAPACK_LIBNAME="liblapack.so-x86_64-linux-gnu"
|
||||
LAPACK_TARGET="/usr/lib/x86_64-linux-gnu/atlas/liblapack.so"
|
||||
;;
|
||||
"ubuntu18.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev iproute2 libconfig-dev"
|
||||
"ubuntu20.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev iproute2 libconfig-dev python guile-2.0-dev"
|
||||
LAPACK_LIBNAME="liblapack.so-x86_64-linux-gnu"
|
||||
LAPACK_TARGET="/usr/lib/x86_64-linux-gnu/atlas/liblapack.so"
|
||||
;;
|
||||
"ubuntu21.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev iproute2 libconfig-dev python guile-2.0-dev"
|
||||
LAPACK_LIBNAME="liblapack.so-x86_64-linux-gnu"
|
||||
LAPACK_TARGET="/usr/lib/x86_64-linux-gnu/atlas/liblapack.so"
|
||||
;;
|
||||
"ubuntu22.04")
|
||||
specific_packages="libtasn1-6-dev libgnutls28-dev iproute2 libconfig-dev python2 guile-2.2-dev"
|
||||
LAPACK_LIBNAME="liblapack.so-x86_64-linux-gnu"
|
||||
LAPACK_TARGET="/usr/lib/x86_64-linux-gnu/atlas/liblapack.so"
|
||||
;;
|
||||
@@ -734,22 +751,21 @@ check_install_oai_software() {
|
||||
texlive-latex-base \
|
||||
ethtool \
|
||||
flex \
|
||||
g++ \
|
||||
gcc \
|
||||
gdb \
|
||||
git \
|
||||
graphviz \
|
||||
gtkwave \
|
||||
guile-2.0-dev \
|
||||
iperf \
|
||||
iptables \
|
||||
iptables-dev \
|
||||
libatlas-base-dev \
|
||||
libblas-dev \
|
||||
liblapack-dev\
|
||||
liblapacke-dev\
|
||||
liblapack-dev \
|
||||
liblapacke-dev \
|
||||
libffi-dev \
|
||||
libforms-bin \
|
||||
libforms-dev \
|
||||
libgcrypt11-dev \
|
||||
libgmp-dev \
|
||||
libgtk-3-dev \
|
||||
libidn2-0-dev \
|
||||
@@ -765,16 +781,12 @@ check_install_oai_software() {
|
||||
libxml2 \
|
||||
libxml2-dev \
|
||||
libxslt1-dev \
|
||||
mscgen \
|
||||
octave-signal \
|
||||
openssh-client \
|
||||
openssh-server \
|
||||
openssl \
|
||||
python \
|
||||
subversion \
|
||||
xmlstarlet \
|
||||
python-pip \
|
||||
pydb \
|
||||
libyaml-dev \
|
||||
wget \
|
||||
libxpm-dev \
|
||||
@@ -792,8 +804,6 @@ check_install_oai_software() {
|
||||
$SUDO $INSTALLER install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
|
||||
fi
|
||||
$SUDO $INSTALLER install -y python-epdb vim-common
|
||||
else
|
||||
$SUDO $INSTALLER install -y mscgen pydb
|
||||
fi
|
||||
|
||||
$SUDO $INSTALLER install -y \
|
||||
@@ -805,6 +815,8 @@ check_install_oai_software() {
|
||||
doxygen \
|
||||
ethtool \
|
||||
flex \
|
||||
g++ \
|
||||
gcc \
|
||||
gdb \
|
||||
git \
|
||||
graphviz \
|
||||
@@ -861,8 +873,6 @@ check_install_oai_software() {
|
||||
fi
|
||||
|
||||
install_asn1c_from_source $1
|
||||
$SUDO rm -fr /opt/ssh
|
||||
$SUDO git clone https://gist.github.com/2190472.git /opt/ssh
|
||||
}
|
||||
|
||||
install_asn1c_from_source(){
|
||||
@@ -956,23 +966,3 @@ do
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
|
||||
# get from http://www.linuxjournal.com/content/validating-ip-address-bash-script
|
||||
validate_ip() {
|
||||
|
||||
local ip=$1
|
||||
local stat=1
|
||||
|
||||
if [[ $ip =~ ^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]]; then
|
||||
OIFS=$IFS
|
||||
IFS='.'
|
||||
ip=($ip)
|
||||
IFS=$OIFS
|
||||
[[ ${ip[0]} -le 255 && ${ip[1]} -le 255 \
|
||||
&& ${ip[2]} -le 255 && ${ip[3]} -le 255 ]]
|
||||
stat=$?
|
||||
fi
|
||||
|
||||
return $stat
|
||||
}
|
||||
|
||||
@@ -85,18 +85,7 @@ Tools available:
|
||||
|
||||
1) itti_analyser (list messages exchanged between protocol layers)
|
||||
2) xforms (Layer 1)
|
||||
3) mscgen (under construction, but can give some results now)
|
||||
(http://www.mcternan.me.uk/mscgen/)
|
||||
We use the software to generate sequence diagrams
|
||||
with traces generated during the execution of the eNB.
|
||||
After the enb execution:
|
||||
yang@yang:...$ cd /tmp
|
||||
yang@yang:/tmp$ /home/yang/openair4G/trunk/targets/SCRIPTS/msc_gen.py
|
||||
The results are located in the current directory (/tmp in this example) in a folder. The name of the folder
|
||||
is the current date (for example: 2015-04-08_20.34.10).
|
||||
The results are input files for the mscgen tool containing events or messages and the
|
||||
corresponding generated png files.
|
||||
4) vcd (timing mesurements)
|
||||
3) vcd (timing mesurements)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -92,18 +92,7 @@ Tools available:
|
||||
|
||||
1) itti_analyser (list messages exchanged between protocol layers)
|
||||
2) xforms (Layer 1)
|
||||
3) mscgen (under construction, but can give some results now)
|
||||
(http://www.mcternan.me.uk/mscgen/)
|
||||
We use the software to generate sequence diagrams
|
||||
with traces generated during the execution of the eNB.
|
||||
After the enb execution:
|
||||
yang@yang:...$ cd /tmp
|
||||
yang@yang:/tmp$ /home/yang/openair4G/trunk/targets/SCRIPTS/msc_gen.py
|
||||
The results are located in the current directory (/tmp in this example) in a folder. The name of the folder
|
||||
is the current date (for example: 2015-04-08_20.34.10).
|
||||
The results are input files for the mscgen tool containing events or messages and the
|
||||
corresponding generated png files.
|
||||
4) vcd (timing mesurements)
|
||||
3) vcd (timing mesurements)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -32,8 +32,6 @@
|
||||
################################
|
||||
THIS_SCRIPT_PATH=$(dirname $(readlink -f $0))
|
||||
source $THIS_SCRIPT_PATH/build_helper
|
||||
declare -i g_run_msc_gen=0
|
||||
declare g_msc_dir="/tmp"
|
||||
|
||||
|
||||
function help()
|
||||
@@ -55,7 +53,6 @@ function help()
|
||||
echo_error " -M, --target-dl-mcs mcs Downlink target MCS."
|
||||
echo_error " -n, --T-no-wait don't wait for tracer, start immediately"
|
||||
echo_error " -p, --T-port port use given port"
|
||||
echo_error " -m, --mscgen directory Generate mscgen output files in a directory"
|
||||
echo_error " -s, --show-stdout Do not redirect stdout and stderr to file /tmp/lte_softmodem.stdout.txt."
|
||||
echo_error " -S, --enable-missed-slot Continue execution in case of missed slot."
|
||||
echo_error " -T, --target-ul-mcs mcs Uplink target MCS."
|
||||
@@ -68,30 +65,10 @@ function help()
|
||||
}
|
||||
|
||||
|
||||
function do_msc_gen()
|
||||
{
|
||||
cd $g_msc_dir
|
||||
last_created_file=`ls -t mscgen* | head -1 | tr -d ':'`
|
||||
$OPENAIR_DIR/targets/SCRIPTS/msc_gen.py
|
||||
sync
|
||||
last_created_file2=`ls -t mscgen* | head -1 | tr -d ':'`
|
||||
|
||||
if [ x"$last_created_file" != x"$last_created_file2" ]; then
|
||||
if [ -f ./$last_created_file2/oai_mscgen_page_0.png ]; then
|
||||
command -v eog 2>/dev/null && eog ./$last_created_file2/oai_mscgen_page_0.png
|
||||
fi
|
||||
fi
|
||||
|
||||
}
|
||||
|
||||
|
||||
function control_c()
|
||||
# run if user hits control-c
|
||||
{
|
||||
echo_warning "\nExiting by ctrl+c\n"
|
||||
if [ $g_run_msc_gen -eq 1 ]; then
|
||||
do_msc_gen
|
||||
fi
|
||||
exit $?
|
||||
}
|
||||
|
||||
@@ -153,18 +130,6 @@ function main()
|
||||
exe_arguments="$exe_arguments --rf-config-file=$rf_config_file"
|
||||
fi
|
||||
;;
|
||||
-m | --mscgen)
|
||||
g_msc_dir=$2
|
||||
# can omit file name if last arg on the line
|
||||
if [ -d "$g_msc_dir" ]; then
|
||||
echo "setting mscgen log files to dir: $g_msc_dir"
|
||||
g_run_msc_gen=1
|
||||
shift 2;
|
||||
else
|
||||
echo_error "Mscgen log dir does not exist"
|
||||
exit -1
|
||||
fi
|
||||
;;
|
||||
-M | --target-dl-mcs)
|
||||
echo "setting target dl MCS to $2"
|
||||
exe_arguments="$exe_arguments -m $2"
|
||||
@@ -251,9 +216,6 @@ function main()
|
||||
else
|
||||
gdb -n -x ~/.gdb_lte_softmodem
|
||||
fi
|
||||
if [ $g_run_msc_gen -eq 1 ]; then
|
||||
do_msc_gen
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
@@ -57,7 +57,6 @@ function help()
|
||||
echo_error " -l, --log-level set the global log level (8:trace, 7:debug, 6:info, 4:warn, 3:error). Note that the log configuration is eNB config file is ignored for oaisim."
|
||||
echo_error " -h, --help Print this help."
|
||||
echo_error " -K, --itti-dump-file filename ITTI dump file containing all ITTI events occuring during EPC runtime.(can omit file name if last argument)"
|
||||
echo_error " -m, --mscgen directory Generate mscgen output files in a directory"
|
||||
echo_error " -V, --vcd Dump timings of processing in a GTKWave compliant file format."
|
||||
echo_error " -W, --wireshark-l2 Dump MAC frames for visualization with wireshark."
|
||||
echo_error " You need to open Wireshark, open the preferences, and check try heuristics for the UDP protocol, MAC-LTE, RLC-LTE,"
|
||||
@@ -75,11 +74,9 @@ function main()
|
||||
cecho "OPENAIR_DIR = $OPENAIR_DIR" $green
|
||||
|
||||
local -i run_gdb=0
|
||||
local -i run_mscgen=0
|
||||
local exe_arguments=""
|
||||
local DEFAULT_CONFIG_FILE_ENB=$OPENAIR_DIR/targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf
|
||||
local CONFIG_FILE_ENB=$DEFAULT_CONFIG_FILE_ENB
|
||||
local MSC_DIR="/tmp"
|
||||
local abstraction_flag=0
|
||||
|
||||
until [ -z "$1" ]
|
||||
@@ -136,17 +133,6 @@ function main()
|
||||
exe_arguments="$exe_arguments -K $ITTI_DUMP_FILE"
|
||||
;;
|
||||
|
||||
-m | --mscgen)
|
||||
MSC_DIR=$2
|
||||
if [ -d "$MSC_DIR" ]; then
|
||||
echo "setting mscgen log files to dir: $MSC_DIR"
|
||||
run_mscgen=1
|
||||
shift 2;
|
||||
else
|
||||
echo_error "Mscgen log dir does not exist"
|
||||
exit -1
|
||||
fi
|
||||
;;
|
||||
# -u | --num-ue )
|
||||
|
||||
-V | --vcd)
|
||||
@@ -212,10 +198,6 @@ function main()
|
||||
cd $OPENAIR_DIR/targets/bin
|
||||
|
||||
|
||||
if [ $run_mscgen -eq 1 ]; then
|
||||
$SUDO rm -f /tmp/openair.msc.*
|
||||
fi
|
||||
|
||||
if [ $run_gdb -eq 0 ]; then
|
||||
exec $SUDO $OPENAIR_DIR/targets/bin/oaisim_nos1.Rel14 $exe_arguments | tee /tmp/enb_ue_nos1.log.txt
|
||||
else
|
||||
@@ -227,20 +209,6 @@ function main()
|
||||
cat ~/.gdb_enb_ue_nos1
|
||||
$SUDO gdb -n -x ~/.gdb_enb_ue_nos1
|
||||
fi
|
||||
|
||||
if [ $run_mscgen -eq 1 ]; then
|
||||
cd $MSC_DIR
|
||||
last_created_file=`ls -t mscgen* | head -1 | tr -d ':'`
|
||||
$OPENAIR_DIR/targets/SCRIPTS/msc_gen.py --profile E_UTRAN
|
||||
sync
|
||||
last_created_file2=`ls -t mscgen* | head -1 | tr -d ':'`
|
||||
|
||||
if [ x"$last_created_file" != x"$last_created_file2" ]; then
|
||||
if [ -f ./$last_created_file2/oai_mscgen_page_0.png ]; then
|
||||
command -v eog 2>/dev/null && eog ./$last_created_file2/oai_mscgen_page_0.png
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
main "$@"
|
||||
|
||||
@@ -81,7 +81,6 @@ function help()
|
||||
echo_error " -g, --gdb Run with GDB."
|
||||
echo_error " -h, --help Print this help."
|
||||
echo_error " -K, --itti-dump-file filename ITTI dump file containing all ITTI events occuring during EPC runtime.(can omit file name if last argument)"
|
||||
echo_error " -m, --mscgen directory Generate mscgen output files in a directory"
|
||||
echo_error " -V, --vcd Dump timings of processing in a GTKWave compliant file format."
|
||||
echo_error " -W, --wireshark-l2 Dump MAC frames for visualization with wireshark."
|
||||
echo_error " You need to open Wireshark, open the preferences, and check try heuristics for the UDP protocol, MAC-LTE, RLC-LTE,"
|
||||
@@ -100,11 +99,9 @@ function main()
|
||||
cecho "OPENAIR_DIR = $OPENAIR_DIR" $green
|
||||
|
||||
local -i run_gdb=0
|
||||
local -i run_mscgen=0
|
||||
local exe_arguments=""
|
||||
local DEFAULT_CONFIG_FILE_ENB=$OPENAIR_DIR/targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_mme.conf
|
||||
local CONFIG_FILE_ENB=$DEFAULT_CONFIG_FILE_ENB
|
||||
local MSC_DIR="/tmp"
|
||||
|
||||
until [ -z "$1" ]
|
||||
do
|
||||
@@ -160,19 +157,6 @@ function main()
|
||||
exe_arguments="$exe_arguments -K $ITTI_DUMP_FILE"
|
||||
;;
|
||||
|
||||
-m | --mscgen)
|
||||
MSC_DIR=$2
|
||||
# can omit file name if last arg on the line
|
||||
if [ -d "$MSC_DIR" ]; then
|
||||
echo "setting mscgen log files to dir: $MSC_DIR"
|
||||
run_mscgen=1
|
||||
shift 2;
|
||||
else
|
||||
echo_error "Mscgen log dir does not exist"
|
||||
exit -1
|
||||
fi
|
||||
;;
|
||||
|
||||
-V | --vcd)
|
||||
echo "setting gtk-wave output"
|
||||
exe_arguments="$exe_arguments -V /tmp/oai_gtk_wave.vcd"
|
||||
@@ -258,10 +242,6 @@ function main()
|
||||
cd $OPENAIR_DIR/targets/bin
|
||||
|
||||
|
||||
if [ $run_mscgen -eq 1 ]; then
|
||||
rm -f /tmp/openair.msc.*
|
||||
fi
|
||||
|
||||
if [ $run_gdb -eq 0 ]; then
|
||||
exec $OPENAIR_DIR/targets/bin/oaisim.Rel14 $exe_arguments | tee /tmp/enb_ue_s1.log.txt
|
||||
else
|
||||
@@ -273,21 +253,6 @@ function main()
|
||||
cat ~/.gdb_enb_ue_s1
|
||||
gdb -n -x ~/.gdb_enb_ue_s1
|
||||
fi
|
||||
|
||||
if [ $run_mscgen -eq 1 ]; then
|
||||
cd $MSC_DIR
|
||||
last_created_file=`ls -t mscgen* | head -1 | tr -d ':'`
|
||||
$OPENAIR_DIR/targets/SCRIPTS/msc_gen.py --profile E_UTRAN
|
||||
sync
|
||||
last_created_file2=`ls -t mscgen* | head -1 | tr -d ':'`
|
||||
|
||||
if [ x"$last_created_file" != x"$last_created_file2" ]; then
|
||||
if [ -f ./$last_created_file2/oai_mscgen_page_0.png ]; then
|
||||
command -v eog 2>/dev/null && eog ./$last_created_file2/oai_mscgen_page_0.png
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
}
|
||||
|
||||
sudo echo
|
||||
|
||||
Reference in New Issue
Block a user