diff options
author | Aric Belsito <lluixhi@gmail.com> | 2017-09-08 13:43:38 -0700 |
---|---|---|
committer | Aric Belsito <lluixhi@gmail.com> | 2017-09-10 11:54:23 -0700 |
commit | cbe57bef0454595714224b1d7aea0da5582af63e (patch) | |
tree | b82c46c1c76ed804b2fa0ab430d85ca0de83fe70 | |
parent | 8a2a079b6da03d636502ff0b4bc4a2f3aee0c3ea (diff) | |
download | portable-cbe57bef0454595714224b1d7aea0da5582af63e.tar.gz portable-cbe57bef0454595714224b1d7aea0da5582af63e.tar.bz2 portable-cbe57bef0454595714224b1d7aea0da5582af63e.zip |
Some CMake Fixes.
pqueue.h was getting installed when it shouldn't.
pkgconfig files were not getting installed or generated.
-rw-r--r-- | CMakeLists.txt | 17 | ||||
-rw-r--r-- | include/CMakeLists.txt | 1 |
2 files changed, 18 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index b897a53..9814356 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
@@ -324,6 +324,23 @@ if(NOT MSVC OR ENABLE_VSTEST) | |||
324 | add_subdirectory(tests) | 324 | add_subdirectory(tests) |
325 | endif() | 325 | endif() |
326 | 326 | ||
327 | if(NOT MSVC) | ||
328 | # Create pkgconfig files. | ||
329 | set(prefix ${CMAKE_INSTALL_PREFIX}) | ||
330 | set(exec_prefix \${prefix}) | ||
331 | set(libdir \${exec_prefix}/${CMAKE_INSTALL_LIBDIR}) | ||
332 | set(includedir \${prefix}/include) | ||
333 | file(STRINGS "VERSION" VERSION LIMIT_COUNT 1) | ||
334 | file(GLOB OPENSSL_PKGCONFIGS "*.pc.in") | ||
335 | foreach(file ${OPENSSL_PKGCONFIGS}) | ||
336 | get_filename_component(filename ${file} NAME) | ||
337 | string(REPLACE ".in" "" new_file "${filename}") | ||
338 | configure_file(${filename} pkgconfig/${new_file} @ONLY) | ||
339 | endforeach() | ||
340 | install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/pkgconfig | ||
341 | DESTINATION ${CMAKE_INSTALL_LIBDIR}) | ||
342 | endif() | ||
343 | |||
327 | configure_file( | 344 | configure_file( |
328 | "${CMAKE_CURRENT_SOURCE_DIR}/cmake_uninstall.cmake.in" | 345 | "${CMAKE_CURRENT_SOURCE_DIR}/cmake_uninstall.cmake.in" |
329 | "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake" | 346 | "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake" |
diff --git a/include/CMakeLists.txt b/include/CMakeLists.txt index b730954..1d1a159 100644 --- a/include/CMakeLists.txt +++ b/include/CMakeLists.txt | |||
@@ -3,5 +3,6 @@ if(ENABLE_LIBRESSL_INSTALL) | |||
3 | DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} | 3 | DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} |
4 | PATTERN "CMakeLists.txt" EXCLUDE | 4 | PATTERN "CMakeLists.txt" EXCLUDE |
5 | PATTERN "compat" EXCLUDE | 5 | PATTERN "compat" EXCLUDE |
6 | PATTERN "pqueue.h" EXCLUDE | ||
6 | PATTERN "Makefile*" EXCLUDE) | 7 | PATTERN "Makefile*" EXCLUDE) |
7 | endif(ENABLE_LIBRESSL_INSTALL) | 8 | endif(ENABLE_LIBRESSL_INSTALL) |