Skip to content

Commit 546d964

Browse files
committed
Update libpng to v1.6.52
1 parent 194e191 commit 546d964

2 files changed

Lines changed: 21 additions & 44 deletions

File tree

png/libpng

Submodule libpng updated 191 files

png/png.patch

Lines changed: 20 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,51 +1,28 @@
1-
diff -Naur libpng/CMakeLists.txt PNG_BLD/CMakeLists.txt
2-
--- libpng/CMakeLists.txt 2024-03-06 10:43:33.593760600 -0500
3-
+++ PNG_BLD/CMakeLists.txt 2024-03-06 10:51:59.356989438 -0500
4-
@@ -30,6 +30,9 @@
1+
--- libpng/CMakeLists.txt 2025-12-04 15:29:05.405037672 -0500
2+
+++ PNG_BLD/CMakeLists.txt 2025-12-04 15:33:31.997897361 -0500
3+
@@ -29,6 +29,9 @@
54
VERSION ${PNGLIB_VERSION}
65
LANGUAGES C ASM)
76

87
+# Location of CMake modules
98
+list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/CMake")
109
+
11-
if(POLICY CMP0074)
12-
# Allow find_package() to use the ZLIB_ROOT variable, if available.
13-
cmake_policy(SET CMP0074 NEW)
14-
@@ -48,8 +51,10 @@
10+
include(CheckCSourceCompiles)
11+
include(CheckLibraryExists)
12+
include(GNUInstallDirs)
13+
@@ -43,9 +46,11 @@
1514
# Previously, we used to set CMAKE_DEBUG_POSTFIX globally. That variable should
1615
# not be cached, however, because doing so would affect all projects processed
1716
# after libpng, in unexpected and undesirable ways.
18-
-set(PNG_DEBUG_POSTFIX "d"
19-
- CACHE STRING "Postfix to append to library file names under the Debug configuration")
2017
+if(NOT PNG_NO_DEBUG_POSTFIX)
21-
+ set(PNG_DEBUG_POSTFIX "d"
22-
+ CACHE STRING "Postfix to append to library file names under the Debug configuration")
23-
+endif(NOT PNG_NO_DEBUG_POSTFIX)
18+
set(PNG_DEBUG_POSTFIX
19+
"d"
20+
CACHE STRING "Postfix to append to library file names under the Debug configuration")
21+
+endif()
2422

2523
# Allow the users to import their own extra configuration settings.
26-
set(DFA_XTRA ""
27-
@@ -98,6 +103,7 @@
28-
option(PNG_BUILD_ZLIB "Custom zlib location, else find_package is used" OFF)
29-
if(NOT PNG_BUILD_ZLIB)
30-
find_package(ZLIB REQUIRED)
31-
+ include_directories(${ZLIB_INCLUDE_DIRS})
32-
elseif(POLICY CMP0074)
33-
if("x${ZLIB_ROOT}" STREQUAL "x")
34-
message(DEPRECATION
35-
@@ -490,10 +496,9 @@
36-
37-
if(PNG_PREFIX)
38-
set(PNGLIBCONF_H_EXTRA_DEPENDS
39-
- "${CMAKE_CURRENT_BINARY_DIR}/scripts/prefix.out"
40-
- "${CMAKE_CURRENT_SOURCE_DIR}/scripts/macro.lst")
41-
+ png_scripts_prefix_out)
42-
set(PNGPREFIX_H_EXTRA_DEPENDS
43-
- "${CMAKE_CURRENT_BINARY_DIR}/scripts/intprefix.out")
44-
+ png_scripts_intprefix_out)
45-
endif()
46-
47-
generate_out(INPUT "${CMAKE_CURRENT_BINARY_DIR}/pnglibconf.c"
48-
@@ -677,15 +682,15 @@
24+
# Those settings can be either passed via DFA_XTRA if they are in DFA form
25+
@@ -649,15 +653,15 @@
4926
# We are on a Unix or Unix-like toolchain like the GNU toolchain on Windows.
5027
# Library file names are expected to have an implicit prefix such as "lib".
5128
# Let CMake prepend and append its usual prefixes and suffixes by default.
@@ -65,24 +42,24 @@ diff -Naur libpng/CMakeLists.txt PNG_BLD/CMakeLists.txt
6542
endif()
6643

6744
if(PNG_SHARED)
68-
@@ -1068,16 +1073,16 @@
45+
@@ -1052,16 +1056,16 @@
6946
if(PNG_SHARED)
7047
# Create a symlink for libpng.dll.a => libpng16.dll.a on Cygwin
7148
if(NOT WIN32 OR CYGWIN OR MINGW)
7249
- create_symlink(libpng${CMAKE_SHARED_LIBRARY_SUFFIX} TARGET png_shared)
73-
- install(FILES $<TARGET_LINKER_FILE_DIR:png_shared>/libpng${CMAKE_SHARED_LIBRARY_SUFFIX}
50+
- install(FILES "$<TARGET_LINKER_FILE_DIR:png_shared>/libpng${CMAKE_SHARED_LIBRARY_SUFFIX}"
7451
+ create_symlink(libpng_brl${CMAKE_SHARED_LIBRARY_SUFFIX} TARGET png_shared)
75-
+ install(FILES $<TARGET_LINKER_FILE_DIR:png_shared>/libpng_brl${CMAKE_SHARED_LIBRARY_SUFFIX}
76-
DESTINATION ${CMAKE_INSTALL_LIBDIR})
52+
+ install(FILES "$<TARGET_LINKER_FILE_DIR:png_shared>/libpng_brl${CMAKE_SHARED_LIBRARY_SUFFIX}"
53+
DESTINATION "${CMAKE_INSTALL_LIBDIR}")
7754
endif()
7855
endif()
7956

8057
if(PNG_STATIC)
8158
if(NOT WIN32 OR CYGWIN OR MINGW)
8259
- create_symlink(libpng${CMAKE_STATIC_LIBRARY_SUFFIX} TARGET png_static)
83-
- install(FILES $<TARGET_LINKER_FILE_DIR:png_static>/libpng${CMAKE_STATIC_LIBRARY_SUFFIX}
60+
- install(FILES "$<TARGET_LINKER_FILE_DIR:png_static>/libpng${CMAKE_STATIC_LIBRARY_SUFFIX}"
8461
+ create_symlink(libpng_brl${CMAKE_STATIC_LIBRARY_SUFFIX} TARGET png_static)
85-
+ install(FILES $<TARGET_LINKER_FILE_DIR:png_static>/libpng_brl${CMAKE_STATIC_LIBRARY_SUFFIX}
86-
DESTINATION ${CMAKE_INSTALL_LIBDIR})
62+
+ install(FILES "$<TARGET_LINKER_FILE_DIR:png_static>/libpng_brl${CMAKE_STATIC_LIBRARY_SUFFIX}"
63+
DESTINATION "${CMAKE_INSTALL_LIBDIR}")
8764
endif()
8865
endif()

0 commit comments

Comments
 (0)