From f2bd893241d575f89a7a375fec969b51f96808f4 Mon Sep 17 00:00:00 2001 From: TheBrokenRail Date: Fri, 22 Oct 2021 17:28:26 -0400 Subject: [PATCH] Fix Build (Finally) --- dependencies/libpng/CMakeLists.txt | 3 ++- dependencies/zlib/CMakeLists.txt | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/dependencies/libpng/CMakeLists.txt b/dependencies/libpng/CMakeLists.txt index 0ba4b3e9c..234db5e67 100644 --- a/dependencies/libpng/CMakeLists.txt +++ b/dependencies/libpng/CMakeLists.txt @@ -8,7 +8,6 @@ add_compile_options(-w) ## LibPNG # Download -set(SKIP_INSTALL_ALL TRUE) # Skip Default LibPNG Installation FetchContent_Declare( libpng GIT_REPOSITORY "https://github.com/glennrp/libpng.git" @@ -23,6 +22,8 @@ set(CMAKE_POLICY_DEFAULT_CMP0054 NEW) # Re-Enable New Behavior set_target_properties(png12 PROPERTIES LINK_FLAGS "-Wl,--version-script='${CMAKE_CURRENT_SOURCE_DIR}/libpng.vers'") # Use Symbol Versioning set_target_properties(png12 PROPERTIES DEBUG_POSTFIX "") # Fix LibPNG Suffix In Debug Mode +# Ensure Build +set_target_properties(png12 PROPERTIES EXCLUDE_FROM_ALL FALSE) # Install install(TARGETS png12 DESTINATION "${MCPI_LIB_DIR}") diff --git a/dependencies/zlib/CMakeLists.txt b/dependencies/zlib/CMakeLists.txt index f5fdf8421..09c0c3641 100644 --- a/dependencies/zlib/CMakeLists.txt +++ b/dependencies/zlib/CMakeLists.txt @@ -8,7 +8,6 @@ add_compile_options(-w) ## zlib # Download -set(SKIP_INSTALL_ALL TRUE) # Skip Default ZLib Installation FetchContent_Declare( zlib GIT_REPOSITORY "https://github.com/madler/zlib.git" @@ -18,6 +17,8 @@ FetchContent_Populate(zlib) include_directories("${zlib_SOURCE_DIR}" "${zlib_BINARY_DIR}") # Fix ZLib Build add_subdirectory("${zlib_SOURCE_DIR}" "${zlib_BINARY_DIR}" EXCLUDE_FROM_ALL) +# Ensure Build +set_target_properties(zlib PROPERTIES EXCLUDE_FROM_ALL FALSE) # Install install(TARGETS zlib DESTINATION "${MCPI_LIB_DIR}")