cmake: set rpath after searching for GNU Radio
This commit is contained in:
+20
-20
@@ -69,26 +69,6 @@ if(NOT Boost_FOUND)
|
|||||||
message(FATAL_ERROR "Boost required to compile foo")
|
message(FATAL_ERROR "Boost required to compile foo")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
########################################################################
|
|
||||||
# On Apple only, set install name and use rpath correctly, if not already set
|
|
||||||
########################################################################
|
|
||||||
if(APPLE)
|
|
||||||
if(NOT CMAKE_INSTALL_NAME_DIR)
|
|
||||||
set(CMAKE_INSTALL_NAME_DIR
|
|
||||||
${CMAKE_INSTALL_PREFIX}/${GR_LIBRARY_DIR} CACHE
|
|
||||||
PATH "Library Install Name Destination Directory" FORCE)
|
|
||||||
endif(NOT CMAKE_INSTALL_NAME_DIR)
|
|
||||||
if(NOT CMAKE_INSTALL_RPATH)
|
|
||||||
set(cmakE_INSTALL_RPATH
|
|
||||||
${CMAKE_INSTALL_PREFIX}/${GR_LIBRARY_DIR} CACHE
|
|
||||||
PATH "Library Install RPath" FORCE)
|
|
||||||
endif(NOT CMAKE_INSTALL_RPATH)
|
|
||||||
if(NOT CMAKE_BUILD_WITH_INSTALL_RPATH)
|
|
||||||
set(CMAKE_BUILD_WITH_INSTALL_RPATH ON CACHE
|
|
||||||
BOOL "Do Build Using Library Install RPath" FORCE)
|
|
||||||
endif(NOT CMAKE_BUILD_WITH_INSTALL_RPATH)
|
|
||||||
endif(APPLE)
|
|
||||||
|
|
||||||
########################################################################
|
########################################################################
|
||||||
# Install directories
|
# Install directories
|
||||||
########################################################################
|
########################################################################
|
||||||
@@ -128,6 +108,26 @@ if(NOT CPPUNIT_FOUND)
|
|||||||
message(FATAL_ERROR "CppUnit required to compile foo")
|
message(FATAL_ERROR "CppUnit required to compile foo")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
########################################################################
|
||||||
|
# On Apple only, set install name and use rpath correctly, if not already set
|
||||||
|
########################################################################
|
||||||
|
if(APPLE)
|
||||||
|
if(NOT CMAKE_INSTALL_NAME_DIR)
|
||||||
|
set(CMAKE_INSTALL_NAME_DIR
|
||||||
|
${CMAKE_INSTALL_PREFIX}/${GR_LIBRARY_DIR} CACHE
|
||||||
|
PATH "Library Install Name Destination Directory" FORCE)
|
||||||
|
endif(NOT CMAKE_INSTALL_NAME_DIR)
|
||||||
|
if(NOT CMAKE_INSTALL_RPATH)
|
||||||
|
set(cmakE_INSTALL_RPATH
|
||||||
|
${CMAKE_INSTALL_PREFIX}/${GR_LIBRARY_DIR} CACHE
|
||||||
|
PATH "Library Install RPath" FORCE)
|
||||||
|
endif(NOT CMAKE_INSTALL_RPATH)
|
||||||
|
if(NOT CMAKE_BUILD_WITH_INSTALL_RPATH)
|
||||||
|
set(CMAKE_BUILD_WITH_INSTALL_RPATH ON CACHE
|
||||||
|
BOOL "Do Build Using Library Install RPath" FORCE)
|
||||||
|
endif(NOT CMAKE_BUILD_WITH_INSTALL_RPATH)
|
||||||
|
endif(APPLE)
|
||||||
|
|
||||||
########################################################################
|
########################################################################
|
||||||
# Setup the include and linker paths
|
# Setup the include and linker paths
|
||||||
########################################################################
|
########################################################################
|
||||||
|
|||||||
Reference in New Issue
Block a user