X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=CMakeLists.txt;h=cf887cf03abe8868d034ad6b8bd9efc61635dbbb;hb=68c1ab2191d9959fde0bd275a560f7c9cf6df485;hp=365d370cca0a418d6073bd141255862380b0bf8e;hpb=a41c6f5f26b3a44009f4aff3df3f83b9a79ace01;p=ric-plt%2Flib%2Frmr.git diff --git a/CMakeLists.txt b/CMakeLists.txt index 365d370..cf887cf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -21,10 +21,9 @@ project( rmr LANGUAGES C ) cmake_minimum_required( VERSION 3.5 ) - set( major_version "1" ) # should be automatically populated from git tag later, but until CI process sets a tag we use this set( minor_version "0" ) -set( patch_level "19" ) +set( patch_level "25" ) set( install_root "${CMAKE_INSTALL_PREFIX}" ) set( install_lib "lib" ) @@ -39,8 +38,11 @@ endif() # locations on all platforms. include( GNUInstallDirs ) -if( NOT BUILD_LIB ) - set( BUILD_LIB lib ) +# nano/nng install using LIBDIR as established by the gnu include; it varies from system +# to system, and we don't trust that it is always set, so we default to lib. +# +if( NOT CMAKE_INSTALL_LIBDIR ) + set( CMAKE_INSTALL_LIBDIR "lib" ) endif() # ---------------- extract some things from git ------------------------------ @@ -166,9 +168,9 @@ set( CMAKE_POSITION_INDEPENDENT_CODE ON ) set( CMAKE_CXX_FLAGS "-g -Wall " ) # Include modules -add_subdirectory( src/common ) -add_subdirectory( src/nanomsg ) -add_subdirectory( src/nng ) +add_subdirectory( src/rmr/common ) +add_subdirectory( src/rmr/nanomsg ) +add_subdirectory( src/rmr/nng ) add_subdirectory( doc ) # this will auto skip if {X}fm is not available @@ -249,12 +251,12 @@ install( TARGETS rmr_nng_shared;rmr_nng_static;rmr_shared;rmr_static EXPORT Libr if( need_ext ) message( "including nano and nng libraries in the deb" ) install( FILES - ${CMAKE_CURRENT_BINARY_DIR}/${BUILD_LIB}/libnanomsg${nano_so_suffix} - ${CMAKE_CURRENT_BINARY_DIR}/${BUILD_LIB}/libnanomsg${nano_so_suffix_m} - ${CMAKE_CURRENT_BINARY_DIR}/${BUILD_LIB}/libnanomsg${nano_so_suffix_mm} - ${CMAKE_CURRENT_BINARY_DIR}/${BUILD_LIB}/libnng${nng_so_suffix} - ${CMAKE_CURRENT_BINARY_DIR}/${BUILD_LIB}/libnng${nng_so_suffix_m} - ${CMAKE_CURRENT_BINARY_DIR}/${BUILD_LIB}/libnng${nng_so_suffix_mm} + ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libnanomsg${nano_so_suffix} + ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libnanomsg${nano_so_suffix_m} + ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libnanomsg${nano_so_suffix_mm} + ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libnng${nng_so_suffix} + ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libnng${nng_so_suffix_m} + ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libnng${nng_so_suffix_mm} DESTINATION ${install_lib} )