[libpng] Fix android build (#11280)

This commit is contained in:
huangqinjin 2020-05-14 01:25:33 +08:00 committed by GitHub
parent 6fd7e9c712
commit 5970385596
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1 deletions

View File

@ -1,5 +1,5 @@
Source: libpng
Version: 1.6.37-8
Version: 1.6.37-9
Build-Depends: zlib
Homepage: https://github.com/glennrp/libpng
Description: libpng is a library implementing an interface for reading and writing PNG (Portable Network Graphics) format files.

View File

@ -53,12 +53,18 @@ if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL iOS)
set(LIBPNG_HARDWARE_OPTIMIZATIONS_OPTION "-DPNG_HARDWARE_OPTIMIZATIONS=OFF")
endif()
set(LD_VERSION_SCRIPT_OPTION )
if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL Android)
set(LD_VERSION_SCRIPT_OPTION "-Dld-version-script=OFF")
endif()
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
OPTIONS
${LIBPNG_APNG_OPTION}
${LIBPNG_HARDWARE_OPTIMIZATIONS_OPTION}
${LD_VERSION_SCRIPT_OPTION}
-DPNG_ARM_NEON=on
-DPNG_STATIC=${PNG_STATIC_LIBS}
-DPNG_SHARED=${PNG_SHARED_LIBS}