From 4684facd5bf9d63b01c84008b13f568c976ef50f Mon Sep 17 00:00:00 2001 From: ismagom Date: Fri, 8 May 2015 16:54:50 +0200 Subject: [PATCH] Fixed headers not installing --- srsapps/CMakeLists.txt | 6 +++++- srsapps/common/CMakeLists.txt | 8 +++++++- srsapps/radio/CMakeLists.txt | 8 +++++++- srsapps/ue/mac/CMakeLists.txt | 10 ++++++++-- srsapps/ue/phy/CMakeLists.txt | 8 +++++++- 5 files changed, 34 insertions(+), 6 deletions(-) diff --git a/srsapps/CMakeLists.txt b/srsapps/CMakeLists.txt index d1cc391f3..f7786b57a 100644 --- a/srsapps/CMakeLists.txt +++ b/srsapps/CMakeLists.txt @@ -19,10 +19,14 @@ # and at http://www.gnu.org/licenses/. # +######################################################################## +# Install headers +######################################################################## + INCLUDE_DIRECTORIES(radio/include/) INCLUDE_DIRECTORIES(common/include/) add_subdirectory(radio) -add_subdirectory(ue) add_subdirectory(common) +add_subdirectory(ue) diff --git a/srsapps/common/CMakeLists.txt b/srsapps/common/CMakeLists.txt index a22a423c4..ad5344f2c 100644 --- a/srsapps/common/CMakeLists.txt +++ b/srsapps/common/CMakeLists.txt @@ -19,10 +19,16 @@ # and at http://www.gnu.org/licenses/. # +INSTALL(DIRECTORY include/ + DESTINATION "${INCLUDE_DIR}" + FILES_MATCHING PATTERN "*.h" + PATTERN ".svn" EXCLUDE +) + FILE(GLOB SOURCES "src/*.cc") ADD_LIBRARY(srsapps_common SHARED ${SOURCES}) INSTALL(TARGETS srsapps_common DESTINATION ${LIBRARY_DIR}) LIBLTE_SET_PIC(srsapps_common) -FILE(GLOB SOURCES "include/srsapps/common/*.h") +FILE(GLOB HEADERS_ALL "include/srsapps/common/*.h") ADD_CUSTOM_TARGET (add_srsapps_common_headers SOURCES ${HEADERS_ALL}) diff --git a/srsapps/radio/CMakeLists.txt b/srsapps/radio/CMakeLists.txt index f0ed75dc6..98a1ac11e 100644 --- a/srsapps/radio/CMakeLists.txt +++ b/srsapps/radio/CMakeLists.txt @@ -21,6 +21,12 @@ FIND_PACKAGE(UHD) +INSTALL(DIRECTORY include/ + DESTINATION "${INCLUDE_DIR}" + FILES_MATCHING PATTERN "*.h" + PATTERN ".svn" EXCLUDE +) + IF(UHD_FOUND) FILE(GLOB SOURCES "src/*.cc") ADD_LIBRARY(srsapps_radio SHARED ${SOURCES}) @@ -28,5 +34,5 @@ IF(UHD_FOUND) LIBLTE_SET_PIC(srsapps_radio) ENDIF(UHD_FOUND) -FILE(GLOB SOURCES "include/srsapps/radio/*.h") +FILE(GLOB HEADERS_ALL "include/srsapps/radio/*.h") ADD_CUSTOM_TARGET (add_srsapps_radio_headers SOURCES ${HEADERS_ALL}) diff --git a/srsapps/ue/mac/CMakeLists.txt b/srsapps/ue/mac/CMakeLists.txt index 899a09459..05595631f 100644 --- a/srsapps/ue/mac/CMakeLists.txt +++ b/srsapps/ue/mac/CMakeLists.txt @@ -19,11 +19,17 @@ # and at http://www.gnu.org/licenses/. # +INSTALL(DIRECTORY include/ + DESTINATION "${INCLUDE_DIR}" + FILES_MATCHING PATTERN "*.h" + PATTERN ".svn" EXCLUDE +) + FILE(GLOB SOURCES "src/*.cc") ADD_LIBRARY(srsapps_ue_mac SHARED ${SOURCES}) INSTALL(TARGETS srsapps_ue_mac DESTINATION ${LIBRARY_DIR}) LIBLTE_SET_PIC(srsapps_ue_mac) -FILE(GLOB SOURCES "include/*.h") -ADD_CUSTOM_TARGET (add_srsapps_ue_mac_headers SOURCES ${HEADERS_ALL}) +FILE(GLOB HEADERS_ALL "include/srsapps/ue/mac/*.h") +ADD_CUSTOM_TARGET (add_ue_mac_headers SOURCES ${HEADERS_ALL}) diff --git a/srsapps/ue/phy/CMakeLists.txt b/srsapps/ue/phy/CMakeLists.txt index 30a33f1fe..6226e84d1 100644 --- a/srsapps/ue/phy/CMakeLists.txt +++ b/srsapps/ue/phy/CMakeLists.txt @@ -19,13 +19,19 @@ # and at http://www.gnu.org/licenses/. # +INSTALL(DIRECTORY include/ + DESTINATION "${INCLUDE_DIR}" + FILES_MATCHING PATTERN "*.h" + PATTERN ".svn" EXCLUDE +) + FILE(GLOB SOURCES "src/*.cc") ADD_LIBRARY(srsapps_ue_phy SHARED ${SOURCES}) TARGET_LINK_LIBRARIES(srsapps_ue_phy srsapps_common) INSTALL(TARGETS srsapps_ue_phy DESTINATION ${LIBRARY_DIR}) LIBLTE_SET_PIC(srsapps_ue_phy) -FILE(GLOB SOURCES "include/srsapps/ue/phy/*.h") +FILE(GLOB HEADERS_ALL "include/srsapps/ue/phy/*.h") ADD_CUSTOM_TARGET (add_ue_phy_headers SOURCES ${HEADERS_ALL}) ADD_SUBDIRECTORY(test)