diff options
author | evpobr <evpobr@gmail.com> | 2019-05-29 16:17:53 +0500 |
---|---|---|
committer | Erik de Castro Lopo <erikd@mega-nerd.com> | 2020-04-05 19:31:40 +1000 |
commit | acadefddac6b6a3a67d7628432c4b1380fbc2044 (patch) | |
tree | da83389fb9c7986fdf4aad6b8319bd3282e7342f /src/libFLAC++/CMakeLists.txt | |
parent | 1d5299d67b4f4d8172b2fab702696bce1082b91a (diff) | |
download | flac-acadefddac6b6a3a67d7628432c4b1380fbc2044.tar.gz |
Add more CMake options
* BUILD_PROGRAMS
** INSTALL_MANPAGES
* INSTALL_PKGCONFIG_MODULES
* INSTALL_CMAKE_CONFIG_MODULE
Diffstat (limited to 'src/libFLAC++/CMakeLists.txt')
-rw-r--r-- | src/libFLAC++/CMakeLists.txt | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/src/libFLAC++/CMakeLists.txt b/src/libFLAC++/CMakeLists.txt index 04b721f3..a4849d74 100644 --- a/src/libFLAC++/CMakeLists.txt +++ b/src/libFLAC++/CMakeLists.txt @@ -1,9 +1,3 @@ -set(prefix "${CMAKE_INSTALL_PREFIX}") -set(exec_prefix "${CMAKE_INSTALL_PREFIX}") -set(libdir "${CMAKE_INSTALL_FULL_LIBDIR}") -set(includedir "${CMAKE_INSTALL_FULL_INCLUDEDIR}") -configure_file(flac++.pc.in flac++.pc @ONLY) - check_cxx_source_compiles(" #ifdef __STDC_NO_VLA__ syntax error; @@ -45,5 +39,13 @@ install(TARGETS FLAC++ EXPORT targets ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}/" LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}/" RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}/") -install(FILES "${CMAKE_CURRENT_BINARY_DIR}/flac++.pc" - DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig") + +if(INSTALL_PKGCONFIG_MODULES) + set(prefix "${CMAKE_INSTALL_PREFIX}") + set(exec_prefix "${CMAKE_INSTALL_PREFIX}") + set(libdir "${CMAKE_INSTALL_FULL_LIBDIR}") + set(includedir "${CMAKE_INSTALL_FULL_INCLUDEDIR}") + configure_file(flac++.pc.in flac++.pc @ONLY) + install(FILES "${CMAKE_CURRENT_BINARY_DIR}/flac++.pc" + DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/pkgconfig") +endif() |