Commit 044be0d1 authored by Marwan Hammouda's avatar Marwan Hammouda

removing dependency on Qt packages

parent 938f259b
......@@ -2484,8 +2484,23 @@ set (SIMUSRC
##########################
add_library(SIMU SHARED ${SIMUSRC} )
# Find the QtWidgets library
find_package(Qt5 COMPONENTS Widgets Charts REQUIRED)
# Qt-based scope
set(QTSCOPE_SOURCE_NR
${OPENAIR1_DIR}/PHY/TOOLS/nr_phy_qt_scope.cpp
)
find_package(Qt5 COMPONENTS Widgets Charts)
if (Qt5_FOUND)
message ("Qt5 Packages found.")
# Creates rules for calling the Meta-Object Compiler (moc) on the given source files
qt5_wrap_cpp(QTSCOPE_SOURCE_NR ${OPENAIR1_DIR}/PHY/TOOLS/nr_phy_qt_scope.h)
add_library(nrqtscope MODULE ${QTSCOPE_SOURCE_NR})
# Use the Widgets module from Qt5.
target_link_libraries(nrqtscope Qt5::Widgets Qt5::Charts)
else (Qt5_FOUND)
message ("WARNING: Qt5 Packages NOT found, so qt scope can NOT be displayed.")
endif ()
add_library(SIMU_ETH
${OPENAIR1_DIR}/SIMULATION/ETH_TRANSPORT/netlink_init.c
......@@ -2525,11 +2540,6 @@ set(XFORMSINTERFACE_SOURCE
)
set(XFORMS_LIBRARIES "forms")
set(QTSCOPE_SOURCE_NR
${OPENAIR1_DIR}/PHY/TOOLS/nr_phy_qt_scope.cpp
)
add_library(enbscope MODULE ${XFORMS_SOURCE} ${XFORMS_SOURCE_SOFTMODEM} ${XFORMS_ENB_SOURCE})
add_library(uescope MODULE ${XFORMS_SOURCE} ${XFORMS_SOURCE_SOFTMODEM} ${XFORMS_UE_SOURCE})
target_link_libraries(enbscope ${XFORMS_LIBRARIES})
......@@ -2538,13 +2548,6 @@ target_link_libraries(uescope ${XFORMS_LIBRARIES})
add_library(nrscope MODULE ${XFORMS_SOURCE_NR})
target_link_libraries(nrscope ${XFORMS_LIBRARIES})
# Creates rules for calling the Meta-Object Compiler (moc) on the given source files
qt5_wrap_cpp(QTSCOPE_SOURCE_NR ${OPENAIR1_DIR}/PHY/TOOLS/nr_phy_qt_scope.h)
add_library(nrqtscope MODULE ${QTSCOPE_SOURCE_NR})
# Use the Widgets module from Qt5.
target_link_libraries(nrqtscope Qt5::Widgets Qt5::Charts)
add_library(rfsimulator MODULE
${OPENAIR_DIR}/sdr/rfsimulator/simulator.c
${OPENAIR_DIR}/sdr/rfsimulator/apply_channelmod.c
......
......@@ -754,9 +754,22 @@ function main() {
######################
if [ ! -z "$BUILD_OPTLIB" ] ; then
for oklib in $BUILD_OPTLIB ; do
if [ "$oklib" != "nrqtscope" ]; then
compilations \
$BUILD_DIR $oklib \
lib${oklib}.so $dbin/lib${oklib}.so
fi
if [ "$oklib" = "nrqtscope" ]; then
HEAD_PATH="$(find /usr/ -iname qwidget.h)"
if [ "$HEAD_PATH" != "" ]; then
compilations \
$BUILD_DIR $oklib \
lib${oklib}.so $dbin/lib${oklib}.so
else
echo_warning "qt scope could not compile; make sure to install the Qt packages!"
fi
fi
done
fi
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment