rtl-sdr: add support for lib64 (e.g. Fedora)

Another possibility is to use the GrPlatform.cmake module.

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
Signed-off-by: Steve Markgraf <steve@steve-m.de>
master
Jaroslav Škarvada 12 years ago committed by Steve Markgraf
parent 4a068f565b
commit a5dd532cbb
  1. 8
      CMakeLists.txt
  2. 4
      src/CMakeLists.txt

@ -33,6 +33,10 @@ set(CMAKE_BUILD_TYPE ${CMAKE_BUILD_TYPE} CACHE STRING "")
list(APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/Modules) list(APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/Modules)
if(NOT LIB_INSTALL_DIR)
set(LIB_INSTALL_DIR lib)
endif()
######################################################################## ########################################################################
# Compiler specific setup # Compiler specific setup
######################################################################## ########################################################################
@ -130,7 +134,7 @@ ENDIF(CMAKE_CROSSCOMPILING)
set(prefix ${CMAKE_INSTALL_PREFIX}) set(prefix ${CMAKE_INSTALL_PREFIX})
set(exec_prefix \${prefix}) set(exec_prefix \${prefix})
set(libdir \${exec_prefix}/lib) set(libdir \${exec_prefix}/${LIB_INSTALL_DIR})
set(includedir \${prefix}/include) set(includedir \${prefix}/include)
CONFIGURE_FILE( CONFIGURE_FILE(
@ -140,5 +144,5 @@ CONFIGURE_FILE(
INSTALL( INSTALL(
FILES ${CMAKE_CURRENT_BINARY_DIR}/librtlsdr.pc FILES ${CMAKE_CURRENT_BINARY_DIR}/librtlsdr.pc
DESTINATION lib/pkgconfig DESTINATION ${LIB_INSTALL_DIR}/pkgconfig
) )

@ -126,7 +126,7 @@ endif()
# Install built library files & utilities # Install built library files & utilities
######################################################################## ########################################################################
install(TARGETS ${INSTALL_TARGETS} install(TARGETS ${INSTALL_TARGETS}
LIBRARY DESTINATION lib${LIB_SUFFIX} # .so/.dylib file LIBRARY DESTINATION ${LIB_INSTALL_DIR} # .so/.dylib file
ARCHIVE DESTINATION lib${LIB_SUFFIX} # .lib file ARCHIVE DESTINATION ${LIB_INSTALL_DIR} # .lib file
RUNTIME DESTINATION bin # .dll file RUNTIME DESTINATION bin # .dll file
) )

Loading…
Cancel
Save