From 7305ee92a27f55456c942aa7a9a05a244c9ebe8c Mon Sep 17 00:00:00 2001 From: Semphris Date: Fri, 15 Apr 2022 17:33:32 -0400 Subject: [PATCH] Added option to disable the installer --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6350ff5..e0c2e7c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -216,6 +216,9 @@ if(PHYSFS_BUILD_TEST) set(PHYSFS_INSTALL_TARGETS ${PHYSFS_INSTALL_TARGETS} ";test_physfs") endif() +option(PHYSFS_DISABLE_INSTALL "Disable installing PhysFS" OFF) +if(NOT PHYSFS_DISABLE_INSTALL) + install(TARGETS ${PHYSFS_INSTALL_TARGETS} EXPORT PhysFSExport RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} @@ -290,6 +293,8 @@ if(NOT MSVC) ) endif() +endif(NOT PHYSFS_DISABLE_INSTALL) + macro(message_bool_option _NAME _VALUE) if(${_VALUE}) message(STATUS " ${_NAME}: enabled")