Merge remote-tracking branch 'origin/cmake-refactor' into integration_2023_w27
This commit is contained in:
+66
-300
@@ -37,15 +37,6 @@ include("cmake_targets/macros.cmake")
|
||||
###################################
|
||||
include(FindPkgConfig)
|
||||
|
||||
pkg_search_module(OPENSSL openssl REQUIRED)
|
||||
include_directories(${OPENSSL_INCLUDE_DIRS})
|
||||
|
||||
pkg_search_module(CONFIG libconfig REQUIRED)
|
||||
include_directories(${CONFIG_INCLUDE_DIRS})
|
||||
|
||||
pkg_search_module(CRYPTO libcrypto REQUIRED)
|
||||
include_directories(${CRYPTO_INCLUDE_DIRS})
|
||||
|
||||
# Check if asn1c is installed, and check if it supports all options we need
|
||||
# a user can provide ASN1C_EXEC to override an asn1c to use (e.g., parallel
|
||||
# installation)
|
||||
@@ -64,80 +55,6 @@ check_option(${ASN1C_EXEC} -no-gen-JER ASN1C_EXEC)
|
||||
check_option(${ASN1C_EXEC} -no-gen-BER ASN1C_EXEC)
|
||||
check_option(${ASN1C_EXEC} -no-gen-OER ASN1C_EXEC)
|
||||
|
||||
#uhd 4.0 and iris installs by default in /usr/local
|
||||
include_directories("/usr/local/include/")
|
||||
#use native cmake method as this package is not in pkg-config
|
||||
add_list2_option(RF_BOARD "None" "RF head type" "None" "OAI_USRP" "OAI_BLADERF" "OAI_LMSSDR" "OAI_SIMU")
|
||||
if (${RF_BOARD} STREQUAL "OAI_USRP")
|
||||
find_package(Boost REQUIRED)
|
||||
|
||||
elseif (${RF_BOARD} STREQUAL "OAI_IRIS")
|
||||
include_directories("radio/IRIS/USERSPACE/LIB/")
|
||||
|
||||
set(HW_SOURCE ${HW_SOURCE}
|
||||
radio/IRIS/USERSPACE/LIB/iris_lib.cpp)
|
||||
LINK_DIRECTORIES("/usr/local/lib")
|
||||
set(option_HW_lib "-lSoapySDR -rdynamic -ldl")
|
||||
|
||||
elseif (${RF_BOARD} STREQUAL "OAI_AW2SORI")
|
||||
include_directories("radio/AW2SORI")
|
||||
set(HW_SOURCE ${HW_SOURCE}
|
||||
${OPENAIR_DIR}/radio/AW2SORI/ARCH/AW2SORI/oaiori.c)
|
||||
LINK_DIRECTORIES("/usr/local/lib")
|
||||
set(openair_HW_lib "-shared -fPIC -msse4 -g -ggdb -lori")
|
||||
|
||||
endif (${RF_BOARD} STREQUAL "OAI_USRP")
|
||||
|
||||
pkg_search_module(OPENPGM openpgm-5.1 openpgm-5.2)
|
||||
if(NOT ${OPENPGM_FOUND})
|
||||
message("PACKAGE openpgm-5.1 is required by binaries such as oaisim: will fail later if this target is built")
|
||||
else()
|
||||
include_directories(${OPENPGM_INCLUDE_DIRS})
|
||||
endif()
|
||||
|
||||
pkg_search_module(XPM xpm)
|
||||
if(NOT ${XPM_FOUND})
|
||||
message("PACKAGE xpm not found: some targets will fail")
|
||||
else()
|
||||
include_directories(${XPM_INCLUDE_DIRS})
|
||||
endif()
|
||||
|
||||
# Atlas is required by some packages, but not found in pkg-config
|
||||
# So, here are some hacks here. Hope this gets fixed in future!
|
||||
if(EXISTS "/usr/include/atlas/cblas.h" OR EXISTS "/usr/include/cblas.h")
|
||||
include_directories("/usr/include/atlas")
|
||||
LINK_DIRECTORIES("/usr/lib/lapack")
|
||||
LINK_DIRECTORIES("/usr/lib64")
|
||||
LINK_DIRECTORIES("/usr/lib64/atlas") #Added because atlas libraries in CentOS 7 are here!
|
||||
|
||||
if(EXISTS "/usr/lib64/libblas.so" OR EXISTS "/usr/lib/libblas.so") #Case for CentOS7
|
||||
list(APPEND ATLAS_LIBRARIES blas)
|
||||
|
||||
else() # Case for Ubuntu
|
||||
list(APPEND ATLAS_LIBRARIES cblas)
|
||||
endif()
|
||||
|
||||
if(EXISTS "/usr/lib/atlas/libtatlas.so" OR EXISTS "/usr/lib64/atlas/libtatlas.so") #Case for CentOS7
|
||||
list(APPEND ATLAS_LIBRARIES tatlas)
|
||||
else()
|
||||
list(APPEND ATLAS_LIBRARIES atlas) #Case for Ubuntu
|
||||
endif()
|
||||
|
||||
list(APPEND ATLAS_LIBRARIES lapack)
|
||||
|
||||
# for ubuntu 17.10, directories are different
|
||||
elseif(EXISTS "/usr/include/x86_64-linux-gnu/cblas.h")
|
||||
|
||||
include_directories("/usr/include/x86_64-linux-gnu")
|
||||
LINK_DIRECTORIES("/usr/lib/x86_64-linux-gnu")
|
||||
list(APPEND ATLAS_LIBRARIES cblas)
|
||||
list(APPEND ATLAS_LIBRARIES atlas)
|
||||
list(APPEND ATLAS_LIBRARIES lapack)
|
||||
|
||||
else()
|
||||
message("No Blas/Atlas libs found, some targets will fail")
|
||||
endif()
|
||||
|
||||
#########################################################
|
||||
# Base directories, compatible with legacy OAI building #
|
||||
#########################################################
|
||||
@@ -353,6 +270,9 @@ add_library(nr_rrc ${OPENAIR2_DIR}/RRC/NR/MESSAGES/asn1_msg.c)
|
||||
target_link_libraries(nr_rrc PUBLIC asn1_nr_rrc asn1_lte_rrc)
|
||||
|
||||
|
||||
# S1AP and NGAP need crypt library
|
||||
pkg_check_modules(libcrypt REQUIRED libcrypt)
|
||||
|
||||
# S1AP
|
||||
##############
|
||||
set(S1AP_DIR ${OPENAIR3_DIR}/S1AP)
|
||||
@@ -374,6 +294,8 @@ add_library(s1ap
|
||||
)
|
||||
target_link_libraries(s1ap PUBLIC asn1_s1ap)
|
||||
target_link_libraries(s1ap PRIVATE nr_rrc asn1_nr_rrc_hdrs lte_rrc)
|
||||
target_include_directories(s1ap PRIVATE ${libcrypt_INCLUDE_DIRS})
|
||||
target_link_libraries(s1ap PUBLIC ${libcrypt_LIBRARIES})
|
||||
|
||||
# NGAP
|
||||
##############
|
||||
@@ -395,6 +317,8 @@ add_library(ngap
|
||||
)
|
||||
target_link_libraries(ngap PUBLIC asn1_ngap)
|
||||
target_link_libraries(ngap PRIVATE asn1_lte_rrc_hdrs asn1_nr_rrc_hdrs)
|
||||
target_include_directories(ngap PRIVATE ${libcrypt_INCLUDE_DIRS})
|
||||
target_link_libraries(ngap PRIVATE ${libcrypt_LIBRARIES})
|
||||
|
||||
#M2AP
|
||||
##############
|
||||
@@ -499,114 +423,24 @@ target_link_libraries(f1ap PRIVATE ngap nr_rrc)
|
||||
add_list1_option(NB_ANTENNAS_RX "4" "Number of antennas in reception" "1" "2" "4")
|
||||
add_list1_option(NB_ANTENNAS_TX "4" "Number of antennas in transmission" "1" "2" "4")
|
||||
|
||||
#NOKIA config enhancement
|
||||
set (CONFIG_ROOTDIR ${OPENAIR_DIR}/common/config)
|
||||
add_library(CONFIG_LIB
|
||||
${CONFIG_ROOTDIR}/config_load_configmodule.c
|
||||
${CONFIG_ROOTDIR}/config_userapi.c
|
||||
${CONFIG_ROOTDIR}/config_cmdline.c
|
||||
)
|
||||
|
||||
# CONFIG_LIB is a wrapper around a particular config implementation, default is
|
||||
# libconfig in params_libconfig below
|
||||
pkg_check_modules(libconfig REQUIRED libconfig)
|
||||
target_link_libraries(CONFIG_LIB PRIVATE dl UTIL)
|
||||
add_library(params_libconfig MODULE ${CONFIG_ROOTDIR}/libconfig/config_libconfig.c)
|
||||
target_link_libraries(params_libconfig config)
|
||||
target_include_directories(params_libconfig PRIVATE ${libconfig_INCLUDE_DIRS})
|
||||
target_link_libraries(params_libconfig PRIVATE ${libconfig_LIBRARIES})
|
||||
|
||||
# shared library loader
|
||||
set (SHLIB_LOADER_SOURCES
|
||||
${OPENAIR_DIR}/common/utils/load_module_shlib.c
|
||||
)
|
||||
# include RF devices / transport protocols library modules
|
||||
######################################################################
|
||||
|
||||
set(HWLIB_USRP_SOURCE
|
||||
${OPENAIR_DIR}/radio/USRP/USERSPACE/LIB/usrp_lib.cpp
|
||||
)
|
||||
add_library(oai_usrpdevif MODULE ${HWLIB_USRP_SOURCE} )
|
||||
target_include_directories(oai_usrpdevif PRIVATE
|
||||
"${OPENAIR_DIR}/radio/USRP/USERSPACE/LIB/"
|
||||
${Boost_INCLUDE_DIR}
|
||||
)
|
||||
target_link_libraries(oai_usrpdevif uhd)
|
||||
|
||||
include_directories("${OPENAIR_DIR}/radio/BLADERF/USERSPACE/LIB/")
|
||||
set(HWLIB_BLADERF_SOURCE
|
||||
${OPENAIR_DIR}/radio/BLADERF/USERSPACE/LIB/bladerf_lib.c
|
||||
)
|
||||
add_library(oai_bladerfdevif MODULE ${HWLIB_BLADERF_SOURCE} )
|
||||
target_link_libraries(oai_bladerfdevif bladeRF)
|
||||
|
||||
include_directories("${OPENAIR_DIR}/radio/LMSSDR/USERSPACE/LIB/")
|
||||
|
||||
set(HWLIB_LMSSDR_SOURCE
|
||||
${OPENAIR_DIR}/radio/LMSSDR/USERSPACE/LIB/lms_lib.cpp
|
||||
)
|
||||
add_library(oai_lmssdrdevif MODULE ${HWLIB_LMSSDR_SOURCE} )
|
||||
target_include_directories(oai_lmssdrdevif PRIVATE /usr/local/include/lime)
|
||||
target_link_libraries(oai_lmssdrdevif LimeSuite )
|
||||
|
||||
|
||||
include_directories("${OPENAIR_DIR}/radio/ETHERNET/USERSPACE/LIB/")
|
||||
set(TPLIB_ETHERNET_SOURCE
|
||||
${OPENAIR_DIR}/radio/ETHERNET/USERSPACE/LIB/ethernet_lib.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/USERSPACE/LIB/eth_udp.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/USERSPACE/LIB/eth_raw.c
|
||||
)
|
||||
add_library(oai_eth_transpro MODULE ${TPLIB_ETHERNET_SOURCE} )
|
||||
|
||||
include_directories("${OPENAIR_DIR}/radio/AW2SORI/")
|
||||
link_directories("/usr/local/lib")
|
||||
set(HWLIB_AW2SORI_SOURCE
|
||||
${OPENAIR_DIR}/radio/AW2SORI/oaiori.c
|
||||
)
|
||||
add_library(aw2sori_transpro MODULE ${HWLIB_AW2SORI_SOURCE})
|
||||
target_compile_options(aw2sori_transpro PRIVATE -shared -fPIC -msse4 -g -ggdb -DLITE_COMPILATION)
|
||||
target_link_libraries(aw2sori_transpro libori.so)
|
||||
|
||||
include_directories("${OPENAIR_DIR}/radio/IRIS/USERSPACE/LIB/")
|
||||
set(option_HWIRISLIB_lib "-l SoapySDR")
|
||||
set(HWLIB_IRIS_SOURCE
|
||||
${OPENAIR_DIR}/radio/IRIS/USERSPACE/LIB/iris_lib.cpp
|
||||
)
|
||||
add_library(oai_irisdevif MODULE ${HWLIB_IRIS_SOURCE})
|
||||
target_include_directories(oai_irisdevif PRIVATE /usr/local/lib/SoapySDR/modules0.7/)
|
||||
target_link_libraries(oai_irisdevif SoapySDR)
|
||||
|
||||
# Benetel 4G library
|
||||
######################################################################
|
||||
|
||||
|
||||
include_directories ("/usr/include/dpdk")
|
||||
|
||||
set(HWLIB_BENETEL_4G_SOURCE
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/4g/benetel.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/4g/shared_buffers.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/4g/low.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/4g/low_dpdk.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/4g/dpdk_driver.c
|
||||
)
|
||||
add_library(benetel_4g MODULE ${HWLIB_BENETEL_4G_SOURCE} )
|
||||
|
||||
set_target_properties(benetel_4g PROPERTIES COMPILE_FLAGS "-fvisibility=hidden -I$ENV{RTE_SDK}/$ENV{RTE_TARGET}/include")
|
||||
|
||||
SET(DPDK_LIBS "-Wl,-rpath,$ENV{RTE_SDK}/$ENV{RTE_TARGET}/lib -Wl,--whole-archive -L$ENV{RTE_SDK}/$ENV{RTE_TARGET}/lib -ldpdk -Wl,--no-whole-archive")
|
||||
target_link_libraries(benetel_4g PRIVATE ${DPDK_LIBS})
|
||||
target_link_libraries(benetel_4g PRIVATE pthread dl rt m numa)
|
||||
|
||||
# Benetel 5G library
|
||||
######################################################################
|
||||
|
||||
set(HWLIB_BENETEL_5G_SOURCE
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/5g/benetel.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/5g/shared_buffers.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/5g/low.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/5g/low_dpdk.c
|
||||
${OPENAIR_DIR}/radio/ETHERNET/benetel/5g/dpdk_driver.c
|
||||
)
|
||||
add_library(benetel_5g MODULE ${HWLIB_BENETEL_5G_SOURCE} )
|
||||
|
||||
set_target_properties(benetel_5g PROPERTIES COMPILE_FLAGS "-fvisibility=hidden -I$ENV{RTE_SDK}/$ENV{RTE_TARGET}/include")
|
||||
|
||||
SET(DPDK_LIBS "-Wl,-rpath,$ENV{RTE_SDK}/$ENV{RTE_TARGET}/lib -Wl,--whole-archive -L$ENV{RTE_SDK}/$ENV{RTE_TARGET}/lib -ldpdk -Wl,--no-whole-archive")
|
||||
target_link_libraries(benetel_5g PRIVATE ${DPDK_LIBS})
|
||||
target_link_libraries(benetel_5g PRIVATE pthread dl rt m numa)
|
||||
add_library(shlib_loader OBJECT common/utils/load_module_shlib.c)
|
||||
target_link_libraries(shlib_loader PRIVATE CONFIG_LIB)
|
||||
|
||||
##########################################################
|
||||
|
||||
@@ -635,7 +469,6 @@ include_directories ("${OPENAIR_DIR}/radio/COMMON")
|
||||
##############################################################
|
||||
|
||||
add_boolean_option(OAI_NW_DRIVER_TYPE_ETHERNET False "????" ON)
|
||||
add_boolean_option(NAS_NETLINK False "useless ??? Must be True to compile nasmesh driver without rtai ????" ON)
|
||||
add_boolean_option(OAI_NW_DRIVER_USE_NETLINK True "????" ON)
|
||||
|
||||
add_boolean_option(UE_EXPANSION False "enable UE_EXPANSION with max 256 UE" ON)
|
||||
@@ -643,19 +476,12 @@ add_boolean_option(PHY_TX_THREAD False "enable UE_EXPANSION w
|
||||
add_boolean_option(PRE_SCD_THREAD False "enable UE_EXPANSION with max 256 UE" ON)
|
||||
add_boolean_option(UESIM_EXPANSION False "enable UESIM_EXPANSION with max 256 UE" ON)
|
||||
|
||||
########################
|
||||
# Include order
|
||||
##########################
|
||||
add_boolean_option(ENB_MODE True "Swap the include directories between openair2 and openair3" ON)
|
||||
|
||||
##########################
|
||||
# SCHEDULING/REAL-TIME/PERF options
|
||||
##########################
|
||||
add_boolean_option(ENABLE_USE_CPU_EXECUTION_TIME False "Add data in vcd traces: disable it if perf issues" ON)
|
||||
add_boolean_option(ENABLE_VCD False "always true now, time measurements of proc calls and var displays" ON)
|
||||
add_boolean_option(ENABLE_VCD_FIFO False "time measurements of proc calls and var displays sent to FIFO (one more thread)" ON)
|
||||
add_boolean_option(LINUX False "used in weird memcpy() in pdcp.c ???" ON)
|
||||
add_boolean_option(LINUX_LIST False "used only in lists.c: either use OAI implementation of lists or Linux one (should be ON, but it is False" ON)
|
||||
|
||||
##########################
|
||||
# PHY options
|
||||
@@ -665,7 +491,6 @@ add_integer_option(MAX_NUM_CCs 1 "????" ON)
|
||||
add_boolean_option(SMBV False "Rohde&Schwarz SMBV100A vector signal generator" ON)
|
||||
add_boolean_option(DEBUG_PHY False "Enable PHY layer debugging options" ON)
|
||||
add_boolean_option(DEBUG_PHY_PROC False "Enable debugging of PHY layer procedures" ON)
|
||||
add_boolean_option(DEBUG_DLSCH False "Enable debugging of DLSCH physical layer channel" ON)
|
||||
add_boolean_option(MEX False "Enabling compilation with mex" ON)
|
||||
|
||||
##########################
|
||||
@@ -676,22 +501,10 @@ add_boolean_option(NAS_BUILT_IN_UE True "UE NAS layer present in this e
|
||||
add_boolean_option(NAS_UE True "NAS UE INSTANCE (<> NAS_MME)" ON)
|
||||
|
||||
|
||||
##########################
|
||||
# PDCP LAYER OPTIONS
|
||||
##########################
|
||||
#add_boolean_option(LINK_ENB_PDCP_TO_IP_DRIVER False "For eNB, PDCP communicate with a IP driver")
|
||||
#add_boolean_option(LINK_ENB_PDCP_TO_GTPV1U True "For eNB, PDCP communicate with GTP-U protocol (eNB<->S-GW)")
|
||||
|
||||
##########################
|
||||
# RRC LAYER OPTIONS
|
||||
##########################
|
||||
add_boolean_option(RRC_DEFAULT_RAB_IS_AM True "set the RLC mode to AM for the default bearer, otherwise it is UM." ON)
|
||||
|
||||
|
||||
##########################
|
||||
# S1AP LAYER OPTIONS
|
||||
##########################
|
||||
# none
|
||||
add_boolean_option(RRC_DEFAULT_RAB_IS_AM True "set the LTE RLC mode to AM for the default bearer, otherwise it is UM." ON)
|
||||
|
||||
# add the binary tree to the search path for include files
|
||||
#######################################################
|
||||
@@ -708,19 +521,11 @@ include_directories("${OPENAIR_BIN_DIR}")
|
||||
# Legacy exact order
|
||||
|
||||
include_directories("${OPENAIR_DIR}/executables")
|
||||
if(ENB_MODE)
|
||||
include_directories("${OPENAIR2_DIR}/COMMON")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/LOG")
|
||||
include_directories("${OPENAIR3_DIR}/COMMON")
|
||||
include_directories("${OPENAIR3_DIR}/UTILS")
|
||||
else()
|
||||
include_directories("${OPENAIR3_DIR}/COMMON")
|
||||
include_directories("${OPENAIR3_DIR}/UTILS")
|
||||
include_directories("${OPENAIR2_DIR}/COMMON")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/LOG")
|
||||
endif()
|
||||
include_directories("${OPENAIR2_DIR}/COMMON")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/LOG")
|
||||
include_directories("${OPENAIR3_DIR}/COMMON")
|
||||
include_directories("${OPENAIR3_DIR}/UTILS")
|
||||
include_directories("${NFAPI_DIR}/nfapi/public_inc")
|
||||
include_directories("${NFAPI_DIR}/common/public_inc")
|
||||
include_directories("${NFAPI_DIR}/pnf/public_inc")
|
||||
@@ -759,22 +564,14 @@ include_directories("${OPENAIR3_DIR}/ocp-gtpu")
|
||||
include_directories("${OPENAIR3_DIR}/M3AP")
|
||||
include_directories("${OPENAIR3_DIR}/MME_APP")
|
||||
include_directories("${OPENAIR_DIR}/radio/COMMON")
|
||||
include_directories("${OPENAIR2_DIR}/ENB_APP/CONTROL_MODULES/PHY")
|
||||
include_directories("${OPENAIR2_DIR}/ENB_APP/CONTROL_MODULES/MAC")
|
||||
include_directories("${OPENAIR2_DIR}/ENB_APP/CONTROL_MODULES/RRC")
|
||||
include_directories("${OPENAIR2_DIR}/ENB_APP/CONTROL_MODULES/PDCP")
|
||||
include_directories("${OPENAIR2_DIR}/ENB_APP/CONTROL_MODULES/S1AP")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/OSA")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/MEM")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/LISTS")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/FIFO")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/MATH")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/TIMER")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/OMG")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/OTG")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/CLI")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/OPT")
|
||||
include_directories("${OPENAIR2_DIR}/UTIL/OMV")
|
||||
include_directories("${OPENAIR_DIR}")
|
||||
|
||||
###########
|
||||
@@ -816,8 +613,10 @@ set(SECURITY_SRC
|
||||
${OPENAIR3_DIR}/SECU/nas_stream_eia2.c
|
||||
)
|
||||
|
||||
pkg_check_modules(OpenSSL openssl REQUIRED)
|
||||
add_library(SECURITY ${SECURITY_SRC} $<TARGET_OBJECTS:ds>)
|
||||
target_include_directories(SECURITY PRIVATE ${OPENAIR_DIR}/common/utils/ds/)
|
||||
target_link_libraries(SECURITY PRIVATE ${OpenSSL_LIBRARIES})
|
||||
|
||||
# Physical Channel Procedures Scheduling
|
||||
################################"
|
||||
@@ -1289,8 +1088,16 @@ target_link_libraries(PHY_COMMON PRIVATE asn1_lte_rrc_hdrs)
|
||||
add_library(PHY ${PHY_SRC})
|
||||
target_link_libraries(PHY PRIVATE asn1_lte_rrc_hdrs asn1_nr_rrc_hdrs)
|
||||
|
||||
pkg_check_modules(blas REQUIRED blas)
|
||||
pkg_check_modules(lapacke REQUIRED lapacke)
|
||||
|
||||
add_library(PHY_UE ${PHY_SRC_UE})
|
||||
target_link_libraries(PHY_UE PRIVATE asn1_lte_rrc_hdrs asn1_nr_rrc_hdrs)
|
||||
# RHEL needs also cblas, but Ubuntu does not have it. So `cblas_LIBRARIES` will
|
||||
# be empty for Ubuntu, a no-op
|
||||
pkg_check_modules(cblas cblas)
|
||||
target_link_libraries(PHY_UE PRIVATE ${blas_LIBRARIES} ${cblas_LIBRARIES} ${lapacke_LIBRARIES})
|
||||
target_include_directories(PHY_UE PRIVATE ${blas_INCLUDE_DIRS} ${lapacke_INCLUDE_DIRS})
|
||||
|
||||
add_library(PHY_NR_COMMON ${PHY_NR_SRC_COMMON})
|
||||
|
||||
@@ -1323,7 +1130,7 @@ set(PHY_MEX_UE
|
||||
${OPENAIR_DIR}/common/utils/T/T.c
|
||||
${OPENAIR_DIR}/common/utils/T/local_tracer.c
|
||||
)
|
||||
add_library(PHY_MEX ${PHY_MEX_UE} ${CONFIG_LIB})
|
||||
add_library(PHY_MEX ${PHY_MEX_UE})
|
||||
target_link_libraries(PHY_MEX PRIVATE asn1_lte_rrc_hdrs)
|
||||
|
||||
#Layer 2 library
|
||||
@@ -1372,12 +1179,6 @@ set(NR_PDCP_SRC
|
||||
${OPENAIR2_DIR}/LAYER2/nr_pdcp/nr_pdcp_integrity_nia2.c
|
||||
${OPENAIR2_DIR}/LAYER2/nr_pdcp/nr_pdcp_integrity_nia1.c
|
||||
${OPENAIR2_DIR}/LAYER2/nr_pdcp/asn1_utils.c
|
||||
#hack: include these files to compile the nr phy simulators
|
||||
#these files should not be here, will be removed at some point when the
|
||||
#computation is done directly inside nr_pdcp_integrity_nia1.c instead
|
||||
#of reusing code of osa_stream_eia.c
|
||||
#${OPENAIR2_DIR}/UTIL/OSA/osa_stream_eia.c
|
||||
#${OPENAIR2_DIR}/UTIL/OSA/osa_snow3g.c
|
||||
)
|
||||
|
||||
set(NR_SDAP_SRC
|
||||
@@ -2016,11 +1817,6 @@ set (NBIOT_SOURCES
|
||||
)
|
||||
add_library(NB_IoT MODULE ${NBIOT_SOURCES} )
|
||||
|
||||
# shared library loader
|
||||
set (SHLIB_LOADER_SOURCES
|
||||
${OPENAIR_DIR}/common/utils/load_module_shlib.c
|
||||
)
|
||||
|
||||
add_library(LIB_5GNAS_GNB
|
||||
${NAS_SRC}/COMMON/nr_common.c
|
||||
${NAS_SRC}/gNB/network_process_nas.c
|
||||
@@ -2029,7 +1825,7 @@ add_library(LIB_5GNAS_GNB
|
||||
)
|
||||
|
||||
target_include_directories(LIB_5GNAS_GNB PRIVATE ${OPENAIR_DIR}/common/utils/ds/)
|
||||
target_link_libraries(LIB_5GNAS_GNB PRIVATE SECURITY ${CRYPTO_LIBRARIES})
|
||||
target_link_libraries(LIB_5GNAS_GNB PRIVATE SECURITY)
|
||||
target_link_libraries(LIB_5GNAS_GNB PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
# Simulation library
|
||||
@@ -2049,6 +1845,8 @@ set (SIMUSRC
|
||||
)
|
||||
add_library(SIMU STATIC ${SIMUSRC} )
|
||||
target_include_directories(SIMU PUBLIC ${OPENAIR1_DIR}/SIMULATION/TOOLS ${OPENAIR1_DIR}/SIMULATION/RF)
|
||||
target_link_libraries(SIMU PRIVATE ${blas_LIBRARIES} ${cblas_LIBRARIES} ${lapacke_LIBRARIES})
|
||||
target_include_directories(SIMU PRIVATE ${blas_INCLUDE_DIRS} ${lapacke_INCLUDE_DIRS})
|
||||
|
||||
# Qt-based scope
|
||||
add_boolean_option(ENABLE_NRQTSCOPE OFF "Build the Qt-Scope" OFF)
|
||||
@@ -2079,16 +1877,6 @@ include_directories("${NFAPI_DIR}/nfapi/inc")
|
||||
include_directories("${NFAPI_DIR}/sim_common/inc")
|
||||
include_directories("${NFAPI_DIR}/pnf_sim/inc")
|
||||
|
||||
list(APPEND ATLAS_LIBRARIES lapack lapacke)
|
||||
|
||||
|
||||
add_library(rfsimulator MODULE
|
||||
${OPENAIR_DIR}/radio/rfsimulator/simulator.c
|
||||
${OPENAIR_DIR}/radio/rfsimulator/apply_channelmod.c
|
||||
${OPENAIR1_DIR}/PHY/TOOLS/signal_energy.c
|
||||
)
|
||||
target_link_libraries(rfsimulator PRIVATE SIMU ${ATLAS_LIBRARIES})
|
||||
|
||||
add_library(oai_iqplayer MODULE
|
||||
${OPENAIR_DIR}/radio/iqplayer/iqplayer_lib.c
|
||||
)
|
||||
@@ -2140,17 +1928,12 @@ add_library(minimal_lib
|
||||
${OPENAIR_DIR}/common/utils/minimal_stub.c
|
||||
${T_SOURCE}
|
||||
)
|
||||
target_link_libraries(minimal_lib pthread dl ${T_LIB} CONFIG_LIB)
|
||||
target_link_libraries(minimal_lib pthread dl ${T_LIB})
|
||||
|
||||
add_executable(nfapi_test
|
||||
${OPENAIR_DIR}/openair2/NR_PHY_INTERFACE/nfapi_5g_test.c
|
||||
)
|
||||
|
||||
add_executable(replay_node
|
||||
${OPENAIR_DIR}/radio/rfsimulator/stored_node.c
|
||||
)
|
||||
target_link_libraries (replay_node minimal_lib)
|
||||
|
||||
add_executable(measurement_display
|
||||
${OPENAIR_DIR}/common/utils/threadPool/measurement_display.c)
|
||||
target_link_libraries (measurement_display minimal_lib)
|
||||
@@ -2158,7 +1941,7 @@ target_link_libraries (measurement_display minimal_lib)
|
||||
add_executable(test5Gnas
|
||||
${OPENAIR_DIR}/openair3/TEST/test5Gnas.c
|
||||
)
|
||||
target_link_libraries (test5Gnas LIB_5GNAS_GNB CONFIG_LIB minimal_lib )
|
||||
target_link_libraries (test5Gnas LIB_5GNAS_GNB minimal_lib )
|
||||
|
||||
|
||||
# lte-softmodem is both eNB and UE implementation
|
||||
@@ -2183,7 +1966,6 @@ add_executable(lte-softmodem
|
||||
${OPENAIR_DIR}/common/utils/lte/prach_utils.c
|
||||
${OPENAIR1_DIR}/PHY/TOOLS/phy_scope_interface.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
add_dependencies(lte-softmodem oai_iqplayer)
|
||||
|
||||
@@ -2191,10 +1973,10 @@ target_link_libraries(lte-softmodem PRIVATE
|
||||
-Wl,--start-group
|
||||
lte_rrc nr_rrc s1ap m2ap x2ap m3ap GTPV1U SECURITY UTIL HASHTABLE SCTP_CLIENT MME_APP SCHED_LIB SCHED_RU_LIB
|
||||
PHY_COMMON PHY PHY_RU L2 L2_LTE NFAPI_COMMON_LIB NFAPI_LIB NFAPI_VNF_LIB NFAPI_PNF_LIB NFAPI_USER_LIB MISC_NFAPI_LTE_LIB
|
||||
${NAS_UE_LIB} ITTI SIMU SIMU_ETH
|
||||
${NAS_UE_LIB} ITTI SIMU SIMU_ETH shlib_loader
|
||||
-Wl,--end-group z dl)
|
||||
|
||||
target_link_libraries(lte-softmodem PRIVATE pthread m CONFIG_LIB rt crypt ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} sctp)
|
||||
target_link_libraries(lte-softmodem PRIVATE pthread m CONFIG_LIB rt sctp)
|
||||
target_link_libraries(lte-softmodem PRIVATE ${T_LIB})
|
||||
target_link_libraries(lte-softmodem PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2212,12 +1994,10 @@ add_executable(oairu
|
||||
${OPENAIR_DIR}/executables/main_ru.c
|
||||
${T_SOURCE}
|
||||
${OPENAIR_DIR}/common/utils/lte/prach_utils.c
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
target_link_libraries(oairu PRIVATE
|
||||
-Wl,--start-group
|
||||
SCHED_RU_LIB
|
||||
PHY_COMMON PHY_RU UTIL
|
||||
SCHED_RU_LIB PHY_COMMON PHY_RU UTIL shlib_loader
|
||||
-Wl,--end-group z dl)
|
||||
|
||||
target_link_libraries(oairu PRIVATE pthread m CONFIG_LIB rt ${T_LIB})
|
||||
@@ -2245,7 +2025,6 @@ add_executable(lte-uesoftmodem
|
||||
${OPENAIR_DIR}/common/utils/lte/prach_utils.c
|
||||
${OPENAIR1_DIR}/PHY/TOOLS/phy_scope_interface.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
|
||||
if (NOT ${NOS1})
|
||||
@@ -2256,10 +2035,10 @@ target_link_libraries(lte-uesoftmodem PRIVATE
|
||||
lte_rrc nr_rrc s1ap x2ap m2ap m3ap
|
||||
SECURITY UTIL HASHTABLE SCTP_CLIENT MME_APP SCHED_RU_LIB SCHED_UE_LIB PHY_COMMON
|
||||
PHY_UE PHY_RU L2_UE L2_LTE SIMU SIMU_ETH NFAPI_COMMON_LIB NFAPI_LIB NFAPI_PNF_LIB NFAPI_USER_LIB MISC_NFAPI_LTE_LIB
|
||||
${NAS_UE_LIB} ITTI ${ATLAS_LIBRARIES}
|
||||
${NAS_UE_LIB} ITTI shlib_loader
|
||||
-Wl,--end-group z dl)
|
||||
|
||||
target_link_libraries(lte-uesoftmodem PRIVATE pthread m CONFIG_LIB rt crypt ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} sctp ${ATLAS_LIBRARIES})
|
||||
target_link_libraries(lte-uesoftmodem PRIVATE pthread m CONFIG_LIB rt sctp)
|
||||
target_link_libraries(lte-uesoftmodem PRIVATE ${T_LIB})
|
||||
target_link_libraries(lte-uesoftmodem PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2289,7 +2068,6 @@ add_executable(nr-softmodem
|
||||
${PHY_INTERFACE_DIR}/queue_t.c
|
||||
${OPENAIR1_DIR}/PHY/TOOLS/phy_scope_interface.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
|
||||
target_link_libraries(nr-softmodem PRIVATE
|
||||
@@ -2297,10 +2075,10 @@ target_link_libraries(nr-softmodem PRIVATE
|
||||
UTIL HASHTABLE SCTP_CLIENT SCHED_LIB SCHED_RU_LIB SCHED_NR_LIB PHY_NR PHY PHY_COMMON PHY_NR_COMMON PHY_RU GTPV1U SECURITY
|
||||
ITTI ${NAS_UE_LIB} lte_rrc nr_rrc
|
||||
ngap s1ap L2_LTE_NR L2_NR MAC_NR_COMMON NFAPI_COMMON_LIB NFAPI_LIB NFAPI_VNF_LIB NFAPI_PNF_LIB NFAPI_USER_LIB SIMU SIMU_ETH
|
||||
x2ap f1ap m2ap m3ap e1ap
|
||||
x2ap f1ap m2ap m3ap e1ap shlib_loader
|
||||
-Wl,--end-group z dl)
|
||||
|
||||
target_link_libraries(nr-softmodem PRIVATE pthread m CONFIG_LIB rt crypt ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} sctp ${ATLAS_LIBRARIES})
|
||||
target_link_libraries(nr-softmodem PRIVATE pthread m CONFIG_LIB rt sctp)
|
||||
target_link_libraries(nr-softmodem PRIVATE ${T_LIB})
|
||||
target_link_libraries(nr-softmodem PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2327,13 +2105,12 @@ add_executable(nr-cuup
|
||||
${NR_PDCP_SRC}
|
||||
${NR_SDAP_SRC}
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
|
||||
target_link_libraries(nr-cuup PRIVATE
|
||||
CONFIG_LIB ITTI SCTP_CLIENT
|
||||
GTPV1U e1ap e1_pdcp_if f1ap SIMU_ETH
|
||||
z sctp dl pthread)
|
||||
z sctp dl pthread shlib_loader)
|
||||
target_link_libraries(nr-cuup PRIVATE asn1_lte_rrc_hdrs asn1_nr_rrc_hdrs)
|
||||
|
||||
# nr-uesoftmodem is UE implementation
|
||||
@@ -2355,7 +2132,6 @@ add_executable(nr-uesoftmodem
|
||||
${OPENAIR_DIR}/common/utils/nr/nr_common.c
|
||||
${OPENAIR1_DIR}/PHY/TOOLS/phy_scope_interface.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
|
||||
target_link_libraries(nr-uesoftmodem PRIVATE
|
||||
@@ -2363,10 +2139,10 @@ target_link_libraries(nr-uesoftmodem PRIVATE
|
||||
nr_rrc SECURITY UTIL HASHTABLE SCHED_RU_LIB SCHED_NR_UE_LIB
|
||||
PHY_COMMON PHY_NR_COMMON PHY_NR_UE NR_L2_UE L2_UE_LTE_NR MAC_NR_COMMON NFAPI_COMMON_LIB NFAPI_LIB NFAPI_PNF_LIB
|
||||
NFAPI_USER_LIB MISC_NFAPI_NR_LIB
|
||||
ITTI ${ATLAS_LIBRARIES} LIB_5GNAS_GNB LIB_NAS_SIMUE ${NAS_SIM_LIB} SIMU SIMU_ETH
|
||||
ITTI LIB_5GNAS_GNB LIB_NAS_SIMUE ${NAS_SIM_LIB} SIMU SIMU_ETH shlib_loader
|
||||
-Wl,--end-group z dl)
|
||||
|
||||
target_link_libraries(nr-uesoftmodem PRIVATE pthread m CONFIG_LIB rt crypt ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} ${ATLAS_LIBRARIES})
|
||||
target_link_libraries(nr-uesoftmodem PRIVATE pthread m CONFIG_LIB rt)
|
||||
target_link_libraries(nr-uesoftmodem PRIVATE ${T_LIB})
|
||||
target_link_libraries(nr-uesoftmodem PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2396,7 +2172,7 @@ add_executable(dlsim_tm4
|
||||
)
|
||||
target_link_libraries (dlsim_tm4
|
||||
-Wl,--start-group SIMU UTIL SCHED_LIB SCHED_RU_LIB PHY ITTI -Wl,--end-group
|
||||
pthread m rt CONFIG_LIB ${ATLAS_LIBRARIES} ${T_LIB}
|
||||
pthread m rt CONFIG_LIB ${T_LIB}
|
||||
)
|
||||
|
||||
add_executable(rftest
|
||||
@@ -2404,32 +2180,29 @@ add_executable(rftest
|
||||
${OPENAIR_DIR}/openair1/PHY/TOOLS/calibration_scope.c
|
||||
${OPENAIR_DIR}/radio/COMMON/common_lib.c
|
||||
${OPENAIR_DIR}/executables/softmodem-common.c
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
target_link_libraries(rftest PRIVATE minimal_lib CONFIG_LIB PHY_NR_COMMON UTIL pthread dl m ${T_LIB} )
|
||||
target_link_libraries(rftest PRIVATE minimal_lib PHY_NR_COMMON UTIL forms pthread dl m ${T_LIB} shlib_loader)
|
||||
target_link_libraries(rftest PRIVATE asn1_lte_rrc_hdrs asn1_nr_rrc_hdrs)
|
||||
|
||||
add_executable(polartest
|
||||
${OPENAIR1_DIR}/PHY/CODING/TESTBENCH/polartest.c
|
||||
${OPENAIR_DIR}/common/utils/nr/nr_common.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
target_link_libraries(polartest PRIVATE
|
||||
-Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_COMMON PHY_NR_UE CONFIG_LIB -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} dl
|
||||
m pthread dl
|
||||
)
|
||||
|
||||
add_executable(smallblocktest
|
||||
${OPENAIR1_DIR}/PHY/CODING/TESTBENCH/smallblocktest.c
|
||||
${OPENAIR_DIR}/common/utils/nr/nr_common.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
|
||||
target_link_libraries(smallblocktest PRIVATE
|
||||
-Wl,--start-group UTIL SIMU PHY_NR PHY_COMMON PHY_NR_COMMON CONFIG_LIB -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} dl
|
||||
-Wl,--start-group UTIL SIMU PHY_NR PHY_COMMON PHY_NR_COMMON -Wl,--end-group
|
||||
m pthread dl shlib_loader
|
||||
)
|
||||
|
||||
|
||||
@@ -2437,7 +2210,6 @@ add_executable(ldpctest
|
||||
${PHY_NR_CODINGIF}
|
||||
${OPENAIR1_DIR}/PHY/CODING/TESTBENCH/ldpctest.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
|
||||
add_dependencies( ldpctest ldpc_orig ldpc_optim ldpc_optim8seg ldpc ldpc_parityCheck)
|
||||
@@ -2445,8 +2217,8 @@ if (ENABLE_LDPC_CUDA)
|
||||
add_dependencies(ldpctest ldpc_cuda)
|
||||
endif()
|
||||
target_link_libraries(ldpctest PRIVATE
|
||||
-Wl,--start-group UTIL SIMU PHY_NR PHY_COMMON PHY_NR_COMMON CONFIG_LIB -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} dl
|
||||
-Wl,--start-group UTIL SIMU PHY_NR PHY_COMMON PHY_NR_COMMON -Wl,--end-group
|
||||
m pthread dl shlib_loader
|
||||
)
|
||||
|
||||
add_executable(nr_dlschsim
|
||||
@@ -2454,11 +2226,10 @@ add_executable(nr_dlschsim
|
||||
${OPENAIR1_DIR}/SIMULATION/NR_PHY/nr_dummy_functions.c
|
||||
${OPENAIR_DIR}/common/utils/nr/nr_common.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
target_link_libraries(nr_dlschsim PRIVATE
|
||||
-Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB MAC_NR_COMMON -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} ${T_LIB} ITTI dl
|
||||
m pthread ${T_LIB} ITTI dl shlib_loader
|
||||
)
|
||||
target_link_libraries(nr_dlschsim PRIVATE asn1_nr_rrc_hdrs)
|
||||
|
||||
@@ -2467,11 +2238,10 @@ add_executable(nr_pbchsim
|
||||
${OPENAIR1_DIR}/SIMULATION/NR_PHY/nr_dummy_functions.c
|
||||
${OPENAIR_DIR}/common/utils/nr/nr_common.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
target_link_libraries(nr_pbchsim PRIVATE
|
||||
-Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB MAC_NR_COMMON -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} ${T_LIB} ITTI dl
|
||||
m pthread ${T_LIB} ITTI dl shlib_loader
|
||||
)
|
||||
target_link_libraries(nr_pbchsim PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2482,11 +2252,10 @@ add_executable(nr_pucchsim
|
||||
${OPENAIR1_DIR}/SIMULATION/NR_PHY/nr_dummy_functions.c
|
||||
${OPENAIR_DIR}/common/utils/nr/nr_common.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
target_link_libraries(nr_pucchsim PRIVATE
|
||||
-Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB MAC_NR_COMMON -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} ${T_LIB} ITTI dl
|
||||
m pthread ${T_LIB} ITTI dl shlib_loader
|
||||
)
|
||||
target_link_libraries(nr_pucchsim PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2501,11 +2270,10 @@ add_executable(nr_dlsim
|
||||
${NFAPI_USER_DIR}/gnb_ind_vars.c
|
||||
${PHY_INTERFACE_DIR}/queue_t.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
target_link_libraries(nr_dlsim PRIVATE
|
||||
-Wl,--start-group UTIL SIMU SIMU_ETH PHY_COMMON PHY_NR_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB SCHED_NR_UE_LIB MAC_NR MAC_UE_NR MAC_NR_COMMON nr_rrc CONFIG_LIB L2_NR HASHTABLE x2ap SECURITY ngap -lz -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} ${T_LIB} ITTI ${OPENSSL_LIBRARIES} dl
|
||||
m pthread ${T_LIB} ITTI dl shlib_loader
|
||||
)
|
||||
target_link_libraries(nr_dlsim PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2514,10 +2282,10 @@ add_executable(nr_prachsim
|
||||
${OPENAIR1_DIR}/SIMULATION/NR_PHY/nr_dummy_functions.c
|
||||
${OPENAIR_DIR}/common/utils/nr/nr_common.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES})
|
||||
)
|
||||
target_link_libraries(nr_prachsim PRIVATE
|
||||
-Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR_COMMON PHY_NR PHY_RU PHY_NR_UE MAC_NR_COMMON SCHED_NR_LIB CONFIG_LIB -lz -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} ${T_LIB} ITTI ${OPENSSL_LIBRARIES} dl)
|
||||
m pthread ${T_LIB} ITTI dl shlib_loader)
|
||||
target_link_libraries(nr_prachsim PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
add_executable(nr_ulschsim
|
||||
@@ -2526,11 +2294,10 @@ add_executable(nr_ulschsim
|
||||
${OPENAIR_DIR}/common/utils/nr/nr_common.c
|
||||
${PHY_INTERFACE_DIR}/queue_t.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
target_link_libraries(nr_ulschsim PRIVATE
|
||||
-Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB MAC_NR_COMMON -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} ${T_LIB} ITTI dl
|
||||
m pthread ${T_LIB} ITTI dl shlib_loader
|
||||
)
|
||||
target_link_libraries(nr_ulschsim PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2545,7 +2312,6 @@ add_executable(nr_ulsim
|
||||
${NFAPI_USER_DIR}/gnb_ind_vars.c
|
||||
${PHY_INTERFACE_DIR}/queue_t.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
)
|
||||
|
||||
if (ENABLE_LDPC_T1)
|
||||
@@ -2554,7 +2320,7 @@ endif()
|
||||
|
||||
target_link_libraries(nr_ulsim PRIVATE
|
||||
-Wl,--start-group UTIL SIMU SIMU_ETH PHY_COMMON PHY_NR_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB SCHED_NR_UE_LIB MAC_NR MAC_UE_NR MAC_NR_COMMON nr_rrc CONFIG_LIB L2_NR HASHTABLE x2ap SECURITY ngap -lz -Wl,--end-group
|
||||
m pthread ${ATLAS_LIBRARIES} ${T_LIB} ITTI ${OPENSSL_LIBRARIES} dl
|
||||
m pthread ${T_LIB} ITTI dl shlib_loader
|
||||
)
|
||||
target_link_libraries(nr_ulsim PRIVATE asn1_nr_rrc_hdrs asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2566,12 +2332,11 @@ foreach(myExe dlsim dlsim_tm7 ulsim pbchsim scansim mbmssim pdcchsim pucchsim pr
|
||||
${OPENAIR_DIR}/common/utils/lte/prach_utils.c
|
||||
${OPENAIR1_DIR}/PHY/INIT/lte_param_init.c
|
||||
${T_SOURCE}
|
||||
${SHLIB_LOADER_SOURCES}
|
||||
${NFAPI_USER_DIR}/nfapi.c
|
||||
)
|
||||
target_link_libraries (${myExe} PRIVATE
|
||||
-Wl,--start-group SIMU UTIL SCHED_LIB SCHED_RU_LIB SCHED_UE_LIB PHY_COMMON PHY_NR_COMMON PHY PHY_UE PHY_RU ITTI -Wl,--end-group
|
||||
pthread m rt CONFIG_LIB ${ATLAS_LIBRARIES} ${T_LIB} dl
|
||||
pthread m rt CONFIG_LIB ${T_LIB} dl shlib_loader
|
||||
)
|
||||
target_link_libraries(${myExe} PRIVATE asn1_lte_rrc_hdrs)
|
||||
|
||||
@@ -2592,7 +2357,7 @@ foreach(myExe s1ap
|
||||
${OPENAIR3_DIR}/TEST/test_${myExe}.c
|
||||
)
|
||||
target_link_libraries (test_${myExe}
|
||||
-Wl,--start-group SECURITY UTIL -Wl,--end-group m rt crypt ${CRYPTO_LIBRARIES} ${OPENSSL_LIBRARIES} CONFIG_LIB
|
||||
-Wl,--start-group SECURITY UTIL -Wl,--end-group m rt CONFIG_LIB
|
||||
)
|
||||
endforeach(myExe)
|
||||
|
||||
@@ -2715,3 +2480,4 @@ add_subdirectory(doc)
|
||||
add_subdirectory(openair1)
|
||||
add_subdirectory(openair2)
|
||||
add_subdirectory(openair3)
|
||||
add_subdirectory(radio)
|
||||
|
||||
@@ -102,9 +102,6 @@ find_package(Threads REQUIRED)
|
||||
set (FIRMWARE_VERSION "No svn information")
|
||||
add_definitions("-DFIRMWARE_VERSION=\"${FIRMWARE_VERSION}\"")
|
||||
|
||||
add_boolean_option(LINUX True "????")
|
||||
add_boolean_option(ENB_MODE True "????") # to avoid backtrace
|
||||
|
||||
##########################
|
||||
# NAS LAYER OPTIONS
|
||||
##########################
|
||||
|
||||
+75
-212
@@ -37,29 +37,18 @@ set_openair_env
|
||||
gen_nvram_path=$OPENAIR_DIR/cmake_targets/ran_build/build
|
||||
conf_nvram_path=$OPENAIR_DIR/openair3/NAS/TOOLS/ue_eurecom_test_sfr.conf
|
||||
|
||||
XFORMS="True"
|
||||
SKIP_SHARED_LIB_FLAG="False"
|
||||
PRINT_STATS="False"
|
||||
HW="None"
|
||||
TP="Ethernet"
|
||||
EPC=0
|
||||
HW=""
|
||||
VERBOSE_CI=0
|
||||
VERBOSE_COMPILE=0
|
||||
RUN_GROUP=0
|
||||
TEST_CASE_GROUP=""
|
||||
BUILD_DIR=ran_build
|
||||
BUILD_DOXYGEN=0
|
||||
BUILD_COVERITY_SCAN=0
|
||||
DISABLE_HARDWARE_DEPENDENCY="False"
|
||||
CMAKE_BUILD_TYPE="RelWithDebInfo"
|
||||
CMAKE_CMD="$CMAKE"
|
||||
MAKE_CMD=make
|
||||
BUILD_ECLIPSE=0
|
||||
NR="False"
|
||||
OPTIONAL_LIBRARIES="telnetsrv enbscope uescope nrscope nrqtscope ldpc_cuda ldpc_t1 websrv oai_iqplayer"
|
||||
RU=0
|
||||
CMAKE_C_FLAGS=()
|
||||
CMAKE_CXX_FLAGS=()
|
||||
TARGET_LIST=""
|
||||
|
||||
function print_help() {
|
||||
echo_info "
|
||||
@@ -85,9 +74,6 @@ Options:
|
||||
This option will require root password
|
||||
--install-optional-packages
|
||||
Install useful but not mandatory packages such as valgrind
|
||||
-i | --install-system-files
|
||||
Install OpenAirInterface required files in Linux system
|
||||
This option will require root password
|
||||
-g | --run-with-gdb <Release | RelWithDebInfo | MinSizeRel | Debug
|
||||
specify the build mode used by cmake. defaults to Debug mode if -g is used alone, with no mode parameter
|
||||
if -g is not specifies, Release mode is used.
|
||||
@@ -180,8 +166,7 @@ function main() {
|
||||
do
|
||||
case "$1" in
|
||||
--arch-native)
|
||||
CMAKE_C_FLAGS+=("-march=native")
|
||||
CMAKE_CXX_FLAGS+=("-march=native")
|
||||
echo_fatal "Error: specify --arch-native on the command line to cmake directly: ./build_oai --cmake-opt \"-DCMAKE_C_FLAGS=-march=native -DCMAKE_CXX_FLAGS=-march=native\""
|
||||
shift;;
|
||||
-c | --clean)
|
||||
CLEAN=1
|
||||
@@ -211,10 +196,6 @@ function main() {
|
||||
INSTALL_OPTIONAL=1
|
||||
echo_info "Will install optional packages"
|
||||
shift;;
|
||||
-i | --install-system-files)
|
||||
INSTALL_SYSTEM_FILES=1
|
||||
echo_info "Will copy OpenAirInterface files in Linux directories"
|
||||
shift;;
|
||||
-g | --run-with-gdb)
|
||||
case "$2" in
|
||||
"Release")
|
||||
@@ -250,23 +231,27 @@ function main() {
|
||||
shift;;
|
||||
--eNB)
|
||||
eNB=1
|
||||
TARGET_LIST="$TARGET_LIST lte-softmodem"
|
||||
echo_info "Will compile eNB"
|
||||
shift;;
|
||||
--gNB)
|
||||
gNB=1
|
||||
TARGET_LIST="$TARGET_LIST nr-softmodem nr-cuup"
|
||||
echo_info "Will compile gNB"
|
||||
shift;;
|
||||
--RU)
|
||||
RU=1
|
||||
TARGET_LIST="$TARGET_LIST oairu"
|
||||
echo_info "Will compile RRU"
|
||||
shift;;
|
||||
--UE)
|
||||
UE=1
|
||||
TARGET_LIST="$TARGET_LIST lte-uesoftmodem"
|
||||
echo_info "Will compile UE"
|
||||
shift;;
|
||||
--nrUE)
|
||||
nrUE=1
|
||||
rfsimNas=1
|
||||
TARGET_LIST="$TARGET_LIST nr-uesoftmodem"
|
||||
echo_info "Will compile NR UE"
|
||||
shift;;
|
||||
--mu)
|
||||
@@ -280,30 +265,48 @@ function main() {
|
||||
gen_nvram_path=$(readlink -f "$2")
|
||||
shift 2;;
|
||||
--UE-ip)
|
||||
UE_ip=1
|
||||
echo_info "Will compile UE"
|
||||
TARGET_LIST="$TARGET_LIST ue_ip"
|
||||
shift;;
|
||||
-w | --hardware)
|
||||
# Use OAI_USRP as the key word USRP is used inside UHD driver
|
||||
case "$2" in
|
||||
"USRP" | "BLADERF" | "LMSSDR" | "IRIS" | "SIMU" | "AW2SORI")
|
||||
"USRP" | "BLADERF" | "LMSSDR" | "IRIS" | "SIMU")
|
||||
HW="OAI_"$2
|
||||
TARGET_LIST="$TARGET_LIST oai_${2,,}devif" # ,, makes lowercase
|
||||
CMAKE_CMD="$CMAKE_CMD -DOAI_$2=ON"
|
||||
;;
|
||||
"AW2SORI")
|
||||
HW="OAI_"$2
|
||||
TARGET_LIST="$TARGET_LIST aw2sori_transpro"
|
||||
CMAKE_CMD="$CMAKE_CMD -DOAI_$2=ON"
|
||||
;;
|
||||
"None")
|
||||
HW="None"
|
||||
;;
|
||||
*)
|
||||
echo_fatal "Unknown HW type $HW: exit..."
|
||||
echo_fatal "Unknown hardware type $2: exit..."
|
||||
;;
|
||||
esac
|
||||
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
|
||||
case "$2" in
|
||||
"Ethernet")
|
||||
TARGET_LIST="$TARGET_LIST oai_eth_transpro"
|
||||
CMAKE_CMD="$CMAKE_CMD -DOAI_${2^^}=ON" # ^^ makes uppercase
|
||||
;;
|
||||
"benetel4g" | "benetel5g")
|
||||
TARGET_LIST="$TARGET_LIST $2"
|
||||
CMAKE_CMD="$CMAKE_CMD -DOAI_${2^^}=ON" # ^^ makes uppercase
|
||||
;;
|
||||
"None")
|
||||
;;
|
||||
*)
|
||||
echo_fatal "Unknown transport type $2; exit..."
|
||||
;;
|
||||
esac
|
||||
shift 2;;
|
||||
-P | --phy_simulators)
|
||||
SIMUS_PHY=1
|
||||
# TODO: fix: dlsim_tm4 pucchsim prachsim pdcchsim pbchsim mbmssim
|
||||
TARGET_LIST="$TARGET_LIST dlsim ulsim ldpctest polartest smallblocktest nr_pbchsim nr_dlschsim nr_ulschsim nr_dlsim nr_ulsim nr_pucchsim nr_prachsim"
|
||||
echo_info "Will compile dlsim, ulsim, ..."
|
||||
shift;;
|
||||
-s | --check)
|
||||
@@ -318,11 +321,8 @@ function main() {
|
||||
-V | --vcd)
|
||||
echo_info "Setting gtk-wave output"
|
||||
CMAKE_CMD="$CMAKE_CMD -DENABLE_VCD_FIFO=True"
|
||||
EXE_ARGUMENTS="$EXE_ARGUMENTS -V"
|
||||
shift;;
|
||||
-x | --xforms)
|
||||
XFORMS=1
|
||||
EXE_ARGUMENTS="$EXE_ARGUMENTS -d"
|
||||
echo_info "Will generate the software oscilloscope features"
|
||||
shift;;
|
||||
--verbose-ci)
|
||||
@@ -338,10 +338,6 @@ function main() {
|
||||
BUILD_DOXYGEN=1
|
||||
echo_info "Will build doxygen support"
|
||||
shift;;
|
||||
--build-coverity-scan)
|
||||
BUILD_COVERITY_SCAN=1
|
||||
echo_info "Will build Coverity-Scan objects for upload"
|
||||
shift;;
|
||||
--disable-T-Tracer)
|
||||
CMAKE_CMD="$CMAKE_CMD -DT_TRACER=False"
|
||||
echo_info "Disabling the T tracer"
|
||||
@@ -367,31 +363,23 @@ function main() {
|
||||
echo_info "Downloading UHD images in the indicated location"
|
||||
shift 2;;
|
||||
--build-eclipse)
|
||||
BUILD_ECLIPSE=1
|
||||
CMAKE_CMD="$CMAKE_CMD"' -DCMAKE_ECLIPSE_GENERATE_SOURCE_PROJECT=TRUE -G"Eclipse CDT4 - Unix Makefiles"'
|
||||
echo_info "Enabling build eclipse project support"
|
||||
shift 1;;
|
||||
--build-lib)
|
||||
BUILD_OPTLIB=""
|
||||
if [ "$2" == "all" ] ; then
|
||||
BUILD_OPTLIB="$OPTIONAL_LIBRARIES"
|
||||
TARGET_LIST="$TARGET_LIST $OPTIONAL_LIBRARIES"
|
||||
for lib in $OPTIONAL_LIBRARIES; do CMAKE_CMD="$CMAKE_CMD -DENABLE_${lib^^}=ON"; done
|
||||
echo_info "Enabling build of all optional shared libraries ($OPTIONAL_LIBRARIES)"
|
||||
else
|
||||
for alib in $2 ; do
|
||||
for oklib in $OPTIONAL_LIBRARIES ; do
|
||||
if [ "$alib" = "$oklib" ] ; then
|
||||
BUILD_OPTLIB="$BUILD_OPTLIB $alib"
|
||||
echo_info "Enabling build of lib${alib}.so"
|
||||
fi
|
||||
done
|
||||
for reqlib in $2; do
|
||||
lib=$(echo $OPTIONAL_LIBRARIES | tr ' ' '\n' | grep -w $reqlib) # search given parameter in list
|
||||
[[ $? -ne 0 ]] && echo_fatal "Unknown optional library in $reqlib, valid libraries are $OPTIONAL_LIBRARIES"
|
||||
TARGET_LIST="$TARGET_LIST $lib" # will append the found library
|
||||
CMAKE_CMD="$CMAKE_CMD -DENABLE_${lib^^}=ON"
|
||||
echo_info "Enabling build of optional shared library $lib"
|
||||
done
|
||||
if [ "${BUILD_OPTLIB## }" != "$2" ] ; then
|
||||
echo_fatal "Unknown optional library in $2, valid libraries are $OPTIONAL_LIBRARIES"
|
||||
fi
|
||||
fi
|
||||
for oklib in $BUILD_OPTLIB ; do
|
||||
CMAKE_CMD="$CMAKE_CMD -DENABLE_${oklib^^}=ON"
|
||||
done
|
||||
shift 2;;
|
||||
--noavx512)
|
||||
CMAKE_CMD="$CMAKE_CMD -DAVX512=OFF"
|
||||
@@ -401,13 +389,8 @@ function main() {
|
||||
CMAKE_CMD="$CMAKE_CMD -DAVX2=OFF"
|
||||
echo_info "Disabling AVX2 instructions"
|
||||
shift 1;;
|
||||
-k | --skip-shared-libraries)
|
||||
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)
|
||||
CMAKE_CMD="$CMAKE_CMD -DSANITIZE_ADDRESS=True -DSANITIZE_UNDEFINED=True"
|
||||
@@ -429,48 +412,15 @@ function main() {
|
||||
esac
|
||||
done
|
||||
|
||||
###################################
|
||||
# Check if cov-build is installed #
|
||||
###################################
|
||||
if [ "$BUILD_COVERITY_SCAN" == "1" ] ; then
|
||||
echo_info "Checking cov-build is installed"
|
||||
IS_INSTALLED=`which cov-build | grep -c cov-build || true`
|
||||
if [ $IS_INSTALLED -eq 1 ] ; then
|
||||
echo_info "Found cov-build"
|
||||
else
|
||||
echo_fatal "Did NOT find cov-build in PATH!"
|
||||
fi
|
||||
fi
|
||||
|
||||
########################################################
|
||||
# Check validity of HW and TP parameters for eNB / gNB #
|
||||
########################################################
|
||||
# to be discussed
|
||||
|
||||
if [ "$eNB" = "1" -o "$gNB" = "1" ] ; then
|
||||
if [ "$HW" = "None" -a "$TP" = "None" ] ; then
|
||||
echo_info "No local radio head and no transport protocol selected"
|
||||
fi
|
||||
if [ "$HW" = "None" ] ; then
|
||||
echo_info "No radio head has been selected (HW set to $HW)"
|
||||
fi
|
||||
if [ "$TP" = "None" ] ; then
|
||||
echo_info "No transport protocol has been selected (TP set to $TP)"
|
||||
fi
|
||||
fi
|
||||
|
||||
echo_info "RF HW set to $HW"
|
||||
# If the user doesn't specify the Linux scheduler to use, we set a value
|
||||
|
||||
#######################################################
|
||||
# Setting and printing OAI envs, we should check here #
|
||||
#######################################################
|
||||
|
||||
cecho "OPENAIR_DIR = $OPENAIR_DIR" $green
|
||||
echo "OPENAIR_DIR = $OPENAIR_DIR"
|
||||
|
||||
if [ "$CLEAN_ALL" = "1" ] ; then
|
||||
clean_all_files
|
||||
echo_info "Erased all previously producted files"
|
||||
echo "Erased all previously producted files"
|
||||
fi
|
||||
|
||||
dlog=$OPENAIR_DIR/cmake_targets/log
|
||||
@@ -507,134 +457,47 @@ function main() {
|
||||
check_install_additional_tools
|
||||
fi
|
||||
|
||||
execlist=""
|
||||
[[ "$eNB" == "1" ]] && execlist="$execlist lte-softmodem"
|
||||
[[ "$gNB" == "1" ]] && execlist="$execlist nr-softmodem nr-cuup"
|
||||
[[ "$RU" == "1" ]] && execlist="$execlist oairu"
|
||||
[[ "$UE" == 1 ]] && execlist="$execlist lte-uesoftmodem"
|
||||
[[ "$nrUE" == 1 ]] && execlist="$execlist nr-uesoftmodem"
|
||||
# TODO: fix: dlsim_tm4 pucchsim prachsim pdcchsim pbchsim mbmssim
|
||||
[[ "$SIMUS_PHY" == "1" ]] && execlist="$execlist dlsim ulsim ldpctest polartest smallblocktest nr_pbchsim nr_dlschsim nr_ulschsim nr_dlsim nr_ulsim nr_pucchsim nr_prachsim"
|
||||
[[ "$BUILD_OPTLIB" != "" ]] && execlist="$execlist $BUILD_OPTLIB"
|
||||
[[ "$execlist" != "" ]] && execlist="$execlist params_libconfig coding rfsimulator"
|
||||
|
||||
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
|
||||
|
||||
# for historical reasons we build in a subdirectory cmake_targets/XYZ/build,
|
||||
# e.g., cmake_targets/ran_build/build, hence the ../../..
|
||||
CMAKE_CMD="$CMAKE_CMD ../../.."
|
||||
echo_info "running $CMAKE_CMD"
|
||||
eval $CMAKE_CMD
|
||||
|
||||
if [[ "$execlist" != "" ]]; then
|
||||
echo_info "Compiling $execlist..."
|
||||
compilations $BUILD_DIR all.txt $execlist
|
||||
fi
|
||||
|
||||
if [ "$UE" = 1 ] ; then
|
||||
|
||||
echo_info "Compiling UE specific part"
|
||||
|
||||
if [ "$UE_ip" = 1 ]
|
||||
then
|
||||
echo_info "Building ue_ip module"
|
||||
compilations $BUILD_DIR ue_ip.txt ue_ip
|
||||
else
|
||||
echo_info "Bypassing ue_ip build"
|
||||
fi #IS_CONTAINER
|
||||
|
||||
# mkdir -p $DIR/at_commands/build
|
||||
# cd $DIR/at_commands/build
|
||||
# eval $CMAKE_CMD
|
||||
# compilations at_commands at_nas_ue
|
||||
|
||||
[ "$CLEAN" = "1" ] && rm -rf $DIR/nas_sim_tools/build
|
||||
mkdir -p $DIR/nas_sim_tools/build
|
||||
cd $DIR/nas_sim_tools/build
|
||||
|
||||
eval $CMAKE_CMD ..
|
||||
compilations nas_sim_tools usim.txt usim
|
||||
compilations nas_sim_tools nvram.txt nvram
|
||||
compilations nas_sim_tools conf2uedata.txt conf2uedata
|
||||
|
||||
# generate USIM data
|
||||
if [ -f conf2uedata ]; then
|
||||
install_nas_tools $conf_nvram_path $DIR/$BUILD_DIR/build "$DIR/$BUILD_DIR/build/conf2uedata.txt"
|
||||
else
|
||||
echo_warning "not generated UE NAS files: binaries not found"
|
||||
if [[ $TARGET_LIST != "" ]]; then
|
||||
# add some default libraries that should always be built
|
||||
# for eNB, gNB, UEs, simulators
|
||||
if [[ $gNB == 1 || $eNB == 1 || $UE == 1 || $nrUE == 1 || $SIMUS_PHY == 1 || $RU == 1 ]]; then
|
||||
TARGET_LIST="$TARGET_LIST params_libconfig coding rfsimulator dfts"
|
||||
fi
|
||||
fi
|
||||
|
||||
####################################################
|
||||
# Build RF device and transport protocol libraries #
|
||||
####################################################
|
||||
if [ "$eNB" = "1" -o "$UE" = "1" -o "$gNB" = "1" -o "$RU" = "1" -o "$nrUE" = "1" ] ; then
|
||||
mkdir -p $DIR/$BUILD_DIR/build
|
||||
cd $DIR/$BUILD_DIR/build
|
||||
|
||||
# build RF device libraries
|
||||
if [ "$HW" != "None" ] ; then
|
||||
rm -f liboai_device.so
|
||||
# for historical reasons we build in a subdirectory cmake_targets/XYZ/build,
|
||||
# e.g., cmake_targets/ran_build/build, hence the ../../..
|
||||
CMAKE_CMD="$CMAKE_CMD ../../.."
|
||||
echo_info "Running \"$CMAKE_CMD\""
|
||||
eval $CMAKE_CMD
|
||||
compilations $BUILD_DIR all.txt $TARGET_LIST
|
||||
|
||||
if [ "$HW" == "OAI_USRP" ] ; then
|
||||
compilations $BUILD_DIR oai_usrpdevif.txt oai_usrpdevif
|
||||
if [ "$UE" = 1 ] ; then
|
||||
|
||||
ln -sf liboai_usrpdevif.so liboai_device.so
|
||||
echo_info "liboai_device.so is linked to USRP device library"
|
||||
elif [ "$HW" == "OAI_BLADERF" ] ; then
|
||||
if [ -f "/usr/include/libbladeRF.h" ] ; then
|
||||
compilations $BUILD_DIR oai_bladerfdevif.txt oai_bladerfdevif
|
||||
fi
|
||||
echo_info "Compiling UE specific part"
|
||||
|
||||
ln -sf liboai_bladerfdevif.so liboai_device.so
|
||||
echo_info "liboai_device.so is linked to BLADERF device library"
|
||||
elif [ "$HW" == "OAI_LMSSDR" ] ; then
|
||||
# if [ -f "/usr/include/libbladeRF.h" ] ; then
|
||||
compilations $BUILD_DIR oai_lmssdrdevif.txt oai_lmssdrdevif
|
||||
# fi
|
||||
[ "$CLEAN" = "1" ] && rm -rf $DIR/nas_sim_tools/build
|
||||
mkdir -p $DIR/nas_sim_tools/build
|
||||
cd $DIR/nas_sim_tools/build
|
||||
|
||||
ln -sf liboai_lmssdrdevif.so liboai_device.so
|
||||
echo_info "liboai_device.so is linked to LMSSDR device library"
|
||||
elif [ "$HW" == "OAI_IRIS" ] ; then
|
||||
compilations $BUILD_DIR oai_irisdevif.txt oai_irisdevif
|
||||
eval $CMAKE_CMD ..
|
||||
compilations nas_sim_tools usim.txt usim
|
||||
compilations nas_sim_tools nvram.txt nvram
|
||||
compilations nas_sim_tools conf2uedata.txt conf2uedata
|
||||
|
||||
ln -s liboai_irisdevif.so liboai_device.so
|
||||
echo_info "liboai_device.so is linked to IRIS device library"
|
||||
elif [ "$HW" == "OAI_AW2SORI" ] ; then
|
||||
compilations $BUILD_DIR aw2sori_transpro.txt aw2sori_transpro
|
||||
|
||||
ln -sf libaw2sori_transpro.so libthirdparty_transpro.so
|
||||
echo_info "build libthirdparty_transpro.so for AW2SORI fronthaul"
|
||||
else
|
||||
echo_info "liboai_device.so is not linked to any device library"
|
||||
fi
|
||||
fi
|
||||
|
||||
#build transport protocol libraries (currently only ETHERNET is available)
|
||||
if [ "$SKIP_SHARED_LIB_FLAG" = "False" ]; then
|
||||
echo_info "Building transport protocol libraries"
|
||||
rm -f liboai_transpro.so
|
||||
if [ "$TP" == "Ethernet" ]; then
|
||||
compilations $BUILD_DIR oai_eth_transpro.txt oai_eth_transpro
|
||||
ln -sf liboai_eth_transpro.so liboai_transpro.so
|
||||
echo_info "liboai_transpro.so is linked to ETHERNET transport"
|
||||
fi
|
||||
if [ "$TP" == "benetel4g" ]; then
|
||||
compilations $BUILD_DIR benetel_4g.txt benetel4g
|
||||
ln -sf libbenetel_4g.so liboai_transpro.so
|
||||
echo_info "liboai_transpro.so is linked to BENETEL4G transport"
|
||||
fi
|
||||
if [ "$TP" == "benetel5g" ]; then
|
||||
compilations $BUILD_DIR benetel_5g.txt benetel_5g
|
||||
ln -sf libbenetel_5g.so liboai_transpro.so
|
||||
echo_info "liboai_transpro.so is linked to BENETEL4G transport"
|
||||
fi
|
||||
# generate USIM data
|
||||
if [ -f conf2uedata ]; then
|
||||
install_nas_tools $conf_nvram_path $DIR/$BUILD_DIR/build "$DIR/$BUILD_DIR/build/conf2uedata.txt"
|
||||
else
|
||||
echo_warning "not generated UE NAS files: binaries not found"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
###################
|
||||
@@ -646,7 +509,7 @@ function main() {
|
||||
echo_info "Doxygen generation log is located here: $doxygen_log"
|
||||
echo_info "Generating Doxygen files....please wait"
|
||||
(
|
||||
$MAKE_CMD doc
|
||||
cmake --build . --target doc
|
||||
) >& $doxygen_log
|
||||
fi
|
||||
|
||||
|
||||
@@ -216,35 +216,26 @@ check_errors() {
|
||||
}
|
||||
|
||||
compilations() {
|
||||
[[ $# -gt 2 ]] || echo_fatal "compilations needs more than three arguments"
|
||||
local dir=$1
|
||||
shift 1
|
||||
local logfile=$1
|
||||
shift 1
|
||||
local targets=$@
|
||||
local verbose=$([ "$VERBOSE_COMPILE" == "1" ] && echo "-v" || echo "")
|
||||
echo cd $OPENAIR_DIR/cmake_targets/$dir/build
|
||||
cd $OPENAIR_DIR/cmake_targets/$dir/build
|
||||
echo_info "Log file for compilation is being written to: $dlog/$logfile"
|
||||
echo_info "Running \"cmake --build . $verbose --target $targets -- -j$(nproc)\"" $green
|
||||
echo "Log file for compilation is being written to: $dlog/$logfile"
|
||||
set +e
|
||||
{
|
||||
if [ "$BUILD_COVERITY_SCAN" == "1" ]; then
|
||||
COV_SCAN_PREFIX="cov-build --dir cov-int"
|
||||
else
|
||||
COV_SCAN_PREFIX=""
|
||||
fi
|
||||
if [ "$MAKE_CMD" != "" ]; then
|
||||
$MAKE_CMD $targets
|
||||
else
|
||||
if [ "$VERBOSE_COMPILE" == "1" ]; then
|
||||
$COV_SCAN_PREFIX make -j`nproc` $targets VERBOSE=$VERBOSE_COMPILE
|
||||
else
|
||||
$COV_SCAN_PREFIX make -j`nproc` $targets
|
||||
fi
|
||||
fi
|
||||
cmake --build . $verbose --target $targets -- -j$(nproc)
|
||||
ret=$?
|
||||
} > $dlog/$logfile 2>&1
|
||||
if [ "$VERBOSE_CI" == "1" ]; then
|
||||
echo_info "====== Start of log for $logfile ======"
|
||||
echo "====== Start of log for $logfile ======"
|
||||
cat $dlog/$logfile
|
||||
echo_info "====== End of log for $logfile ======"
|
||||
echo "====== End of log for $logfile ======"
|
||||
fi
|
||||
check_warnings "$dlog/$logfile"
|
||||
if [[ $ret -eq 0 ]]; then
|
||||
|
||||
@@ -15,7 +15,6 @@
|
||||
/* VCD specific defines and includes
|
||||
* If the codebase changes, it may need to be updated
|
||||
*/
|
||||
#define ENB_MODE
|
||||
#define ENABLE_USE_CPU_EXECUTION_TIME
|
||||
#include "../LOG/vcd_signal_dumper.c"
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
#include <stdlib.h>
|
||||
|
||||
#ifndef T_TRACER
|
||||
int T_stdout;
|
||||
#endif
|
||||
|
||||
+5
-5
@@ -874,11 +874,11 @@ INPUT = \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/rfsimulator/rfsimulator.h \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/rfsimulator/simulator.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/rfsimulator/apply_channelmod.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/USERSPACE/LIB/if_defs.h \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/USERSPACE/LIB/ethernet_lib.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/USERSPACE/LIB/eth_udp.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/USERSPACE/LIB/eth_raw.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/if_defs.h \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/ethernet_lib.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/eth_udp.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/ethernet_lib.h \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../radio/ETHERNET/eth_raw.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../common/config/config_cmdline.c \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../common/config/config_paramdesc.h \
|
||||
@CMAKE_CURRENT_SOURCE_DIR@/../common/config/config_userapi.h \
|
||||
|
||||
@@ -35,4 +35,4 @@ COPY . .
|
||||
RUN /bin/sh oaienv && \
|
||||
cd cmake_targets && \
|
||||
mkdir -p log && \
|
||||
./build_oai --eNB --gNB --RU --UE --nrUE --ninja --build-lib "telnetsrv enbscope uescope nrscope" -w USRP --verbose-ci --noavx512 -c
|
||||
./build_oai --eNB --gNB --RU --UE --nrUE --ninja --build-lib "telnetsrv enbscope uescope nrscope" -w USRP -t Ethernet --verbose-ci --noavx512 -c
|
||||
|
||||
@@ -35,4 +35,4 @@ COPY . .
|
||||
RUN /bin/sh oaienv && \
|
||||
cd cmake_targets && \
|
||||
mkdir -p log && \
|
||||
./build_oai --eNB --gNB --RU --UE --nrUE --ninja --build-lib "telnetsrv enbscope uescope nrscope" -w USRP --verbose-ci --noavx512 -c
|
||||
./build_oai --eNB --gNB --RU --UE --nrUE --ninja --build-lib "telnetsrv enbscope uescope nrscope" -w USRP -t Ethernet --verbose-ci --noavx512 -c
|
||||
|
||||
@@ -35,4 +35,4 @@ COPY . .
|
||||
RUN /bin/sh oaienv && \
|
||||
cd cmake_targets && \
|
||||
mkdir -p log && \
|
||||
./build_oai --eNB --gNB --RU --UE --nrUE --ninja --build-lib "telnetsrv enbscope uescope nrscope nrqtscope" -w USRP --verbose-ci --noavx512 -c --cmake-opt -DCMAKE_C_FLAGS=-Werror --cmake-opt -DCMAKE_CXX_FLAGS=-Werror
|
||||
./build_oai --eNB --gNB --RU --UE --nrUE --ninja --build-lib "telnetsrv enbscope uescope nrscope nrqtscope" -w USRP -t Ethernet --verbose-ci --noavx512 -c --cmake-opt -DCMAKE_C_FLAGS=-Werror --cmake-opt -DCMAKE_CXX_FLAGS=-Werror
|
||||
|
||||
@@ -72,6 +72,7 @@ COPY --from=enb-build \
|
||||
COPY --from=enb-base \
|
||||
/lib64/libconfig.so.11 \
|
||||
/lib64/libblas.so.3 \
|
||||
/lib64/libcblas.so.3 \
|
||||
/lib64/liblapack.so.3 \
|
||||
/lib64/liblapacke.so.3 \
|
||||
/lib64/libboost_chrono.so.1.75.0 \
|
||||
|
||||
@@ -34,8 +34,8 @@ COPY ./libori.so /usr/local/lib
|
||||
# build AW2S fronthaul lib
|
||||
WORKDIR /oai-ran
|
||||
RUN /bin/sh oaienv && \
|
||||
cd cmake_targets/ran_build/build && \
|
||||
ninja aw2sori_transpro
|
||||
cd cmake_targets/ && \
|
||||
./build_oai -w AW2SORI -t Ethernet
|
||||
|
||||
#start from scratch for target executable
|
||||
FROM registry.access.redhat.com/ubi9/ubi:latest as oai-gnb-aw2s
|
||||
@@ -75,6 +75,7 @@ COPY --from=gnb-base \
|
||||
/lib64/libconfig.so.11 \
|
||||
/lib64/libforms.so.2 \
|
||||
/lib64/libblas.so.3 \
|
||||
/lib64/libcblas.so.3 \
|
||||
/lib64/liblapack.so.3 \
|
||||
/lib64/liblapacke.so.3 \
|
||||
/lib64/
|
||||
|
||||
@@ -35,8 +35,8 @@ COPY ./libori.so /usr/local/lib
|
||||
# build AW2S fronthaul lib
|
||||
WORKDIR /oai-ran
|
||||
RUN /bin/sh oaienv && \
|
||||
cd cmake_targets/ran_build/build && \
|
||||
ninja aw2sori_transpro
|
||||
cd cmake_targets/ && \
|
||||
./build_oai -w AW2SORI -t Ethernet
|
||||
|
||||
#start from scratch for target executable
|
||||
FROM $BASE_IMAGE as oai-gnb-aw2s
|
||||
|
||||
@@ -34,8 +34,8 @@ COPY ./libori.so /usr/local/lib/
|
||||
# build AW2S fronthaul lib
|
||||
WORKDIR /oai-ran
|
||||
RUN /bin/sh oaienv && \
|
||||
cd cmake_targets/ran_build/build && \
|
||||
ninja aw2sori_transpro
|
||||
cd cmake_targets/ && \
|
||||
./build_oai -w AW2SORI -t Ethernet
|
||||
|
||||
#start from scratch for target executable
|
||||
FROM ubuntu:bionic as oai-gnb-aw2s
|
||||
|
||||
@@ -73,6 +73,7 @@ COPY --from=gnb-base \
|
||||
/lib64/libconfig.so.11 \
|
||||
/lib64/libforms.so.2 \
|
||||
/lib64/libblas.so.3 \
|
||||
/lib64/libcblas.so.3 \
|
||||
/lib64/liblapack.so.3 \
|
||||
/lib64/liblapacke.so.3 \
|
||||
/lib64/libboost_chrono.so.1.75.0 \
|
||||
|
||||
@@ -66,6 +66,7 @@ COPY --from=ru-build \
|
||||
COPY --from=ru-base \
|
||||
/lib64/libconfig.so.11 \
|
||||
/lib64/libblas.so.3 \
|
||||
/lib64/libcblas.so.3 \
|
||||
/lib64/liblapack.so.3 \
|
||||
/lib64/liblapacke.so.3 \
|
||||
/lib64/libboost_chrono.so.1.75.0 \
|
||||
|
||||
@@ -73,6 +73,7 @@ COPY --from=lte-ue-build \
|
||||
COPY --from=lte-ue-base \
|
||||
/lib64/libconfig.so.11 \
|
||||
/lib64/libblas.so.3 \
|
||||
/lib64/libcblas.so.3 \
|
||||
/lib64/liblapack.so.3 \
|
||||
/lib64/liblapacke.so.3 \
|
||||
/lib64/libboost_chrono.so.1.75.0 \
|
||||
|
||||
@@ -61,6 +61,7 @@ COPY --from=gnb-build \
|
||||
COPY --from=gnb-base \
|
||||
/lib64/libconfig.so.11 \
|
||||
/lib64/libblas.so.3 \
|
||||
/lib64/libcblas.so.3 \
|
||||
/lib64/liblapack.so.3 \
|
||||
/lib64/liblapacke.so.3 \
|
||||
/lib64/
|
||||
|
||||
@@ -52,6 +52,8 @@ COPY --from=gnb-build \
|
||||
/oai-ran/cmake_targets/ran_build/build/libtelnetsrv.so \
|
||||
/usr/local/lib/
|
||||
|
||||
RUN ldconfig && ldd /opt/oai-gnb/bin/nr-cuup
|
||||
|
||||
# Create directory for configuration files
|
||||
WORKDIR /opt/oai-gnb/etc
|
||||
|
||||
|
||||
@@ -78,6 +78,7 @@ COPY --from=nr-ue-build \
|
||||
COPY --from=nr-ue-base \
|
||||
/lib64/libconfig.so.11 \
|
||||
/lib64/libblas.so.3 \
|
||||
/lib64/libcblas.so.3 \
|
||||
/lib64/liblapack.so.3 \
|
||||
/lib64/liblapacke.so.3 \
|
||||
/lib64/libforms.so.2 \
|
||||
|
||||
@@ -83,6 +83,7 @@ COPY --from=phy-sim-build \
|
||||
/lib64/libXau.so.6 \
|
||||
/lib64/libforms.so.2 \
|
||||
/lib64/libblas.so.3 \
|
||||
/lib64/libcblas.so.3 \
|
||||
/lib64/liblapack.so.3 \
|
||||
/lib64/libexslt.so.0 \
|
||||
/lib64/libxslt.so.1 \
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
#include "common/utils/LOG/log.h"
|
||||
#include "common/utils/LOG/vcd_signal_dumper.h"
|
||||
#include "radio/COMMON/common_lib.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h"
|
||||
#include "radio/ETHERNET/ethernet_lib.h"
|
||||
|
||||
/* these variables have to be defined before including ENB_APP/enb_paramdef.h */
|
||||
static int DEFBANDS[] = {7};
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
//#undef FRAME_LENGTH_COMPLEX_SAMPLES //there are two conflicting definitions, so we better make sure we don't use it at all
|
||||
|
||||
#include "radio/COMMON/common_lib.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/if_defs.h"
|
||||
#include "radio/ETHERNET/if_defs.h"
|
||||
|
||||
//#undef FRAME_LENGTH_COMPLEX_SAMPLES //there are two conflicting definitions, so we better make sure we don't use it at all
|
||||
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
//#undef FRAME_LENGTH_COMPLEX_SAMPLES //there are two conflicting definitions, so we better make sure we don't use it at all
|
||||
|
||||
#include "radio/COMMON/common_lib.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/if_defs.h"
|
||||
#include "radio/ETHERNET/if_defs.h"
|
||||
|
||||
//#undef FRAME_LENGTH_COMPLEX_SAMPLES //there are two conflicting definitions, so we better make sure we don't use it at all
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
|
||||
|
||||
#include "radio/COMMON/common_lib.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/if_defs.h"
|
||||
#include "radio/ETHERNET/if_defs.h"
|
||||
|
||||
#include "PHY/phy_vars.h"
|
||||
#include "PHY/phy_extern.h"
|
||||
|
||||
+1
-1
@@ -38,7 +38,7 @@
|
||||
#include "rt_profiling.h"
|
||||
|
||||
#include "radio/COMMON/common_lib.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h"
|
||||
#include "radio/ETHERNET/ethernet_lib.h"
|
||||
|
||||
#include "PHY/LTE_TRANSPORT/if4_tools.h"
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
//#undef FRAME_LENGTH_COMPLEX_SAMPLES //there are two conflicting definitions, so we better make sure we don't use it at all
|
||||
|
||||
#include "radio/COMMON/common_lib.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/if_defs.h"
|
||||
#include "radio/ETHERNET/if_defs.h"
|
||||
|
||||
//#undef FRAME_LENGTH_COMPLEX_SAMPLES //there are two conflicting definitions, so we better make sure we don't use it at all
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
#include "common/utils/nr/nr_common.h"
|
||||
|
||||
#include "radio/COMMON/common_lib.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/if_defs.h"
|
||||
#include "radio/ETHERNET/if_defs.h"
|
||||
|
||||
//#undef FRAME_LENGTH_COMPLEX_SAMPLES //there are two conflicting definitions, so we better make sure we don't use it at all
|
||||
#include "openair1/PHY/MODULATION/nr_modulation.h"
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
|
||||
|
||||
#include "radio/COMMON/common_lib.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h"
|
||||
#include "radio/ETHERNET/ethernet_lib.h"
|
||||
|
||||
#include "PHY/LTE_TRANSPORT/if4_tools.h"
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -41,14 +41,8 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <linux/version.h>
|
||||
#if defined RHEL_RELEASE_CODE && RHEL_RELEASE_CODE >= 1796 && RHEL_RELEASE_CODE != 2403
|
||||
#include <lapacke/lapacke_utils.h>
|
||||
#include <lapacke/lapacke.h>
|
||||
#else
|
||||
#include <lapacke_utils.h>
|
||||
#include <lapacke.h>
|
||||
#endif
|
||||
#include <cblas.h>
|
||||
#include <lapacke_utils.h>
|
||||
#include <lapacke.h>
|
||||
#include "linear_preprocessing_rec.h"
|
||||
|
||||
//#define DEBUG_MMSE
|
||||
|
||||
@@ -14,13 +14,8 @@ data storage. */
|
||||
#include <cblas.h>
|
||||
#include <string.h>
|
||||
#include <linux/version.h>
|
||||
#if defined RHEL_RELEASE_CODE && RHEL_RELEASE_CODE >= 1796 && RHEL_RELEASE_CODE != 2403
|
||||
#include <lapacke/lapacke_utils.h>
|
||||
#include <lapacke/lapacke.h>
|
||||
#else
|
||||
#include <lapacke_utils.h>
|
||||
#include <lapacke.h>
|
||||
#endif
|
||||
//#define DEBUG_PREPROC
|
||||
|
||||
|
||||
|
||||
@@ -29,6 +29,13 @@
|
||||
#* \warning
|
||||
#*/
|
||||
|
||||
find_library(forms NAMES forms)
|
||||
if(NOT forms)
|
||||
message(FATAL_ERROR "required library forms not found for building scopes")
|
||||
else()
|
||||
message(STATUS "libforms library, required for scopes, found at ${forms}")
|
||||
endif()
|
||||
|
||||
include_directories ("/usr/include/X11")
|
||||
add_library(xforms_common OBJECT
|
||||
lte_phy_scope.c
|
||||
|
||||
@@ -50,7 +50,6 @@ int main(int argc, char **argv) {
|
||||
|
||||
|
||||
int N_RB=50;
|
||||
int subCarrierFreq=30e3;
|
||||
int sampling_rate=30.72e6;
|
||||
int DFT=2048;
|
||||
int TxAdvanceInDFTSize=12;
|
||||
@@ -325,17 +324,8 @@ int main(int argc, char **argv) {
|
||||
while(!oai_exit) {
|
||||
for (int i=0; i<antennas; i++)
|
||||
read(fd, samplesTx[i], DFT*sizeof(c16_t));
|
||||
int readBlockSize = rfdevice.trx_read_func(&rfdevice,
|
||||
×tamp,
|
||||
samplesRx,
|
||||
DFT,
|
||||
antennas);
|
||||
int txs = rfdevice.trx_write_func(&rfdevice,
|
||||
timestamp+TxAdvanceInDFTSize*DFT,
|
||||
samplesTx,
|
||||
DFT,
|
||||
antennas,
|
||||
0);
|
||||
rfdevice.trx_read_func(&rfdevice, ×tamp, samplesRx, DFT, antennas);
|
||||
rfdevice.trx_write_func(&rfdevice, timestamp + TxAdvanceInDFTSize * DFT, samplesTx, DFT, antennas, 0);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
@@ -30,13 +30,8 @@
|
||||
#ifndef __PLATFORM_TYPES_H__
|
||||
#define __PLATFORM_TYPES_H__
|
||||
|
||||
#if !defined(NAS_NETLINK)
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
#else
|
||||
#include <linux/types.h>
|
||||
typedef void * intptr_t;
|
||||
#endif
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// GENERIC ACCESS STRATUM TYPES
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include "SystemInformationBlockType2.h"
|
||||
|
||||
#include "PHY/phy_extern.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h"
|
||||
#include "radio/ETHERNET/ethernet_lib.h"
|
||||
#include "common/config/config_userapi.h"
|
||||
#include "RRC_config_tools.h"
|
||||
#include "RRC_paramsvalues.h"
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
#include "LAYER2/MAC/mac_proto.h"
|
||||
#include "PHY/phy_extern.h"
|
||||
#include "PHY/INIT/phy_init.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h"
|
||||
#include "radio/ETHERNET/ethernet_lib.h"
|
||||
#include "nfapi_vnf.h"
|
||||
#include "nfapi_pnf.h"
|
||||
#include "executables/lte-softmodem.h"
|
||||
|
||||
@@ -340,6 +340,8 @@
|
||||
#include "F1AP_Cells-To-Be-Broadcast-Item.h"
|
||||
#include "F1AP_QCI.h"
|
||||
|
||||
#include "f1ap_default_values.h"
|
||||
|
||||
#include "conversions.h"
|
||||
#include "platform_types.h"
|
||||
#include "common/utils/LOG/log.h"
|
||||
@@ -359,22 +361,13 @@
|
||||
|
||||
#include "assertions.h"
|
||||
|
||||
#if defined(ENB_MODE)
|
||||
#include "common/utils/LOG/log.h"
|
||||
#include "f1ap_default_values.h"
|
||||
#define F1AP_ERROR(x, args...) LOG_E(F1AP, x, ##args)
|
||||
#define F1AP_WARN(x, args...) LOG_W(F1AP, x, ##args)
|
||||
#define F1AP_TRAF(x, args...) LOG_I(F1AP, x, ##args)
|
||||
#define F1AP_INFO(x, args...) LOG_I(F1AP, x, ##args)
|
||||
#define F1AP_DEBUG(x, args...) LOG_I(F1AP, x, ##args)
|
||||
#else
|
||||
//# include "mme_default_values.h"
|
||||
#define F1AP_ERROR(x, args...) do { fprintf(stdout, "[F1AP][E]"x, ##args); } while(0)
|
||||
#define F1AP_WARN(x, args...) do { fprintf(stdout, "[F1AP][W]"x, ##args); } while(0)
|
||||
#define F1AP_TRAF(x, args...) do { fprintf(stdout, "[F1AP][T]"x, ##args); } while(0)
|
||||
#define F1AP_INFO(x, args...) do { fprintf(stdout, "[F1AP][I]"x, ##args); } while(0)
|
||||
#define F1AP_DEBUG(x, args...) do { fprintf(stdout, "[F1AP][D]"x, ##args); } while(0)
|
||||
#endif
|
||||
#include "common/utils/LOG/log.h"
|
||||
#include "f1ap_default_values.h"
|
||||
#define F1AP_ERROR(x, args...) LOG_E(F1AP, x, ##args)
|
||||
#define F1AP_WARN(x, args...) LOG_W(F1AP, x, ##args)
|
||||
#define F1AP_TRAF(x, args...) LOG_I(F1AP, x, ##args)
|
||||
#define F1AP_INFO(x, args...) LOG_I(F1AP, x, ##args)
|
||||
#define F1AP_DEBUG(x, args...) LOG_I(F1AP, x, ##args)
|
||||
|
||||
//Forward declaration
|
||||
#define F1AP_FIND_PROTOCOLIE_BY_ID(IE_TYPE, ie, container, IE_ID, mandatory) \
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
// #include "LAYER2/MAC/extern.h"
|
||||
// #include "LAYER2/MAC/proto.h"
|
||||
#include "PHY/INIT/nr_phy_init.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h"
|
||||
#include "radio/ETHERNET/ethernet_lib.h"
|
||||
#include "nfapi_vnf.h"
|
||||
#include "nfapi_pnf.h"
|
||||
#include "nr_pdcp/nr_pdcp_oai_api.h"
|
||||
|
||||
@@ -24,7 +24,6 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <stdint.h>
|
||||
#include <openssl/cmac.h>
|
||||
|
||||
#include "openair3/SECU/secu_defs.h"
|
||||
#include "openair3/SECU/key_nas_deriver.h"
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
|
||||
#include "sctp_eNB_defs.h"
|
||||
|
||||
#include "m2ap_default_values.h"
|
||||
#include "m2ap_ids.h" //looks X2AP specific for HO
|
||||
#include "m2ap_timers.h"
|
||||
|
||||
|
||||
@@ -52,19 +52,12 @@
|
||||
|
||||
extern int asn1_xer_print;
|
||||
|
||||
#if defined(ENB_MODE)
|
||||
# include "common/utils/LOG/log.h"
|
||||
# include "m2ap_default_values.h"
|
||||
# define M2AP_INFO(x, args...) LOG_I(M2AP, x, ##args)
|
||||
# define M2AP_ERROR(x, args...) LOG_E(M2AP, x, ##args)
|
||||
# define M2AP_WARN(x, args...) LOG_W(M2AP, x, ##args)
|
||||
# define M2AP_DEBUG(x, args...) LOG_D(M2AP, x, ##args)
|
||||
#else
|
||||
# define M2AP_INFO(x, args...) do { fprintf(stdout, "[M2AP][I]"x, ##args); } while(0)
|
||||
# define M2AP_ERROR(x, args...) do { fprintf(stdout, "[M2AP][E]"x, ##args); } while(0)
|
||||
# define M2AP_WARN(x, args...) do { fprintf(stdout, "[M2AP][W]"x, ##args); } while(0)
|
||||
# define M2AP_DEBUG(x, args...) do { fprintf(stdout, "[M2AP][D]"x, ##args); } while(0)
|
||||
#endif
|
||||
#include "common/utils/LOG/log.h"
|
||||
#include "m2ap_default_values.h"
|
||||
#define M2AP_INFO(x, args...) LOG_I(M2AP, x, ##args)
|
||||
#define M2AP_ERROR(x, args...) LOG_E(M2AP, x, ##args)
|
||||
#define M2AP_WARN(x, args...) LOG_W(M2AP, x, ##args)
|
||||
#define M2AP_DEBUG(x, args...) LOG_D(M2AP, x, ##args)
|
||||
|
||||
#define M2AP_FIND_PROTOCOLIE_BY_ID(IE_TYPE, ie, container, IE_ID, mandatory) \
|
||||
do {\
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
|
||||
#include "sctp_eNB_defs.h"
|
||||
|
||||
#include "m2ap_default_values.h"
|
||||
#include "m2ap_ids.h" //looks X2AP specific for HO
|
||||
#include "m2ap_timers.h"
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
#include "LAYER2/MAC/mac_proto.h"
|
||||
#include "PHY/phy_extern.h"
|
||||
#include "PHY/INIT/phy_init.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h"
|
||||
#include "radio/ETHERNET/ethernet_lib.h"
|
||||
#include "nfapi_vnf.h"
|
||||
#include "nfapi_pnf.h"
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
#include "openair2/RRC/NR_UE/rrc_vars.h"
|
||||
#include "openair2/GNB_APP/L1_nr_paramdef.h"
|
||||
#include "openair2/GNB_APP/gnb_paramdef.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/if_defs.h"
|
||||
#include "radio/ETHERNET/if_defs.h"
|
||||
#include <stdio.h>
|
||||
#include "openair2/GNB_APP/MACRLC_nr_paramdef.h"
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
#include "openair2/PHY_INTERFACE/phy_stub_UE.h"
|
||||
#include "openair2/ENB_APP/L1_paramdef.h"
|
||||
#include "openair2/ENB_APP/enb_paramdef.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/if_defs.h"
|
||||
#include "radio/ETHERNET/if_defs.h"
|
||||
#include "common/config/config_load_configmodule.h"
|
||||
#include "common/config/config_userapi.h"
|
||||
#include <arpa/inet.h>
|
||||
|
||||
@@ -49,18 +49,11 @@
|
||||
|
||||
extern int asn1_xer_print;
|
||||
|
||||
#if defined(ENB_MODE)
|
||||
# include "common/utils/LOG/log.h"
|
||||
# define X2AP_INFO(x, args...) LOG_I(X2AP, x, ##args)
|
||||
# define X2AP_ERROR(x, args...) LOG_E(X2AP, x, ##args)
|
||||
# define X2AP_WARN(x, args...) LOG_W(X2AP, x, ##args)
|
||||
# define X2AP_DEBUG(x, args...) LOG_D(X2AP, x, ##args)
|
||||
#else
|
||||
# define X2AP_INFO(x, args...) do { fprintf(stdout, "[X2AP][I]"x, ##args); } while(0)
|
||||
# define X2AP_ERROR(x, args...) do { fprintf(stdout, "[X2AP][E]"x, ##args); } while(0)
|
||||
# define X2AP_WARN(x, args...) do { fprintf(stdout, "[X2AP][W]"x, ##args); } while(0)
|
||||
# define X2AP_DEBUG(x, args...) do { fprintf(stdout, "[X2AP][D]"x, ##args); } while(0)
|
||||
#endif
|
||||
#include "common/utils/LOG/log.h"
|
||||
#define X2AP_INFO(x, args...) LOG_I(X2AP, x, ##args)
|
||||
#define X2AP_ERROR(x, args...) LOG_E(X2AP, x, ##args)
|
||||
#define X2AP_WARN(x, args...) LOG_W(X2AP, x, ##args)
|
||||
#define X2AP_DEBUG(x, args...) LOG_D(X2AP, x, ##args)
|
||||
|
||||
#define X2AP_FIND_PROTOCOLIE_BY_ID(IE_TYPE, ie, container, IE_ID, mandatory) \
|
||||
do {\
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
|
||||
#include "sctp_eNB_defs.h"
|
||||
|
||||
#include "m3ap_default_values.h"
|
||||
#include "m3ap_ids.h" //looks X2AP specific for HO
|
||||
#include "m3ap_timers.h"
|
||||
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
|
||||
#include "sctp_eNB_defs.h"
|
||||
|
||||
#include "m3ap_default_values.h"
|
||||
#include "m3ap_ids.h" //looks X2AP specific for HO
|
||||
#include "m3ap_timers.h"
|
||||
|
||||
|
||||
@@ -50,19 +50,12 @@
|
||||
|
||||
extern int asn1_xer_print;
|
||||
|
||||
#if defined(ENB_MODE)
|
||||
# include "common/utils/LOG/log.h"
|
||||
# include "m3ap_default_values.h"
|
||||
# define M3AP_INFO(x, args...) LOG_I(M3AP, x, ##args)
|
||||
# define M3AP_ERROR(x, args...) LOG_E(M3AP, x, ##args)
|
||||
# define M3AP_WARN(x, args...) LOG_W(M3AP, x, ##args)
|
||||
# define M3AP_DEBUG(x, args...) LOG_D(M3AP, x, ##args)
|
||||
#else
|
||||
# define M3AP_INFO(x, args...) do { fprintf(stdout, "[M3AP][I]"x, ##args); } while(0)
|
||||
# define M3AP_ERROR(x, args...) do { fprintf(stdout, "[M3AP][E]"x, ##args); } while(0)
|
||||
# define M3AP_WARN(x, args...) do { fprintf(stdout, "[M3AP][W]"x, ##args); } while(0)
|
||||
# define M3AP_DEBUG(x, args...) do { fprintf(stdout, "[M3AP][D]"x, ##args); } while(0)
|
||||
#endif
|
||||
#include "common/utils/LOG/log.h"
|
||||
#include "m3ap_default_values.h"
|
||||
#define M3AP_INFO(x, args...) LOG_I(M3AP, x, ##args)
|
||||
#define M3AP_ERROR(x, args...) LOG_E(M3AP, x, ##args)
|
||||
#define M3AP_WARN(x, args...) LOG_W(M3AP, x, ##args)
|
||||
#define M3AP_DEBUG(x, args...) LOG_D(M3AP, x, ##args)
|
||||
|
||||
#define M3AP_FIND_PROTOCOLIE_BY_ID(IE_TYPE, ie, container, IE_ID, mandatory) \
|
||||
do {\
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
#include "LAYER2/MAC/mac_proto.h"
|
||||
#include "PHY/phy_extern.h"
|
||||
#include "PHY/INIT/phy_init.h"
|
||||
#include "radio/ETHERNET/USERSPACE/LIB/ethernet_lib.h"
|
||||
#include "radio/ETHERNET/ethernet_lib.h"
|
||||
#include "nfapi_vnf.h"
|
||||
#include "nfapi_pnf.h"
|
||||
|
||||
|
||||
@@ -96,7 +96,6 @@
|
||||
extern int asn_debug;
|
||||
extern int asn1_xer_print;
|
||||
|
||||
#if defined(ENB_MODE)
|
||||
# include "common/utils/LOG/log.h"
|
||||
# include "ngap_gNB_default_values.h"
|
||||
# define NGAP_ERROR(x, args...) LOG_E(NGAP, x, ##args)
|
||||
@@ -104,14 +103,6 @@ extern int asn1_xer_print;
|
||||
# define NGAP_TRAF(x, args...) LOG_I(NGAP, x, ##args)
|
||||
# define NGAP_INFO(x, args...) LOG_I(NGAP, x, ##args)
|
||||
# define NGAP_DEBUG(x, args...) LOG_I(NGAP, x, ##args)
|
||||
#else
|
||||
# include "amf_default_values.h"
|
||||
# define NGAP_ERROR(x, args...) do { fprintf(stdout, "[NGAP][E]"x, ##args); } while(0)
|
||||
# define NGAP_WARN(x, args...) do { fprintf(stdout, "[NGAP][W]"x, ##args); } while(0)
|
||||
# define NGAP_TRAF(x, args...) do { fprintf(stdout, "[NGAP][T]"x, ##args); } while(0)
|
||||
# define NGAP_INFO(x, args...) do { fprintf(stdout, "[NGAP][I]"x, ##args); } while(0)
|
||||
# define NGAP_DEBUG(x, args...) do { fprintf(stdout, "[NGAP][D]"x, ##args); } while(0)
|
||||
#endif
|
||||
|
||||
#define NGAP_FIND_PROTOCOLIE_BY_ID(IE_TYPE, ie, container, IE_ID, mandatory) \
|
||||
do { \
|
||||
|
||||
@@ -52,21 +52,13 @@
|
||||
|
||||
extern int asn1_xer_print;
|
||||
|
||||
#if defined(ENB_MODE)
|
||||
# include "common/utils/LOG/log.h"
|
||||
# include "s1ap_eNB_default_values.h"
|
||||
# define S1AP_ERROR(x, args...) LOG_E(S1AP, x, ##args)
|
||||
# define S1AP_WARN(x, args...) LOG_W(S1AP, x, ##args)
|
||||
# define S1AP_TRAF(x, args...) LOG_I(S1AP, x, ##args)
|
||||
# define S1AP_INFO(x, args...) LOG_I(S1AP, x, ##args)
|
||||
# define S1AP_DEBUG(x, args...) LOG_I(S1AP, x, ##args)
|
||||
#else
|
||||
# define S1AP_ERROR(x, args...) do { fprintf(stdout, "[S1AP][E]"x, ##args); } while(0)
|
||||
# define S1AP_WARN(x, args...) do { fprintf(stdout, "[S1AP][W]"x, ##args); } while(0)
|
||||
# define S1AP_TRAF(x, args...) do { fprintf(stdout, "[S1AP][T]"x, ##args); } while(0)
|
||||
# define S1AP_INFO(x, args...) do { fprintf(stdout, "[S1AP][I]"x, ##args); } while(0)
|
||||
# define S1AP_DEBUG(x, args...) do { fprintf(stdout, "[S1AP][D]"x, ##args); } while(0)
|
||||
#endif
|
||||
#include "common/utils/LOG/log.h"
|
||||
#include "s1ap_eNB_default_values.h"
|
||||
#define S1AP_ERROR(x, args...) LOG_E(S1AP, x, ##args)
|
||||
#define S1AP_WARN(x, args...) LOG_W(S1AP, x, ##args)
|
||||
#define S1AP_TRAF(x, args...) LOG_I(S1AP, x, ##args)
|
||||
#define S1AP_INFO(x, args...) LOG_I(S1AP, x, ##args)
|
||||
#define S1AP_DEBUG(x, args...) LOG_I(S1AP, x, ##args)
|
||||
|
||||
|
||||
#define S1AP_FIND_PROTOCOLIE_BY_ID(IE_TYPE, ie, container, IE_ID, mandatory) \
|
||||
|
||||
@@ -34,16 +34,10 @@
|
||||
#include <stdint.h>
|
||||
#include <sys/socket.h>
|
||||
|
||||
#if defined(ENB_MODE)
|
||||
# include "common/utils/LOG/log.h"
|
||||
# define SCTP_ERROR(x, args...) LOG_E(SCTP, x, ##args)
|
||||
# define SCTP_DEBUG(x, args...) LOG_D(SCTP, x, ##args)
|
||||
# define SCTP_WARN(x, args...) LOG_W(SCTP, x, ##args)
|
||||
#else
|
||||
# define SCTP_ERROR(x, args...) do { fprintf(stderr, "[SCTP][E]"x, ##args); } while(0)
|
||||
# define SCTP_DEBUG(x, args...) do { fprintf(stdout, "[SCTP][D]"x, ##args); } while(0)
|
||||
# define SCTP_WARN(x, args...) do { fprintf(stdout, "[SCTP][W]"x, ##args); } while(0)
|
||||
#endif
|
||||
#include "common/utils/LOG/log.h"
|
||||
#define SCTP_ERROR(x, args...) LOG_E(SCTP, x, ##args)
|
||||
#define SCTP_DEBUG(x, args...) LOG_D(SCTP, x, ##args)
|
||||
#define SCTP_WARN(x, args...) LOG_W(SCTP, x, ##args)
|
||||
|
||||
int sctp_set_init_opt(int sd, uint16_t instreams, uint16_t outstreams,
|
||||
uint16_t max_attempts, uint16_t init_timeout);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
find_library(ori NAMES "libori.so" REQUIRED)
|
||||
if(NOT ori)
|
||||
message(FATAL_ERROR "cannot locate libori.so, required to build aw2sori_transpro")
|
||||
endif()
|
||||
# force that oai_eth_transpro is built as well, as aw2sori_transpro requires it
|
||||
if(NOT OAI_ETHERNET)
|
||||
message(FATAL_ERROR "aw2sori_transpro requires oai_eth_transpro, please enable OAI_ETHERNET (-DOAI_ETHERNET=ON for cmake, or ./build_oai -t Ethernet)")
|
||||
endif()
|
||||
|
||||
add_library(aw2sori_transpro MODULE oaiori.c)
|
||||
target_compile_options(aw2sori_transpro PRIVATE -shared -fPIC -msse4 -g -ggdb -DLITE_COMPILATION)
|
||||
target_link_libraries(aw2sori_transpro PRIVATE ori oai_eth_transpro)
|
||||
set_target_properties(aw2sori_transpro PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
add_custom_command(TARGET aw2sori_transpro POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink libaw2sori_transpro.so libthirdparty_transpro.so
|
||||
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
@@ -0,0 +1,7 @@
|
||||
pkg_check_modules(bladeRF REQUIRED libbladeRF)
|
||||
add_library(oai_bladerfdevif MODULE bladerf_lib.c)
|
||||
target_link_libraries(oai_bladerfdevif PRIVATE bladeRF)
|
||||
set_target_properties(oai_bladerfdevif PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
add_custom_command(TARGET oai_bladerfdevif POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink liboai_bladerfdevif.so liboai_device.so
|
||||
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
@@ -0,0 +1,34 @@
|
||||
add_boolean_option(OAI_AW2SORI OFF "Activate OAI's AW2S driver" OFF)
|
||||
if(OAI_AW2SORI)
|
||||
add_subdirectory(AW2SORI)
|
||||
endif()
|
||||
|
||||
add_boolean_option(OAI_ETHERNET OFF "Activate OAI's Ethernet transport driver" OFF)
|
||||
if(OAI_ETHERNET)
|
||||
add_subdirectory(ETHERNET)
|
||||
endif()
|
||||
|
||||
add_boolean_option(OAI_BLADERF OFF "Activate OAI's BladeRF driver" OFF)
|
||||
if(OAI_BLADERF)
|
||||
add_subdirectory(BLADERF)
|
||||
endif()
|
||||
|
||||
add_boolean_option(OAI_IRIS OFF "Activate OAI's IRIS/SoapySDR driver" OFF)
|
||||
if(OAI_IRIS)
|
||||
add_subdirectory(IRIS)
|
||||
endif()
|
||||
|
||||
add_boolean_option(OAI_LMSSDR OFF "Activate OAI's LimeSDR driver" OFF)
|
||||
if(OAI_LMSSDR)
|
||||
add_subdirectory(LMSSDR)
|
||||
endif()
|
||||
|
||||
add_boolean_option(OAI_SIMU ON "Activate OAI's rfsimulator driver" OFF)
|
||||
if(OAI_SIMU)
|
||||
add_subdirectory(rfsimulator)
|
||||
endif()
|
||||
|
||||
add_boolean_option(OAI_USRP OFF "Activate OAI's USRP driver" OFF)
|
||||
if(OAI_USRP)
|
||||
add_subdirectory(USRP)
|
||||
endif()
|
||||
@@ -0,0 +1,12 @@
|
||||
add_library(oai_eth_transpro MODULE
|
||||
ethernet_lib.c
|
||||
eth_udp.c
|
||||
eth_raw.c
|
||||
)
|
||||
target_include_directories(oai_eth_transpro PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
set_target_properties(oai_eth_transpro PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
add_custom_command(TARGET oai_eth_transpro POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink liboai_eth_transpro.so liboai_transpro.so
|
||||
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
|
||||
add_subdirectory(benetel)
|
||||
@@ -0,0 +1,20 @@
|
||||
pkg_check_modules(libdpdk REQUIRED libdpdk=20.05.0)
|
||||
|
||||
add_library(benetel_4g MODULE
|
||||
benetel.c
|
||||
shared_buffers.c
|
||||
low.c
|
||||
low_dpdk.c
|
||||
dpdk_driver.c
|
||||
)
|
||||
|
||||
target_compile_definitions(benetel_4g PROPERTIES COMPILE_FLAGS "-fvisibility=hidden -I$ENV{RTE_SDK}/$ENV{RTE_TARGET}/include")
|
||||
|
||||
SET(DPDK_LIBS "-Wl,-rpath,$ENV{RTE_SDK}/$ENV{RTE_TARGET}/lib -Wl,--whole-archive -L$ENV{RTE_SDK}/$ENV{RTE_TARGET}/lib -ldpdk -Wl,--no-whole-archive")
|
||||
target_include_directories(benetel_4g PRIVATE ${libdpdk_INCLUDE_DIRS})
|
||||
target_link_libraries(benetel_4g PRIVATE ${libdpdk_LIBRARIES})
|
||||
target_link_libraries(benetel_4g PRIVATE pthread dl rt m numa)
|
||||
set_target_properties(benetel_4g PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
add_custom_command(TARGET benetel_4g POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink libbenetel_4g.so liboai_transpro.so
|
||||
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
@@ -0,0 +1,19 @@
|
||||
pkg_check_modules(libdpdk REQUIRED libdpdk=20.05.0)
|
||||
|
||||
add_library(benetel_5g MODULE
|
||||
benetel.c
|
||||
shared_buffers.c
|
||||
low.c
|
||||
low_dpdk.c
|
||||
dpdk_driver.c
|
||||
)
|
||||
|
||||
SET(DPDK_LIBS "-Wl,-rpath,$ENV{RTE_SDK}/$ENV{RTE_TARGET}/lib -Wl,--whole-archive -L$ENV{RTE_SDK}/$ENV{RTE_TARGET}/lib -ldpdk -Wl,--no-whole-archive")
|
||||
target_include_directories(benetel_5g PRIVATE ${libdpdk_INCLUDE_DIRS})
|
||||
target_link_libraries(benetel_5g PRIVATE ${libdpdk_LIBRARIES})
|
||||
target_link_libraries(benetel_5g PRIVATE pthread dl rt m numa)
|
||||
set_target_properties(benetel_5g PROPERTIES COMPILE_FLAGS "-fvisibility=hidden -I$ENV{RTE_SDK}/$ENV{RTE_TARGET}/include")
|
||||
set_target_properties(benetel_5g PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
add_custom_command(TARGET benetel_5g POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink libbenetel_5g.so liboai_transpro.so
|
||||
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
@@ -0,0 +1,9 @@
|
||||
add_boolean_option(OAI_BENETEL4G OFF "Activate OAI's Benetel 4G radio driver" OFF)
|
||||
if(OAI_BENETEL4G)
|
||||
add_subdirectory(4g)
|
||||
endif()
|
||||
|
||||
add_boolean_option(OAI_BENETEL5G OFF "Activate OAI's Benetel 5G radio driver" OFF)
|
||||
if(OAI_BENETEL5G)
|
||||
add_subdirectory(5g)
|
||||
endif()
|
||||
@@ -19,7 +19,7 @@
|
||||
* contact@openairinterface.org
|
||||
*/
|
||||
|
||||
/*! \file radio/ETHERNET/USERSPACE/LIB/if_defs.h
|
||||
/*! \file radio/ETHERNET/if_defs.h
|
||||
* \brief
|
||||
* \author S. Sandeep Kumar, Raymond Knopp
|
||||
* \date 2016
|
||||
@@ -0,0 +1,8 @@
|
||||
find_package(SoapySDR REQUIRED)
|
||||
|
||||
add_library(oai_irisdevif MODULE iris_lib.cpp)
|
||||
target_link_libraries(oai_irisdevif PRIVATE SoapySDR)
|
||||
set_target_properties(oai_irisdevif PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
add_custom_command(TARGET oai_irisdevif POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink liboai_irisdevif.so liboai_device.so
|
||||
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
@@ -0,0 +1,8 @@
|
||||
find_package(LimeSuite REQUIRED)
|
||||
|
||||
add_library(oai_lmssdrdevif MODULE lms_lib.cpp)
|
||||
target_link_libraries(oai_lmssdrdevif LimeSuite )
|
||||
set_target_properties(oai_lmssdrdevif PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
add_custom_command(TARGET oai_lmssdrdevif POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink liboai_lmssdrdevif.so liboai_device.so
|
||||
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
@@ -0,0 +1,10 @@
|
||||
#find_package(Boost REQUIRED)
|
||||
find_package(UHD REQUIRED)
|
||||
|
||||
add_library(oai_usrpdevif MODULE usrp_lib.cpp)
|
||||
#target_include_directories(oai_usrpdevif PRIVATE Boost::boost)
|
||||
target_link_libraries(oai_usrpdevif uhd)
|
||||
set_target_properties(oai_usrpdevif PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
add_custom_command(TARGET oai_usrpdevif POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink liboai_usrpdevif.so liboai_device.so
|
||||
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
@@ -0,0 +1,11 @@
|
||||
add_library(rfsimulator MODULE
|
||||
simulator.c
|
||||
apply_channelmod.c
|
||||
../../openair1/PHY/TOOLS/signal_energy.c
|
||||
)
|
||||
target_link_libraries(rfsimulator PRIVATE SIMU)
|
||||
target_link_libraries(rfsimulator PRIVATE asn1_nr_rrc asn1_lte_rrc)
|
||||
set_target_properties(rfsimulator PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
|
||||
|
||||
add_executable(replay_node stored_node.c)
|
||||
target_link_libraries (replay_node minimal_lib)
|
||||
@@ -1,59 +0,0 @@
|
||||
CC = gcc
|
||||
MPICC = gcc #mpicc
|
||||
RM_F_V = rm -f -v
|
||||
PWD = $(shell pwd)
|
||||
export CC
|
||||
export MPICC
|
||||
export RM_F_V
|
||||
export PWD
|
||||
|
||||
OBJS_DIR := $(PWD)/objs
|
||||
|
||||
SVN_REV := $(shell svnversion -n .)
|
||||
DATE_REV := $(shell date '+%F %T')
|
||||
|
||||
NUM_CORES:=$(shell cat /proc/cpuinfo | grep processor | wc -l)
|
||||
|
||||
OPENSSL_FOUND := $(shell if pkg-config --exists openssl; then echo "1" ; else echo "0"; fi)
|
||||
ifeq ($(OPENSSL_FOUND), 1)
|
||||
OPENSSL_LIBS := $(shell pkg-config --libs openssl)
|
||||
#else
|
||||
#@echo "package openssl not installed"
|
||||
endif
|
||||
|
||||
PGM_FOUND := $(shell if pkg-config --exists openpgm-5.1; then echo "1" ; else echo "0"; fi)
|
||||
ifeq ($(PGM_FOUND), 1)
|
||||
PGM_CFLAGS := $(shell pkg-config --cflags openpgm-5.1)
|
||||
PGM_LIBS := $(shell pkg-config --libs openpgm-5.1)
|
||||
#else
|
||||
#@echo "package pgm not installed"
|
||||
endif
|
||||
|
||||
LIBXML2_FOUND := $(shell if pkg-config --exists libxml-2.0; then echo "1" ; else echo "0"; fi)
|
||||
ifeq ($(LIBXML2_FOUND), 1)
|
||||
LIBXML2_CFLAGS := $(shell pkg-config --cflags libxml-2.0)
|
||||
LIBXML2_LIBS := $(shell pkg-config --libs libxml-2.0)
|
||||
#else
|
||||
#@echo "package libxml2 not installed"
|
||||
endif
|
||||
|
||||
XPM_FOUND := $(shell if pkg-config --exists xpm; then echo "1" ; else echo "0"; fi)
|
||||
ifeq ($(XPM_FOUND), 1)
|
||||
XPM_LIBS := $(shell pkg-config --libs xpm)
|
||||
#else
|
||||
#@echo "package xmp not installed"
|
||||
endif
|
||||
|
||||
LIBBLAS_FOUND := $(shell if [ -f /usr/include/cblas.h ]; then echo "1"; else echo "0"; fi)
|
||||
ifeq ($(LIBBLAS_FOUND), 1)
|
||||
LIBBLAS_LIBS := -lblas
|
||||
else
|
||||
$(error "libblas not found, please install it")
|
||||
endif
|
||||
|
||||
#Export common libs
|
||||
LIBS = \
|
||||
-lm \
|
||||
$(LIBBLAS_LIBS) \
|
||||
$(LIBXML2_LIBS) \
|
||||
$(XPM_LIBS)
|
||||
Reference in New Issue
Block a user