diff options
author | Steve Robinson <ssrobins@gmail.com> | 2019-08-24 13:25:14 -0700 |
---|---|---|
committer | Cosmin Truta <ctruta@gmail.com> | 2020-05-17 19:50:18 -0400 |
commit | 5e8b45c436c1c1bef18b3a8e18b4f0b980e946fc (patch) | |
tree | 1bbf69a2e2d15cb04462f21dde2089ca3372d8a8 /CMakeLists.txt | |
parent | 6dd99ca9c85a59cc8848553177b84abea228f82f (diff) | |
download | libpng-5e8b45c436c1c1bef18b3a8e18b4f0b980e946fc.tar.gz |
cmake: Fix a build error on iOS
Avoid the awk-based configuration when cross-compiling from macOS
to iOS.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 874387ca6..c85aa74cf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14,6 +14,7 @@ # Revised by Cosmin Truta, 2018 # Revised by Kyle Bentley, 2018 # Revised by David Callu, 2020 +# Revised by Steve Robinson, 2020 # This code is released under the libpng license. # For conditions of distribution and use, see the disclaimer @@ -273,7 +274,7 @@ find_program(AWK NAMES gawk awk) include_directories(${CMAKE_CURRENT_BINARY_DIR}) -if(NOT AWK OR ANDROID) +if(NOT AWK OR ANDROID OR IOS) # No awk available to generate sources; use pre-built pnglibconf.h configure_file(${CMAKE_CURRENT_SOURCE_DIR}/scripts/pnglibconf.h.prebuilt ${CMAKE_CURRENT_BINARY_DIR}/pnglibconf.h) @@ -452,7 +453,7 @@ else() "${CMAKE_CURRENT_BINARY_DIR}/scripts/symbols.chk" "${CMAKE_CURRENT_BINARY_DIR}/scripts/symbols.out" "${CMAKE_CURRENT_BINARY_DIR}/scripts/vers.out") -endif(NOT AWK OR ANDROID) +endif(NOT AWK OR ANDROID OR IOS) # OUR SOURCES set(libpng_public_hdrs @@ -466,7 +467,7 @@ set(libpng_private_hdrs pnginfo.h pngstruct.h ) -if(AWK AND NOT ANDROID) +if(AWK AND NOT ANDROID AND NOT IOS) list(APPEND libpng_private_hdrs "${CMAKE_CURRENT_BINARY_DIR}/pngprefix.h") endif() set(libpng_sources |