fixed the libpng build

This commit is contained in:
Jacker 2022-11-08 12:28:27 +02:00
parent 984873cb30
commit 3c0ae3a64a

View file

@ -985,6 +985,8 @@ if(BUNDLED_PNG AND BUILD_CLIENT)
set(binary_dir "${LIBS_BINARY_DIR}/libpng")
if(VSTUDIO)
set(PNG_BUNDLED_LIBRARIES optimized "${binary_dir}/Release/libpng16_static${CMAKE_STATIC_LIBRARY_SUFFIX}" debug "${binary_dir}/Debug/libpng16_staticd${CMAKE_STATIC_LIBRARY_SUFFIX}")
elseif(MSVC)
set(PNG_BUNDLED_LIBRARIES optimized "${binary_dir}/libpng16_static${CMAKE_STATIC_LIBRARY_SUFFIX}" debug "${binary_dir}/libpng16_staticd${CMAKE_STATIC_LIBRARY_SUFFIX}")
elseif(VS_BUILD)
set(PNG_BUNDLED_LIBRARIES "${binary_dir}/libpng${CMAKE_STATIC_LIBRARY_SUFFIX}")
else()
@ -1010,7 +1012,7 @@ if(BUNDLED_PNG AND BUILD_CLIENT)
BUILD_BYPRODUCTS ${_PNG_OUTPUT}
CMAKE_ARGS -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} -DCMAKE_CXX_FLAGS=${CMAKE_CXX_FLAGS}
-DCMAKE_CXX_FLAGS_DEBUG=${CMAKE_CXX_FLAGS_DEBUG} -DCMAKE_CXX_FLAGS_RELEASE=${CMAKE_CXX_FLAGS_RELEASE}
-DCMAKE_C_FLAGS=${CMAKE_C_FLAGS} -DPNG_SHARED=OFF -DPNG_STATIC=ON -DPNG_BUILD_ZLIB=ON -DZLIB_INCLUDE_DIR=${ZLIB_INCLUDE_DIR}
-DCMAKE_C_FLAGS=${CMAKE_C_FLAGS} -DPNG_SHARED=OFF -DPNG_STATIC=ON -DPNG_BUILD_ZLIB=ON -DZLIB_INCLUDE_DIRS=${ZLIB_INCLUDE_DIR}
-DPNG_TESTS=OFF -DPNG_FRAMEWORK=OFF -DPNG_DEBUG=OFF -DPNG_HARDWARE_OPTIMIZATIONS=${PNG_OPTIMIZATION}
-DCMAKE_OSX_DEPLOYMENT_TARGET="${CMAKE_OSX_DEPLOYMENT_TARGET}" -DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES_}
INSTALL_COMMAND ""