diff options
author | Josh Blum | 2012-11-11 12:46:34 -0800 |
---|---|---|
committer | Josh Blum | 2012-11-11 12:46:34 -0800 |
commit | 8f9fedb6846f7304ac4c5ed7ae3233a03b5359b7 (patch) | |
tree | 5164e1403e00f2cff2760a3f5edff939b3047aa9 | |
parent | f1e85b43b0d76ff2f0c6b4432e4c318f5562ba08 (diff) | |
download | sandhi-8f9fedb6846f7304ac4c5ed7ae3233a03b5359b7.tar.gz sandhi-8f9fedb6846f7304ac4c5ed7ae3233a03b5359b7.tar.bz2 sandhi-8f9fedb6846f7304ac4c5ed7ae3233a03b5359b7.zip |
created pc file pkg config library stuff
-rw-r--r-- | CMakeLists.txt | 1 | ||||
-rw-r--r-- | lib/CMakeLists.txt | 15 | ||||
-rw-r--r-- | lib/gras.pc.in | 15 |
3 files changed, 31 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index e5be56d..5674e5e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -5,6 +5,7 @@ cmake_minimum_required(VERSION 2.6) project(gras CXX C) enable_testing() +set(GRAS_VERSION "0.0.0") set(GRAS_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}) set(GRAS_BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR}) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 0657f28..3748830 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -60,9 +60,24 @@ list(APPEND GRAS_SOURCES ######################################################################## add_library(gras SHARED ${GRAS_SOURCES}) target_link_libraries(gras ${GRAS_LIBRARIES}) +set_target_properties(gras PROPERTIES VERSION ${GRAS_VERSION}) install(TARGETS gras LIBRARY DESTINATION lib${LIB_SUFFIX} COMPONENT ${GRAS_COMP_RUNTIME} # .so file ARCHIVE DESTINATION lib${LIB_SUFFIX} COMPONENT ${GRAS_COMP_DEVEL} # .lib file RUNTIME DESTINATION bin COMPONENT ${GRAS_COMP_RUNTIME} # .dll file ) + +######################################################################## +# Build pkg config file +######################################################################## +configure_file( + ${CMAKE_CURRENT_SOURCE_DIR}/gras.pc.in + ${CMAKE_CURRENT_BINARY_DIR}/gras.pc +@ONLY) + +install( + FILES ${CMAKE_CURRENT_BINARY_DIR}/gras.pc + DESTINATION lib${LIB_SUFFIX}/pkgconfig + COMPONENT ${GRAS_COMP_DEVEL} +) diff --git a/lib/gras.pc.in b/lib/gras.pc.in new file mode 100644 index 0000000..49fd99f --- /dev/null +++ b/lib/gras.pc.in @@ -0,0 +1,15 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=${prefix} +libdir=${exec_prefix}/lib@LIB_SUFFIX@ +includedir=${prefix}/include + +Name: GRAS +Description: GNU Radio Advanced Scheduler +URL: https://github.com/guruofquality/gras/wiki +Version: @GRAS_VERSION@ +Requires: +Requires.private: +Conflicts: +Cflags: -I${includedir} +Libs: -L${libdir} -lgras +Libs.private: |