libs: update libpng 1.6.38 + macos patch

This commit is contained in:
rafal1137 2022-10-28 16:46:09 +02:00
parent 34fa4575c1
commit 498aacf0a7
123 changed files with 10213 additions and 7092 deletions

69
libpng/.appveyor.yml Normal file
View file

@ -0,0 +1,69 @@
version: 1.6.x-{build}
branches:
except:
- /libpng[0-1][0-7]/
image:
- Visual Studio 2022
shallow_clone: true
environment:
matrix:
- TOOLCHAIN: vstudio
AUTOMATION: cmake
ARCH: x86
- TOOLCHAIN: vstudio
AUTOMATION: cmake
ARCH: x64
- TOOLCHAIN: vstudio
AUTOMATION: cmake
ARCH: arm64
CI_NO_TEST: 1
- TOOLCHAIN: msys2
AUTOMATION: cmake
ARCH: i686
- TOOLCHAIN: msys2
AUTOMATION: cmake
ARCH: x86_64
- TOOLCHAIN: msys2
AUTOMATION: autotools
ARCH: i686
- TOOLCHAIN: msys2
AUTOMATION: autotools
ARCH: x86_64
- TOOLCHAIN: msys2
AUTOMATION: legacy
ARCH: i686
- TOOLCHAIN: msys2
AUTOMATION: legacy
ARCH: x86_64
install:
- 'if "%TOOLCHAIN%"=="vstudio" C:\tools\vcpkg\vcpkg.exe install zlib:%ARCH%-windows'
- 'if "%TOOLCHAIN%"=="vstudio" C:\tools\vcpkg\vcpkg.exe integrate install'
before_build:
- 'if "%TOOLCHAIN%"=="vstudio" set CI_CMAKE_VARS=-DCMAKE_TOOLCHAIN_FILE=C:\tools\vcpkg\scripts\buildsystems\vcpkg.cmake'
- 'if "%TOOLCHAIN%"=="vstudio" set CI_CMAKE_GENERATOR=Visual Studio 17 2022'
- 'if "%TOOLCHAIN%"=="vstudio" if "%ARCH%"=="x86" set CI_CMAKE_GENERATOR_PLATFORM=Win32'
- 'if "%TOOLCHAIN%"=="vstudio" if "%ARCH%"=="x64" set CI_CMAKE_GENERATOR_PLATFORM=x64'
- 'if "%TOOLCHAIN%"=="vstudio" if "%ARCH%"=="arm64" set CI_CMAKE_GENERATOR_PLATFORM=ARM64'
- 'if "%TOOLCHAIN%"=="msys2" if "%AUTOMATION%"=="cmake" set CI_CMAKE_GENERATOR=Unix Makefiles'
- 'if "%TOOLCHAIN%"=="msys2" if "%ARCH%"=="i686" set PATH=C:\msys64\mingw32\bin;%PATH%'
- 'if "%TOOLCHAIN%"=="msys2" if "%ARCH%"=="x86_64" set PATH=C:\msys64\mingw64\bin;%PATH%'
- 'if "%TOOLCHAIN%"=="msys2" set CI_CC=%ARCH%-w64-mingw32-gcc'
- 'set CI_CMAKE_BUILD_FLAGS=--parallel 2'
- 'set CI_CTEST_FLAGS=--parallel 2'
- 'set CI_MAKE_FLAGS=-j2'
- 'set CI_LEGACY_MAKEFILES=scripts/makefile.gcc scripts/makefile.msys scripts/makefile.std'
build_script:
- 'if "%TOOLCHAIN%"=="vstudio" C:\msys64\usr\bin\bash.exe -l "%APPVEYOR_BUILD_FOLDER%\ci\ci_cmake.sh"'
- 'if "%TOOLCHAIN%"=="msys2" if "%AUTOMATION%"=="cmake" C:\msys64\usr\bin\bash.exe -l "%APPVEYOR_BUILD_FOLDER%\ci\ci_cmake.sh"'
- 'if "%TOOLCHAIN%"=="msys2" if "%AUTOMATION%"=="autotools" C:\msys64\usr\bin\bash.exe -l "%APPVEYOR_BUILD_FOLDER%\ci\ci_autotools.sh"'
- 'if "%TOOLCHAIN%"=="msys2" if "%AUTOMATION%"=="legacy" C:\msys64\usr\bin\bash.exe -l "%APPVEYOR_BUILD_FOLDER%\ci\ci_legacy.sh"'
cache:
- C:\tools\vcpkg\installed

75
libpng/.gitignore vendored Normal file
View file

@ -0,0 +1,75 @@
# Prerequisites
*.d
# Precompiled headers
*.gch
*.pch
# Object files
*.slo
*.lo
*.o
*.obj
# Linker output files
*.exp
*.ilk
*.map
# Compiled dynamic libraries
*.dll
*.dylib
*.so
*.so.*
# Compiled static libraries
*.a
*.la
*.lai
*.lib
# Compiled executables
*.app/
*.exe
# Debug files
*.dSYM/
*.idb
*.pdb
*.su
# Libpng configuration and build artifacts
.deps/
.dirstamp
Makefile
config.h
config.log
config.status
libpng-config
libpng.pc
libpng.vers
libpng16-config
libpng16.pc
libtool
pnglibconf.[ch]
pnglibconf.dfn
pnglibconf.out
pnglibconf.pre
pngprefix.h
stamp-h1
vers.out
# Libpng test artifacts
png-fix-itxt
pngcp
pngfix
pngimage
pngstest
pngtest
pngunknown
pngvalid
timepng
pngout.png
# Libpng CI artifacts
out/

45
libpng/.travis.yml Normal file
View file

@ -0,0 +1,45 @@
branches:
except:
- /libpng[0-1][0-7]/
language: c
os:
- freebsd
- linux
- osx
compiler:
- clang
- gcc
env:
- AUTOMATION=cmake CI_NO_TEST=1
- AUTOMATION=cmake CI_CMAKE_VARS="-DPNG_HARDWARE_OPTIMIZATIONS=ON" CI_SANITIZERS="address,undefined"
- AUTOMATION=cmake CI_CMAKE_VARS="-DPNG_HARDWARE_OPTIMIZATIONS=OFF" CI_SANITIZERS="address,undefined"
- AUTOMATION=autotools CI_NO_TEST=1
- AUTOMATION=autotools CI_CONFIGURE_FLAGS="--enable-hardware-optimizations"
- AUTOMATION=autotools CI_CONFIGURE_FLAGS="--disable-hardware-optimizations"
- AUTOMATION=legacy CI_NO_TEST=1
- AUTOMATION=legacy CI_SANITIZERS="address,undefined"
matrix:
include:
- os: osx
compiler: cc
env: AUTOMATION=cmake CI_CMAKE_GENERATOR=Xcode
exclude:
- os: freebsd
compiler: gcc
- os: osx
compiler: gcc
before_script:
- 'export CI_CMAKE_BUILD_FLAGS="--parallel 2"'
- 'export CI_CTEST_FLAGS="--parallel 2"'
- 'export CI_MAKE_FLAGS=-j2'
- 'export CI_CC=$TRAVIS_COMPILER'
- 'export CI_LEGACY_MAKEFILES="scripts/makefile.$TRAVIS_COMPILER scripts/makefile.std"'
script:
- './ci/ci_$AUTOMATION.sh'

View file

@ -1,5 +1,5 @@
libpng 1.6.37 - April 14, 2019
==============================
libpng 1.6.38 - September 14, 2022
==================================
This is a public release of libpng, intended for use in production code.
@ -9,13 +9,13 @@ Files available for download
Source files with LF line endings (for Unix/Linux):
* libpng-1.6.37.tar.xz (LZMA-compressed, recommended)
* libpng-1.6.37.tar.gz
* libpng-1.6.38.tar.xz (LZMA-compressed, recommended)
* libpng-1.6.38.tar.gz
Source files with CRLF line endings (for Windows):
* lp1637.7z (LZMA-compressed, recommended)
* lp1637.zip
* lp1638.7z (LZMA-compressed, recommended)
* lp1638.zip
Other information:
@ -25,20 +25,13 @@ Other information:
* TRADEMARK.md
Changes since the previous public release (version 1.6.36)
Changes since the previous public release (version 1.6.37)
----------------------------------------------------------
* Fixed a use-after-free vulnerability (CVE-2019-7317) in png_image_free.
* Fixed a memory leak in the ARM NEON implementation of png_do_expand_palette.
* Fixed a memory leak in pngtest.c.
* Fixed two vulnerabilities (CVE-2018-14048, CVE-2018-14550) in
contrib/pngminus; refactor.
* Changed the license of contrib/pngminus to MIT; refresh makefile and docs.
(Contributed by Willem van Schaik)
* Fixed a typo in the libpng license v2.
(Contributed by Miguel Ojeda)
* Added makefiles for AddressSanitizer-enabled builds.
* Cleaned up various makefiles.
* Added configurations and scripts for continuous integration.
* Fixed various errors in the handling of tRNS, hIST and eXIf.
* Implemented many stability improvements across all platforms.
* Updated the internal documentation.
Send comments/corrections/commendations to png-mng-implement at lists.sf.net.

View file

@ -20,7 +20,9 @@ Authors, for copyright and licensing purposes.
* Mans Rullgard
* Matt Sarett
* Mike Klein
* Pascal Massimino
* Paul Schmidt
* Qiang Zhou
* Sam Bushell
* Samuel Williams
* Simon-Pierre Cadieux
@ -35,10 +37,12 @@ Authors, for copyright and licensing purposes.
* Google Inc.
- Matt Sarett
- Mike Klein
- Dan Field
- Sami Boukortt
The build projects, the build scripts, the test scripts, and other
files in the "projects", "scripts" and "tests" directories, have other
copyright owners, but are released under the libpng license.
files in the "ci", "projects", "scripts" and "tests" directories, have
other copyright owners, but are released under the libpng license.
Some files in the "contrib" directory, and some tools-generated files
that are distributed with libpng, have other copyright owners, and are

View file

@ -2295,7 +2295,7 @@ Version 1.4.0beta58 [May 14, 2009]
Clarified usage of sig_bit versus sig_bit_p in example.c (Vincent Torri)
Version 1.4.0beta59 [May 15, 2009]
Reformated sources in libpng style (3-space intentation, comment format)
Reformated sources in libpng style (3-space indentation, comment format)
Fixed typo in libpng docs (PNG_FILTER_AVE should be PNG_FILTER_AVG)
Added sections about the git repository and our coding style to the
documentation
@ -3886,7 +3886,7 @@ Version 1.6.0beta06 [January 24, 2012]
Version 1.6.0beta07 [January 28, 2012]
Eliminated Intel icc/icl compiler warnings. The Intel (GCC derived)
compiler issues slightly different warnings from those issued by the
current vesions of GCC. This eliminates those warnings by
current versions of GCC. This eliminates those warnings by
adding/removing casts and small code rewrites.
Updated configure.ac from autoupdate: added --enable-werror option.
Also some layout regularization and removal of introduced tab characters
@ -6103,6 +6103,12 @@ Version 1.6.37 [April 14, 2019]
Added makefiles for AddressSanitizer-enabled builds.
Cleaned up various makefiles.
Version 1.6.38 [September 14, 2022]
Added configurations and scripts for continuous integration.
Fixed various errors in the handling of tRNS, hIST and eXIf.
Implemented many stability improvements across all platforms.
Updated the internal documentation.
Send comments/corrections/commendations to png-mng-implement at lists.sf.net.
Subscription is required; visit
https://lists.sourceforge.net/lists/listinfo/png-mng-implement

File diff suppressed because it is too large Load diff

View file

@ -128,16 +128,18 @@ Your directory structure should look like this:
README
*.h, *.c => libpng source files
CMakeLists.txt => "cmake" script
ci
ci_*.sh
configuration files:
configure.ac, configure, Makefile.am, Makefile.in,
autogen.sh, config.guess, ltmain.sh, missing, libpng.pc.in,
libpng-config.in, aclocal.m4, config.h.in, config.sub,
depcomp, install-sh, mkinstalldirs, test-pngtest.sh
depcomp, install-sh, mkinstalldirs, test-pngtest.sh, etc.
contrib
arm-neon, conftest, examples, gregbook, libtests, pngminim,
pngminus, pngsuite, tools, visupng
projects
cbuilder5, owatcom, visualc71, vstudio, xcode
owatcom, visualc71, vstudio
scripts
makefile.*
*.def (module definition files)
@ -145,7 +147,7 @@ Your directory structure should look like this:
pngtest.png
etc.
zlib
README, *.h, *.c contrib, etc.
README, *.h, *.c, contrib, etc.
If the line endings in the files look funny, you may wish to get the other
distribution of libpng. It is available in both tar.gz (UNIX style line
@ -153,28 +155,27 @@ endings) and zip (DOS style line endings) formats.
VI. Building with project files
If you are building libpng with MSVC, you can enter the
libpng projects\visualc71 or vstudio directory and follow the instructions
in README.txt.
If you are building libpng with Microsoft Visual Studio, you can enter
the directory projects\visualc71 or projects\vstudio and follow the
instructions in README.txt.
Otherwise enter the zlib directory and follow the instructions in zlib/README,
then come back here and run "configure" or choose the appropriate
makefile.sys in the scripts directory.
Otherwise, enter the zlib directory and follow the instructions in
zlib/README, then come back here and run "configure" or choose the
appropriate makefile in the scripts directory.
VII. Building with makefiles
Copy the file (or files) that you need from the
scripts directory into this directory, for example
MSDOS example:
copy scripts\makefile.msc makefile
copy scripts\pnglibconf.h.prebuilt pnglibconf.h
UNIX example:
cp scripts/makefile.std makefile
cp scripts/pnglibconf.h.prebuilt pnglibconf.h
cp scripts/makefile.std Makefile
make
Windows example:
nmake -f scripts\makefile.vcwin32
Read the makefile to see if you need to change any source or
target directories to match your preferences.
@ -197,30 +198,27 @@ do that, run "make install" in the zlib directory first if necessary).
Some also allow you to run "make test-installed" after you have
run "make install".
VIII. Configuring libpng for 16-bit platforms
VIII. Configuring for DOS and other 16-bit platforms
You will want to look into zconf.h to tell zlib (and thus libpng) that
it cannot allocate more than 64K at a time. Even if you can, the memory
won't be accessible. So limit zlib and libpng to 64K by defining MAXSEG_64K.
IX. Configuring for DOS
Officially, the support for 16-bit platforms has been removed.
For DOS users who only have access to the lower 640K, you will
have to limit zlib's memory usage via a png_set_compression_mem_level()
call. See zlib.h or zconf.h in the zlib library for more information.
X. Configuring for Medium Model
You may be or may not be in luck if you target the "large" memory model,
but all the smaller models ("small", "compact" and "medium") are known
to be unworkable. For DOS users who have access beyond the lower 640K,
a "flat" 32-bit DOS model (such as DJGPP) is strongly recommended.
Libpng's support for medium model has been tested on most of the popular
compilers. Make sure MAXSEG_64K gets defined, USE_FAR_KEYWORD gets
defined, and FAR gets defined to far in pngconf.h, and you should be
all set. Everything in the library (except for zlib's structure) is
expecting far data. You must use the typedefs with the p or pp on
the end for pointers (or at least look at them and be careful). Make
note that the rows of data are defined as png_bytepp, which is
an "unsigned char far * far *".
For DOS users who only have access to the lower 640K, you will have to
limit zlib's memory usage via a png_set_compression_mem_level() call.
You will also have to look into zconf.h to tell zlib (and thus libpng)
that it cannot allocate more than 64K at a time. Even if you can, the
memory won't be accessible. Therefore, you should limit zlib and libpng
to 64K by defining MAXSEG_64K.
XI. Prepending a prefix to exported symbols
IX. Prepending a prefix to exported symbols
Starting with libpng-1.6.0, you can configure libpng (when using the
"configure" script) to prefix all exported symbols by means of the
@ -231,7 +229,7 @@ identifier). This creates a set of macros in pnglibconf.h, so this is
transparent to applications; their function calls get transformed by
the macros to use the modified names.
XII. Configuring for compiler xxx:
X. Configuring for compiler xxx:
All includes for libpng are in pngconf.h. If you need to add, change
or delete an include, this is the place to do it.
@ -243,7 +241,7 @@ As of libpng-1.5.0, pngpriv.h also includes three other private header
files, pngstruct.h, pnginfo.h, and pngdebug.h, which contain material
that previously appeared in the public headers.
XIII. Removing unwanted object code
XI. Removing unwanted object code
There are a bunch of #define's in pngconf.h that control what parts of
libpng are compiled. All the defines end in _SUPPORTED. If you are
@ -282,7 +280,7 @@ library to fail if they call functions not available in your library.
The size of the library itself should not be an issue, because only
those sections that are actually used will be loaded into memory.
XIV. Enabling or disabling hardware optimizations
XII. Enabling or disabling hardware optimizations
Certain hardware capabilities, such as the Intel SSE instructions,
are normally detected at run time. Enable them with configure options
@ -332,7 +330,7 @@ or disable them all at once with
cmake . -DPNG_HARDWARE_OPTIMIZATIONS=no
XV. Changes to the build and configuration of libpng in libpng-1.5.x
XIII. Changes to the build and configuration of libpng in libpng-1.5.x
Details of internal changes to the library code can be found in the CHANGES
file and in the GIT repository logs. These will be of no concern to the vast
@ -423,7 +421,7 @@ $PREFIX/include directory). Do not edit pnglibconf.h after you have built
libpng, because than the settings would not accurately reflect the settings
that were used to build libpng.
XVI. Setjmp/longjmp issues
XIV. Setjmp/longjmp issues
Libpng uses setjmp()/longjmp() for error handling. Unfortunately setjmp()
is known to be not thread-safe on some platforms and we don't know of
@ -441,7 +439,7 @@ This requires setjmp/longjmp, so you must either build the library
with PNG_SETJMP_SUPPORTED defined, or with PNG_SIMPLIFIED_READ_SUPPORTED
and PNG_SIMPLIFIED_WRITE_SUPPORTED undefined.
XVII. Common linking failures
XV. Common linking failures
If your application fails to find libpng or zlib entries while linking:
@ -453,12 +451,13 @@ If your application fails to find libpng or zlib entries while linking:
If you are using the vstudio project, observe the WARNING in
project/vstudio/README.txt.
XVIII. Other sources of information about libpng:
XVI. Other sources of information about libpng:
Further information can be found in the README and libpng-manual.txt
files, in the individual makefiles, in png.h, and the manual pages
libpng.3 and png.5.
Copyright (c) 2022 Cosmin Truta
Copyright (c) 1998-2002,2006-2016 Glenn Randers-Pehrson
This document is released under the libpng license.
For conditions of distribution and use, see the disclaimer

View file

@ -4,8 +4,8 @@ COPYRIGHT NOTICE, DISCLAIMER, and LICENSE
PNG Reference Library License version 2
---------------------------------------
* Copyright (c) 1995-2019 The PNG Reference Library Authors.
* Copyright (c) 2018-2019 Cosmin Truta.
* Copyright (c) 1995-2022 The PNG Reference Library Authors.
* Copyright (c) 2018-2022 Cosmin Truta.
* Copyright (c) 2000-2002, 2004, 2006-2018 Glenn Randers-Pehrson.
* Copyright (c) 1996-1997 Andreas Dilger.
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.

View file

@ -59,8 +59,7 @@ pngcp_LDADD = libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@.la
# Generally these are single line shell scripts to run a test with a particular
# set of parameters:
TESTS =\
tests/pngtest\
tests/pngtest-badpngs\
tests/pngtest-all\
tests/pngvalid-gamma-16-to-8 tests/pngvalid-gamma-alpha-mode\
tests/pngvalid-gamma-background tests/pngvalid-gamma-expand16-alpha-mode\
tests/pngvalid-gamma-expand16-background\

View file

@ -1,7 +1,7 @@
# Makefile.in generated by automake 1.16.1 from Makefile.am.
# Makefile.in generated by automake 1.16.5 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2018 Free Software Foundation, Inc.
# Copyright (C) 1994-2021 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -334,8 +334,8 @@ NROFF = nroff
MANS = $(dist_man_MANS)
DATA = $(pkgconfig_DATA)
HEADERS = $(nodist_pkginclude_HEADERS) $(pkginclude_HEADERS)
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \
$(LISP)config.h.in
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) \
config.h.in
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
@ -352,9 +352,6 @@ am__define_uniq_tagged_files = \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | $(am__uniquify_input)`
ETAGS = etags
CTAGS = ctags
CSCOPE = cscope
AM_RECURSIVE_TARGETS = cscope check recheck
am__tty_colors_dummy = \
mgn= red= grn= lgn= blu= brg= std=; \
@ -511,6 +508,7 @@ am__set_TESTS_bases = \
bases='$(TEST_LOGS)'; \
bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
bases=`echo $$bases`
AM_TESTSUITE_SUMMARY_HEADER = ' for $(PACKAGE_STRING)'
RECHECK_LOGS = $(TEST_LOGS)
TEST_SUITE_LOG = test-suite.log
TEST_EXTENSIONS = @EXEEXT@ .test
@ -550,6 +548,8 @@ am__post_remove_distdir = $(am__remove_distdir)
DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.xz
GZIP_ENV = --best
DIST_TARGETS = dist-xz dist-gzip
# Exists only to be overridden by the user if desired.
AM_DISTCHECK_DVI_TARGET = dvi
distuninstallcheck_listfiles = find . -type f -print
am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
| sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$'
@ -574,6 +574,8 @@ CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CSCOPE = @CSCOPE@
CTAGS = @CTAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
@ -591,8 +593,10 @@ ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
ETAGS = @ETAGS@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
FILECMD = @FILECMD@
GREP = @GREP@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
@ -636,7 +640,6 @@ PNGLIB_VERSION = @PNGLIB_VERSION@
# AM_CFLAGS)
PNG_COPTS = @PNG_COPTS@
PNG_PREFIX = @PNG_PREFIX@
POW_LIB = @POW_LIB@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
@ -695,6 +698,7 @@ pkgconfigdir = @pkgconfigdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
runstatedir = @runstatedir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
@ -736,8 +740,7 @@ pngcp_LDADD = libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@.la
# Generally these are single line shell scripts to run a test with a particular
# set of parameters:
TESTS = \
tests/pngtest\
tests/pngtest-badpngs\
tests/pngtest-all\
tests/pngvalid-gamma-16-to-8 tests/pngvalid-gamma-alpha-mode\
tests/pngvalid-gamma-background tests/pngvalid-gamma-expand16-alpha-mode\
tests/pngvalid-gamma-expand16-background\
@ -1544,7 +1547,7 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \
fi; \
echo "$${col}$$br$${std}"; \
echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}"; \
echo "$${col}Testsuite summary"$(AM_TESTSUITE_SUMMARY_HEADER)"$${std}"; \
echo "$${col}$$br$${std}"; \
create_testsuite_report --maybe-color; \
echo "$$col$$br$$std"; \
@ -1578,16 +1581,9 @@ recheck: all $(check_PROGRAMS)
am__force_recheck=am--force-recheck \
TEST_LOGS="$$log_list"; \
exit $$?
tests/pngtest.log: tests/pngtest
@p='tests/pngtest'; \
b='tests/pngtest'; \
$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
--log-file $$b.log --trs-file $$b.trs \
$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
"$$tst" $(AM_TESTS_FD_REDIRECT)
tests/pngtest-badpngs.log: tests/pngtest-badpngs
@p='tests/pngtest-badpngs'; \
b='tests/pngtest-badpngs'; \
tests/pngtest-all.log: tests/pngtest-all
@p='tests/pngtest-all'; \
b='tests/pngtest-all'; \
$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
--log-file $$b.log --trs-file $$b.trs \
$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
@ -1823,7 +1819,6 @@ tests/pngimage-full.log: tests/pngimage-full
@am__EXEEXT_TRUE@ --log-file $$b.log --trs-file $$b.trs \
@am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \
@am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT)
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
@ -1884,6 +1879,10 @@ dist-xz: distdir
tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz
$(am__post_remove_distdir)
dist-zstd: distdir
tardir=$(distdir) && $(am__tar) | zstd -c $${ZSTD_CLEVEL-$${ZSTD_OPT--19}} >$(distdir).tar.zst
$(am__post_remove_distdir)
dist-tarZ: distdir
@echo WARNING: "Support for distribution archives compressed with" \
"legacy program 'compress' is deprecated." >&2
@ -1926,6 +1925,8 @@ distcheck: dist
eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\
*.zip*) \
unzip $(distdir).zip ;;\
*.tar.zst*) \
zstd -dc $(distdir).tar.zst | $(am__untar) ;;\
esac
chmod -R a-w $(distdir)
chmod u+w $(distdir)
@ -1941,7 +1942,7 @@ distcheck: dist
$(DISTCHECK_CONFIGURE_FLAGS) \
--srcdir=../.. --prefix="$$dc_install_base" \
&& $(MAKE) $(AM_MAKEFLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
&& $(MAKE) $(AM_MAKEFLAGS) $(AM_DISTCHECK_DVI_TARGET) \
&& $(MAKE) $(AM_MAKEFLAGS) check \
&& $(MAKE) $(AM_MAKEFLAGS) install \
&& $(MAKE) $(AM_MAKEFLAGS) installcheck \
@ -2001,13 +2002,16 @@ all-am: Makefile $(PROGRAMS) $(LTLIBRARIES) $(SCRIPTS) $(MANS) $(DATA) \
$(HEADERS) config.h
install-binPROGRAMS: install-libLTLIBRARIES
install-checkPROGRAMS: install-libLTLIBRARIES
installdirs:
for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man3dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(pkgincludedir)" "$(DESTDIR)$(pkgincludedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) install-am
install-exec: install-exec-am
install-exec: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) install-exec-am
install-data: install-data-am
uninstall: uninstall-am
@ -2208,22 +2212,23 @@ uninstall-am: uninstall-binPROGRAMS uninstall-binSCRIPTS \
uninstall-man: uninstall-man3 uninstall-man5
.MAKE: all check check-am install install-am install-data-am \
install-exec-am install-strip uninstall-am
install-exec install-exec-am install-strip uninstall-am
.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles am--refresh check \
check-TESTS check-am clean clean-binPROGRAMS \
clean-checkPROGRAMS clean-cscope clean-generic \
clean-libLTLIBRARIES clean-libtool cscope cscopelist-am ctags \
ctags-am dist dist-all dist-bzip2 dist-gzip dist-hook \
dist-lzip dist-shar dist-tarZ dist-xz dist-zip distcheck \
distclean distclean-compile distclean-generic distclean-hdr \
distclean-libtool distclean-tags distcleancheck distdir \
distuninstallcheck dvi dvi-am html html-am info info-am \
install install-am install-binPROGRAMS install-binSCRIPTS \
install-data install-data-am install-data-hook install-dvi \
install-dvi-am install-exec install-exec-am install-exec-hook \
install-html install-html-am install-info install-info-am \
install-libLTLIBRARIES install-man install-man3 install-man5 \
dist-lzip dist-shar dist-tarZ dist-xz dist-zip dist-zstd \
distcheck distclean distclean-compile distclean-generic \
distclean-hdr distclean-libtool distclean-tags distcleancheck \
distdir distuninstallcheck dvi dvi-am html html-am info \
info-am install install-am install-binPROGRAMS \
install-binSCRIPTS install-data install-data-am \
install-data-hook install-dvi install-dvi-am install-exec \
install-exec-am install-exec-hook install-html install-html-am \
install-info install-info-am install-libLTLIBRARIES \
install-man install-man3 install-man5 \
install-nodist_pkgincludeHEADERS install-pdf install-pdf-am \
install-pkgconfigDATA install-pkgincludeHEADERS install-ps \
install-ps-am install-strip installcheck installcheck-am \

View file

@ -1,12 +1,12 @@
README for libpng version 1.6.37 - April 14, 2019
=================================================
README for libpng version 1.6.38
================================
See the note about version numbers near the top of png.h.
See INSTALL for instructions on how to install libpng.
Libpng comes in several distribution formats. Get libpng-*.tar.gz or
libpng-*.tar.xz or if you want UNIX-style line endings in the text
files, or lpng*.7z or lpng*.zip if you want DOS-style line endings.
libpng-*.tar.xz if you want UNIX-style line endings in the text files,
or lpng*.7z or lpng*.zip if you want DOS-style line endings.
Version 0.89 was the first official release of libpng. Don't let the
fact that it's the first release fool you. The libpng library has been

83
libpng/aclocal.m4 vendored
View file

@ -1,6 +1,6 @@
# generated automatically by aclocal 1.16.1 -*- Autoconf -*-
# generated automatically by aclocal 1.16.5 -*- Autoconf -*-
# Copyright (C) 1996-2018 Free Software Foundation, Inc.
# Copyright (C) 1996-2021 Free Software Foundation, Inc.
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -14,13 +14,13 @@
m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
[m4_warning([this file was generated for autoconf 2.69.
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.71],,
[m4_warning([this file was generated for autoconf 2.71.
You have another version of autoconf. It may work, but is not guaranteed to.
If you have problems, you may need to regenerate the build system entirely.
To do so, use the procedure documented by the package, typically 'autoreconf'.])])
# Copyright (C) 2002-2018 Free Software Foundation, Inc.
# Copyright (C) 2002-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -35,7 +35,7 @@ AC_DEFUN([AM_AUTOMAKE_VERSION],
[am__api_version='1.16'
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
dnl require some minimum version. Point them to the right macro.
m4_if([$1], [1.16.1], [],
m4_if([$1], [1.16.5], [],
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
])
@ -51,14 +51,14 @@ m4_define([_AM_AUTOCONF_VERSION], [])
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
[AM_AUTOMAKE_VERSION([1.16.1])dnl
[AM_AUTOMAKE_VERSION([1.16.5])dnl
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
# Figure out how to run the assembler. -*- Autoconf -*-
# Copyright (C) 2001-2018 Free Software Foundation, Inc.
# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -78,7 +78,7 @@ _AM_IF_OPTION([no-dependencies],, [_AM_DEPENDENCIES([CCAS])])dnl
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
# Copyright (C) 2001-2018 Free Software Foundation, Inc.
# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -130,7 +130,7 @@ am_aux_dir=`cd "$ac_aux_dir" && pwd`
# AM_CONDITIONAL -*- Autoconf -*-
# Copyright (C) 1997-2018 Free Software Foundation, Inc.
# Copyright (C) 1997-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -161,7 +161,7 @@ AC_CONFIG_COMMANDS_PRE(
Usually this means the macro was only invoked conditionally.]])
fi])])
# Copyright (C) 1999-2018 Free Software Foundation, Inc.
# Copyright (C) 1999-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -352,7 +352,7 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
# Generate code to set up dependency tracking. -*- Autoconf -*-
# Copyright (C) 1999-2018 Free Software Foundation, Inc.
# Copyright (C) 1999-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -391,7 +391,9 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
done
if test $am_rc -ne 0; then
AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments
for automatic dependency tracking. Try re-running configure with the
for automatic dependency tracking. If GNU make was not used, consider
re-running the configure script with MAKE="gmake" (or whatever is
necessary). You can also try re-running configure with the
'--disable-dependency-tracking' option to at least be able to build
the package (albeit without support for automatic dependency tracking).])
fi
@ -418,7 +420,7 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
# Do all the work for Automake. -*- Autoconf -*-
# Copyright (C) 1996-2018 Free Software Foundation, Inc.
# Copyright (C) 1996-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -446,6 +448,10 @@ m4_defn([AC_PROG_CC])
# release and drop the old call support.
AC_DEFUN([AM_INIT_AUTOMAKE],
[AC_PREREQ([2.65])dnl
m4_ifdef([_$0_ALREADY_INIT],
[m4_fatal([$0 expanded multiple times
]m4_defn([_$0_ALREADY_INIT]))],
[m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl
dnl Autoconf wants to disallow AM_ names. We explicitly allow
dnl the ones we care about.
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
@ -482,7 +488,7 @@ m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
[_AM_SET_OPTIONS([$1])dnl
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
m4_if(
m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]),
[ok:ok],,
[m4_fatal([AC_INIT should be called with package and version arguments])])dnl
AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
@ -534,6 +540,20 @@ AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
[m4_define([AC_PROG_OBJCXX],
m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
])
# Variables for tags utilities; see am/tags.am
if test -z "$CTAGS"; then
CTAGS=ctags
fi
AC_SUBST([CTAGS])
if test -z "$ETAGS"; then
ETAGS=etags
fi
AC_SUBST([ETAGS])
if test -z "$CSCOPE"; then
CSCOPE=cscope
fi
AC_SUBST([CSCOPE])
AC_REQUIRE([AM_SILENT_RULES])dnl
dnl The testsuite driver may need to know about EXEEXT, so add the
dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
@ -615,7 +635,7 @@ for _am_header in $config_headers :; do
done
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
# Copyright (C) 2001-2018 Free Software Foundation, Inc.
# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -636,7 +656,7 @@ if test x"${install_sh+set}" != xset; then
fi
AC_SUBST([install_sh])])
# Copyright (C) 2003-2018 Free Software Foundation, Inc.
# Copyright (C) 2003-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -658,7 +678,7 @@ AC_SUBST([am__leading_dot])])
# Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
# From Jim Meyering
# Copyright (C) 1996-2018 Free Software Foundation, Inc.
# Copyright (C) 1996-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -693,7 +713,7 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
# Check to see how 'make' treats includes. -*- Autoconf -*-
# Copyright (C) 2001-2018 Free Software Foundation, Inc.
# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -736,7 +756,7 @@ AC_SUBST([am__quote])])
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
# Copyright (C) 1997-2018 Free Software Foundation, Inc.
# Copyright (C) 1997-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -757,12 +777,7 @@ AC_DEFUN([AM_MISSING_HAS_RUN],
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
AC_REQUIRE_AUX_FILE([missing])dnl
if test x"${MISSING+set}" != xset; then
case $am_aux_dir in
*\ * | *\ *)
MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
*)
MISSING="\${SHELL} $am_aux_dir/missing" ;;
esac
MISSING="\${SHELL} '$am_aux_dir/missing'"
fi
# Use eval to expand $SHELL
if eval "$MISSING --is-lightweight"; then
@ -775,7 +790,7 @@ fi
# Helper functions for option handling. -*- Autoconf -*-
# Copyright (C) 2001-2018 Free Software Foundation, Inc.
# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -804,7 +819,7 @@ AC_DEFUN([_AM_SET_OPTIONS],
AC_DEFUN([_AM_IF_OPTION],
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
# Copyright (C) 1999-2018 Free Software Foundation, Inc.
# Copyright (C) 1999-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -851,7 +866,7 @@ AC_LANG_POP([C])])
# For backward compatibility.
AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
# Copyright (C) 2001-2018 Free Software Foundation, Inc.
# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -870,7 +885,7 @@ AC_DEFUN([AM_RUN_LOG],
# Check to make sure that the build environment is sane. -*- Autoconf -*-
# Copyright (C) 1996-2018 Free Software Foundation, Inc.
# Copyright (C) 1996-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -951,7 +966,7 @@ AC_CONFIG_COMMANDS_PRE(
rm -f conftest.file
])
# Copyright (C) 2009-2018 Free Software Foundation, Inc.
# Copyright (C) 2009-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -1011,7 +1026,7 @@ AC_SUBST([AM_BACKSLASH])dnl
_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
])
# Copyright (C) 2001-2018 Free Software Foundation, Inc.
# Copyright (C) 2001-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -1039,7 +1054,7 @@ fi
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
AC_SUBST([INSTALL_STRIP_PROGRAM])])
# Copyright (C) 2006-2018 Free Software Foundation, Inc.
# Copyright (C) 2006-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@ -1058,7 +1073,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
# Check how to create a tarball. -*- Autoconf -*-
# Copyright (C) 2004-2018 Free Software Foundation, Inc.
# Copyright (C) 2004-2021 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,

View file

@ -1,7 +1,7 @@
/* arm_init.c - NEON optimised filter functions
*
* Copyright (c) 2018 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 2014,2016 Glenn Randers-Pehrson
* Written by Mans Rullgard, 2011.
*
@ -10,9 +10,7 @@
* and license in png.h
*/
/* Below, after checking __linux__, various non-C90 POSIX 1003.1 functions are
* called.
*/
/* This module requires POSIX 1003.1 functions. */
#define _POSIX_SOURCE 1
#include "../pngpriv.h"
@ -33,21 +31,23 @@
* has partial support is contrib/arm-neon/linux.c - a generic Linux
* implementation which reads /proc/cpufino.
*/
#include <signal.h> /* for sig_atomic_t */
#ifndef PNG_ARM_NEON_FILE
# ifdef __linux__
# define PNG_ARM_NEON_FILE "contrib/arm-neon/linux.c"
# if defined(__aarch64__) || defined(_M_ARM64)
/* ARM Neon is expected to be unconditionally available on ARM64. */
# error "PNG_ARM_NEON_CHECK_SUPPORTED must not be defined on this platform"
# elif defined(__linux__)
# define PNG_ARM_NEON_FILE "contrib/arm-neon/linux.c"
# else
# error "No support for run-time ARM Neon checking; use compile-time options"
# endif
#endif
#ifdef PNG_ARM_NEON_FILE
#include <signal.h> /* for sig_atomic_t */
static int png_have_neon(png_structp png_ptr);
#include PNG_ARM_NEON_FILE
#else /* PNG_ARM_NEON_FILE */
# error "PNG_ARM_NEON_FILE undefined: no support for run-time ARM NEON checks"
#endif /* PNG_ARM_NEON_FILE */
#ifdef PNG_ARM_NEON_FILE
# include PNG_ARM_NEON_FILE
#endif
#endif /* PNG_ARM_NEON_CHECK_SUPPORTED */
#ifndef PNG_ALIGNED_MEMORY_SUPPORTED

View file

@ -18,7 +18,7 @@
/* This code requires -mfpu=neon on the command line: */
#if PNG_ARM_NEON_IMPLEMENTATION == 1 /* intrinsics code from pngpriv.h */
#if defined(_MSC_VER) && defined(_M_ARM64)
#if defined(_MSC_VER) && !defined(__clang__) && defined(_M_ARM64)
# include <arm64_neon.h>
#else
# include <arm_neon.h>

View file

@ -14,7 +14,7 @@
#if PNG_ARM_NEON_IMPLEMENTATION == 1
#if defined(_MSC_VER) && defined(_M_ARM64)
#if defined(_MSC_VER) && !defined(__clang__) && defined(_M_ARM64)
# include <arm64_neon.h>
#else
# include <arm_neon.h>
@ -30,8 +30,6 @@ png_riffle_palette_neon(png_structrp png_ptr)
int num_trans = png_ptr->num_trans;
int i;
png_debug(1, "in png_riffle_palette_neon");
/* Initially black, opaque. */
uint8x16x4_t w = {{
vdupq_n_u8(0x00),
@ -40,6 +38,8 @@ png_riffle_palette_neon(png_structrp png_ptr)
vdupq_n_u8(0xff),
}};
png_debug(1, "in png_riffle_palette_neon");
/* First, riffle the RGB colours into an RGBA8 palette.
* The alpha component is set to opaque for now.
*/
@ -65,11 +65,12 @@ png_do_expand_palette_rgba8_neon(png_structrp png_ptr, png_row_infop row_info,
png_uint_32 row_width = row_info->width;
const png_uint_32 *riffled_palette =
(const png_uint_32 *)png_ptr->riffled_palette;
const png_int_32 pixels_per_chunk = 4;
int i;
const png_uint_32 pixels_per_chunk = 4;
png_uint_32 i;
png_debug(1, "in png_do_expand_palette_rgba8_neon");
PNG_UNUSED(row)
if (row_width < pixels_per_chunk)
return 0;
@ -109,10 +110,11 @@ png_do_expand_palette_rgb8_neon(png_structrp png_ptr, png_row_infop row_info,
png_uint_32 row_width = row_info->width;
png_const_bytep palette = (png_const_bytep)png_ptr->palette;
const png_uint_32 pixels_per_chunk = 8;
int i;
png_uint_32 i;
png_debug(1, "in png_do_expand_palette_rgb8_neon");
PNG_UNUSED(row)
if (row_width <= pixels_per_chunk)
return 0;

117
libpng/ci/ci_autotools.sh Normal file
View file

@ -0,0 +1,117 @@
#!/usr/bin/env bash
set -e
# ci_autotools.sh
# Continuously integrate libpng using the GNU Autotools.
#
# Copyright (c) 2019-2022 Cosmin Truta.
#
# This software is released under the libpng license.
# For conditions of distribution and use, see the disclaimer
# and license in png.h.
CI_SCRIPTNAME="$(basename "$0")"
CI_SCRIPTDIR="$(cd "$(dirname "$0")" && pwd)"
CI_SRCDIR="$(dirname "$CI_SCRIPTDIR")"
CI_BUILDDIR="$CI_SRCDIR/out/autotools.build"
CI_INSTALLDIR="$CI_SRCDIR/out/autotools.install"
function ci_info {
printf >&2 "%s: %s\\n" "$CI_SCRIPTNAME" "$*"
}
function ci_err {
printf >&2 "%s: error: %s\\n" "$CI_SCRIPTNAME" "$*"
exit 2
}
function ci_spawn {
printf >&2 "%s: executing:" "$CI_SCRIPTNAME"
printf >&2 " %q" "$@"
printf >&2 "\\n"
"$@"
}
function ci_init_autotools {
CI_SYSTEM_NAME="$(uname -s)"
CI_MACHINE_NAME="$(uname -m)"
CI_MAKE="${CI_MAKE:-make}"
# Set CI_CC to cc by default, if the cc command is available.
# The configure script defaults CC to gcc, which is not always a good idea.
[[ -x $(command -v cc) ]] && CI_CC="${CI_CC:-cc}"
# Ensure that the CI_ variables that cannot be customized reliably are not initialized.
[[ ! $CI_CONFIGURE_VARS ]] || ci_err "unexpected: \$CI_CONFIGURE_VARS='$CI_CONFIGURE_VARS'"
[[ ! $CI_MAKE_VARS ]] || ci_err "unexpected: \$CI_MAKE_VARS='$CI_MAKE_VARS'"
}
function ci_trace_autotools {
ci_info "## START OF CONFIGURATION ##"
ci_info "system name: $CI_SYSTEM_NAME"
ci_info "machine hardware name: $CI_MACHINE_NAME"
ci_info "source directory: $CI_SRCDIR"
ci_info "build directory: $CI_BUILDDIR"
ci_info "install directory: $CI_INSTALLDIR"
ci_info "environment option: \$CI_CONFIGURE_FLAGS: '$CI_CONFIGURE_FLAGS'"
ci_info "environment option: \$CI_MAKE: '$CI_MAKE'"
ci_info "environment option: \$CI_MAKE_FLAGS: '$CI_MAKE_FLAGS'"
ci_info "environment option: \$CI_CC: '$CI_CC'"
ci_info "environment option: \$CI_CC_FLAGS: '$CI_CC_FLAGS'"
ci_info "environment option: \$CI_CPP: '$CI_CPP'"
ci_info "environment option: \$CI_CPP_FLAGS: '$CI_CPP_FLAGS'"
ci_info "environment option: \$CI_AR: '$CI_AR'"
ci_info "environment option: \$CI_RANLIB: '$CI_RANLIB'"
ci_info "environment option: \$CI_LD: '$CI_LD'"
ci_info "environment option: \$CI_LD_FLAGS: '$CI_LD_FLAGS'"
ci_info "environment option: \$CI_SANITIZERS: '$CI_SANITIZERS'"
ci_info "environment option: \$CI_NO_TEST: '$CI_NO_TEST'"
ci_info "environment option: \$CI_NO_INSTALL: '$CI_NO_INSTALL'"
ci_info "environment option: \$CI_NO_CLEAN: '$CI_NO_CLEAN'"
ci_info "executable: \$CI_MAKE: $(command -V "$CI_MAKE")"
[[ $CI_CC ]] &&
ci_info "executable: \$CI_CC: $(command -V "$CI_CC")"
[[ $CI_CPP ]] &&
ci_info "executable: \$CI_CPP: $(command -V "$CI_CPP")"
[[ $CI_AR ]] &&
ci_info "executable: \$CI_AR: $(command -V "$CI_AR")"
[[ $CI_RANLIB ]] &&
ci_info "executable: \$CI_RANLIB: $(command -V "$CI_RANLIB")"
[[ $CI_LD ]] &&
ci_info "executable: \$CI_LD: $(command -V "$CI_LD")"
ci_info "## END OF CONFIGURATION ##"
}
function ci_build_autotools {
ci_info "## START OF BUILD ##"
# Export the configure build environment.
[[ $CI_CC ]] && ci_spawn export CC="$CI_CC"
[[ $CI_CC_FLAGS ]] && ci_spawn export CFLAGS="$CI_CC_FLAGS"
[[ $CI_CPP ]] && ci_spawn export CPP="$CI_CPP"
[[ $CI_CPP_FLAGS ]] && ci_spawn export CPPFLAGS="$CI_CPP_FLAGS"
[[ $CI_AR ]] && ci_spawn export AR="$CI_AR"
[[ $CI_RANLIB ]] && ci_spawn export RANLIB="$CI_RANLIB"
[[ $CI_LD ]] && ci_spawn export CPP="$CI_LD"
[[ $CI_LD_FLAGS ]] && ci_spawn export LDFLAGS="$CI_LD_FLAGS"
[[ $CI_SANITIZERS ]] && {
ci_spawn export CFLAGS="-fsanitize=$CI_SANITIZERS ${CFLAGS:-"-O2"}"
ci_spawn export LDFLAGS="-fsanitize=$CI_SANITIZERS $LDFLAGS"
}
# Build and install.
ci_spawn rm -fr "$CI_BUILDDIR" "$CI_INSTALLDIR"
ci_spawn mkdir -p "$CI_BUILDDIR"
ci_spawn cd "$CI_BUILDDIR"
ci_spawn "$CI_SRCDIR/configure" --prefix="$CI_INSTALLDIR" $CI_CONFIGURE_FLAGS
ci_spawn "$CI_MAKE" $CI_MAKE_FLAGS
[[ $CI_NO_TEST ]] || ci_spawn "$CI_MAKE" $CI_MAKE_FLAGS test
[[ $CI_NO_INSTALL ]] || ci_spawn "$CI_MAKE" $CI_MAKE_FLAGS install
[[ $CI_NO_CLEAN ]] || ci_spawn "$CI_MAKE" $CI_MAKE_FLAGS clean
[[ $CI_NO_CLEAN ]] || ci_spawn "$CI_MAKE" $CI_MAKE_FLAGS distclean
ci_info "## END OF BUILD ##"
}
ci_init_autotools
ci_trace_autotools
[[ $# -eq 0 ]] || {
ci_info "note: this program accepts environment options only"
ci_err "unexpected command arguments: '$*'"
}
ci_build_autotools

169
libpng/ci/ci_cmake.sh Normal file
View file

@ -0,0 +1,169 @@
#!/usr/bin/env bash
set -e
# ci_cmake.sh
# Continuously integrate libpng using CMake.
#
# Copyright (c) 2019-2022 Cosmin Truta.
#
# This software is released under the libpng license.
# For conditions of distribution and use, see the disclaimer
# and license in png.h.
CI_SCRIPTNAME="$(basename "$0")"
CI_SCRIPTDIR="$(cd "$(dirname "$0")" && pwd)"
CI_SRCDIR="$(dirname "$CI_SCRIPTDIR")"
CI_BUILDDIR="$CI_SRCDIR/out/cmake.build"
CI_INSTALLDIR="$CI_SRCDIR/out/cmake.install"
function ci_info {
printf >&2 "%s: %s\\n" "$CI_SCRIPTNAME" "$*"
}
function ci_err {
printf >&2 "%s: error: %s\\n" "$CI_SCRIPTNAME" "$*"
exit 2
}
function ci_spawn {
printf >&2 "%s: executing:" "$CI_SCRIPTNAME"
printf >&2 " %q" "$@"
printf >&2 "\\n"
"$@"
}
function ci_init_cmake {
CI_SYSTEM_NAME="$(uname -s)"
CI_MACHINE_NAME="$(uname -m)"
CI_CMAKE="${CI_CMAKE:-cmake}"
CI_CTEST="${CI_CTEST:-ctest}"
CI_CMAKE_BUILD_TYPE="${CI_CMAKE_BUILD_TYPE:-Release}"
[[ -x $(command -v ninja) ]] && CI_CMAKE_GENERATOR="${CI_CMAKE_GENERATOR:-Ninja}"
if [[ $CI_CMAKE_GENERATOR == "Visual Studio"* ]]
then
# Initialize the CI_...DIR_NATIVE variables, for the benefit of
# the native Windows build tools. The regular CI_...DIR variables
# can only be used inside Bash-on-Windows.
mkdir -p "$CI_BUILDDIR"
mkdir -p "$CI_INSTALLDIR"
if [[ -x $CYGPATH ]]
then
CI_SRCDIR_NATIVE="$("$CYGPATH" -w "$CI_SRCDIR")"
CI_BUILDDIR_NATIVE="$("$CYGPATH" -w "$CI_BUILDDIR")"
CI_INSTALLDIR_NATIVE="$("$CYGPATH" -w "$CI_INSTALLDIR")"
else
CI_SRCDIR_NATIVE="$(cd "$CI_SRCDIR" ; pwd -W || pwd -P)"
CI_BUILDDIR_NATIVE="$(cd "$CI_BUILDDIR" ; pwd -W || pwd -P)"
CI_INSTALLDIR_NATIVE="$(cd "$CI_INSTALLDIR" ; pwd -W || pwd -P)"
fi
# Clean up incidental mixtures of Windows and Bash-on-Windows
# environment variables, to avoid confusing MSBuild.
[[ $TEMP && ( $Temp || $temp ) ]] && unset TEMP
[[ $TMP && ( $Tmp || $tmp ) ]] && unset TMP
# Ensure that CI_CMAKE_GENERATOR_PLATFORM is initialized for this generator.
[[ $CI_CMAKE_GENERATOR_PLATFORM ]] || ci_err "missing: \$CI_CMAKE_GENERATOR_PLATFORM"
fi
}
function ci_trace_cmake {
ci_info "## START OF CONFIGURATION ##"
ci_info "system name: $CI_SYSTEM_NAME"
ci_info "machine hardware name: $CI_MACHINE_NAME"
ci_info "source directory: $CI_SRCDIR"
[[ $CI_SRCDIR_NATIVE ]] &&
ci_info "source directory (native): $CI_SRCDIR_NATIVE"
ci_info "build directory: $CI_BUILDDIR"
[[ $CI_BUILDDIR_NATIVE ]] &&
ci_info "build directory (native): $CI_BUILDDIR_NATIVE"
ci_info "install directory: $CI_INSTALLDIR"
[[ $CI_INSTALLDIR_NATIVE ]] &&
ci_info "install directory (native): $CI_INSTALLDIR_NATIVE"
ci_info "environment option: \$CI_CMAKE: '$CI_CMAKE'"
ci_info "environment option: \$CI_CMAKE_GENERATOR: '$CI_CMAKE_GENERATOR'"
ci_info "environment option: \$CI_CMAKE_GENERATOR_PLATFORM: '$CI_CMAKE_GENERATOR_PLATFORM'"
ci_info "environment option: \$CI_CMAKE_BUILD_TYPE: '$CI_CMAKE_BUILD_TYPE'"
ci_info "environment option: \$CI_CMAKE_BUILD_FLAGS: '$CI_CMAKE_BUILD_FLAGS'"
ci_info "environment option: \$CI_CMAKE_VARS: '$CI_CMAKE_VARS'"
ci_info "environment option: \$CI_CTEST: '$CI_CTEST'"
ci_info "environment option: \$CI_CTEST_FLAGS: '$CI_CTEST_FLAGS'"
ci_info "environment option: \$CI_CC: '$CI_CC'"
ci_info "environment option: \$CI_CC_FLAGS: '$CI_CC_FLAGS'"
ci_info "environment option: \$CI_AR: '$CI_AR'"
ci_info "environment option: \$CI_RANLIB: '$CI_RANLIB'"
ci_info "environment option: \$CI_SANITIZERS: '$CI_SANITIZERS'"
ci_info "environment option: \$CI_NO_TEST: '$CI_NO_TEST'"
ci_info "environment option: \$CI_NO_INSTALL: '$CI_NO_INSTALL'"
ci_info "environment option: \$CI_NO_CLEAN: '$CI_NO_CLEAN'"
ci_info "executable: \$CI_CMAKE: $(command -V "$CI_CMAKE")"
ci_info "executable: \$CI_CTEST: $(command -V "$CI_CTEST")"
[[ $CI_CMAKE_GENERATOR == *"Ninja"* ]] &&
ci_info "executable: $(command -V ninja)"
[[ $CI_CC ]] &&
ci_info "executable: \$CI_CC: $(command -V "$CI_CC")"
[[ $CI_AR ]] &&
ci_info "executable: \$CI_AR: $(command -V "$CI_AR")"
[[ $CI_RANLIB ]] &&
ci_info "executable: \$CI_RANLIB: $(command -V "$CI_RANLIB")"
ci_info "## END OF CONFIGURATION ##"
}
function ci_build_cmake {
ci_info "## START OF BUILD ##"
ci_spawn "$(command -v "$CI_CMAKE")" --version
ci_spawn "$(command -v "$CI_CTEST")" --version
# Initialize ALL_CC_FLAGS as a string.
local ALL_CC_FLAGS="$CI_CC_FLAGS"
[[ $CI_SANITIZERS ]] && ALL_CC_FLAGS="-fsanitize=$CI_SANITIZERS $ALL_CC_FLAGS"
# Initialize ALL_CMAKE_VARS, ALL_CMAKE_BUILD_FLAGS and ALL_CTEST_FLAGS as arrays.
local -a ALL_CMAKE_VARS=()
[[ $CI_CC ]] && ALL_CMAKE_VARS+=(-DCMAKE_C_COMPILER="$CI_CC")
[[ $ALL_CC_FLAGS ]] && ALL_CMAKE_VARS+=(-DCMAKE_C_FLAGS="$ALL_CC_FLAGS")
[[ $CI_AR ]] && ALL_CMAKE_VARS+=(-DCMAKE_AR="$CI_AR")
[[ $CI_RANLIB ]] && ALL_CMAKE_VARS+=(-DCMAKE_RANLIB="$CI_RANLIB")
ALL_CMAKE_VARS+=(-DCMAKE_BUILD_TYPE="$CI_CMAKE_BUILD_TYPE")
ALL_CMAKE_VARS+=(-DCMAKE_VERBOSE_MAKEFILE=ON)
[[ $CI_NO_TEST ]] && ALL_CMAKE_VARS+=(-DPNG_TESTS=OFF)
ALL_CMAKE_VARS+=($CI_CMAKE_VARS)
local -a ALL_CMAKE_BUILD_FLAGS=($CI_CMAKE_BUILD_FLAGS)
local -a ALL_CTEST_FLAGS=($CI_CTEST_FLAGS)
# Initialize SRCDIR_NATIVE and INSTALLDIR_NATIVE.
local SRCDIR_NATIVE="${CI_SRCDIR_NATIVE:-"$CI_SRCDIR"}"
local INSTALLDIR_NATIVE="${CI_INSTALLDIR_NATIVE:-"$CI_INSTALLDIR"}"
# Export the CMake environment variables.
[[ $CI_CMAKE_GENERATOR ]] &&
ci_spawn export CMAKE_GENERATOR="$CI_CMAKE_GENERATOR"
[[ $CI_CMAKE_GENERATOR_PLATFORM ]] &&
ci_spawn export CMAKE_GENERATOR_PLATFORM="$CI_CMAKE_GENERATOR_PLATFORM"
# Build and install.
ci_spawn rm -fr "$CI_BUILDDIR" "$CI_INSTALLDIR"
ci_spawn mkdir -p "$CI_BUILDDIR"
ci_spawn cd "$CI_BUILDDIR"
ci_spawn "$CI_CMAKE" "${ALL_CMAKE_VARS[@]}" \
-DCMAKE_INSTALL_PREFIX="$INSTALLDIR_NATIVE" \
"$SRCDIR_NATIVE"
ci_spawn "$CI_CMAKE" --build . \
--config "$CI_CMAKE_BUILD_TYPE" \
"${ALL_CMAKE_BUILD_FLAGS[@]}"
[[ $CI_NO_TEST ]] ||
ci_spawn "$CI_CTEST" --build-config "$CI_CMAKE_BUILD_TYPE" \
"${ALL_CTEST_FLAGS[@]}"
[[ $CI_NO_INSTALL ]] ||
ci_spawn "$CI_CMAKE" --build . \
--config "$CI_CMAKE_BUILD_TYPE" \
--target install \
"${ALL_CMAKE_BUILD_FLAGS[@]}"
[[ $CI_NO_CLEAN ]] ||
ci_spawn "$CI_CMAKE" --build . \
--config "$CI_CMAKE_BUILD_TYPE" \
--target clean \
"${ALL_CMAKE_BUILD_FLAGS[@]}"
ci_info "## END OF BUILD ##"
}
ci_init_cmake
ci_trace_cmake
[[ $# -eq 0 ]] || {
ci_info "note: this program accepts environment options only"
ci_err "unexpected command arguments: '$*'"
}
ci_build_cmake

147
libpng/ci/ci_legacy.sh Normal file
View file

@ -0,0 +1,147 @@
#!/usr/bin/env bash
set -e
# ci_legacy.sh
# Continuously integrate libpng using the legacy makefiles.
#
# Copyright (c) 2019-2022 Cosmin Truta.
#
# This software is released under the libpng license.
# For conditions of distribution and use, see the disclaimer
# and license in png.h.
CI_SCRIPTNAME="$(basename "$0")"
CI_SCRIPTDIR="$(cd "$(dirname "$0")" && pwd)"
CI_SRCDIR="$(dirname "$CI_SCRIPTDIR")"
CI_BUILDDIR="$CI_SRCDIR"
function ci_info {
printf >&2 "%s: %s\\n" "$CI_SCRIPTNAME" "$*"
}
function ci_err {
printf >&2 "%s: error: %s\\n" "$CI_SCRIPTNAME" "$*"
exit 2
}
function ci_spawn {
printf >&2 "%s: executing:" "$CI_SCRIPTNAME"
printf >&2 " %q" "$@"
printf >&2 "\\n"
"$@"
}
function ci_init_legacy {
CI_SYSTEM_NAME="$(uname -s)"
CI_MACHINE_NAME="$(uname -m)"
CI_MAKE="${CI_MAKE:-make}"
case "$CI_SYSTEM_NAME" in
( Darwin | *BSD | DragonFly )
[[ -x $(command -v clang) ]] && CI_CC="${CI_CC:-clang}" ;;
( * )
[[ -x $(command -v gcc) ]] && CI_CC="${CI_CC:-gcc}" ;;
esac
CI_CC="${CI_CC:-cc}"
case "$CI_CC" in
( *clang* )
CI_LEGACY_MAKEFILES="${CI_LEGACY_MAKEFILES:-"scripts/makefile.clang"}" ;;
( *gcc* )
CI_LEGACY_MAKEFILES="${CI_LEGACY_MAKEFILES:-"scripts/makefile.gcc"}" ;;
( cc | c89 | c99 )
CI_LEGACY_MAKEFILES="${CI_LEGACY_MAKEFILES:-"scripts/makefile.std"}" ;;
esac
CI_LD="${CI_LD:-"$CI_CC"}"
CI_LIBS="${CI_LIBS:-"-lz -lm"}"
}
function ci_trace_legacy {
ci_info "## START OF CONFIGURATION ##"
ci_info "system name: $CI_SYSTEM_NAME"
ci_info "machine hardware name: $CI_MACHINE_NAME"
ci_info "source directory: $CI_SRCDIR"
ci_info "build directory: $CI_BUILDDIR"
ci_info "environment option: \$CI_LEGACY_MAKEFILES: '$CI_LEGACY_MAKEFILES'"
ci_info "environment option: \$CI_MAKE: '$CI_MAKE'"
ci_info "environment option: \$CI_MAKE_FLAGS: '$CI_MAKE_FLAGS'"
ci_info "environment option: \$CI_MAKE_VARS: '$CI_MAKE_VARS'"
ci_info "environment option: \$CI_CC: '$CI_CC'"
ci_info "environment option: \$CI_CC_FLAGS: '$CI_CC_FLAGS'"
ci_info "environment option: \$CI_CPP: '$CI_CPP'"
ci_info "environment option: \$CI_CPP_FLAGS: '$CI_CPP_FLAGS'"
ci_info "environment option: \$CI_AR: '$CI_AR'"
ci_info "environment option: \$CI_RANLIB: '$CI_RANLIB'"
ci_info "environment option: \$CI_LD: '$CI_LD'"
ci_info "environment option: \$CI_LD_FLAGS: '$CI_LD_FLAGS'"
ci_info "environment option: \$CI_LIBS: '$CI_LIBS'"
ci_info "environment option: \$CI_SANITIZERS: '$CI_SANITIZERS'"
ci_info "environment option: \$CI_NO_TEST: '$CI_NO_TEST'"
ci_info "environment option: \$CI_NO_CLEAN: '$CI_NO_CLEAN'"
ci_info "executable: \$CI_MAKE: $(command -V "$CI_MAKE")"
[[ $CI_CC ]] &&
ci_info "executable: \$CI_CC: $(command -V "$CI_CC")"
[[ $CI_CPP ]] &&
ci_info "executable: \$CI_CPP: $(command -V "$CI_CPP")"
[[ $CI_AR ]] &&
ci_info "executable: \$CI_AR: $(command -V "$CI_AR")"
[[ $CI_RANLIB ]] &&
ci_info "executable: \$CI_RANLIB: $(command -V "$CI_RANLIB")"
[[ $CI_LD ]] &&
ci_info "executable: \$CI_LD: $(command -V "$CI_LD")"
ci_info "## END OF CONFIGURATION ##"
}
function ci_build_legacy {
ci_info "## START OF BUILD ##"
# Initialize ALL_CC_FLAGS and ALL_LD_FLAGS as strings.
local ALL_CC_FLAGS="$CI_CC_FLAGS"
local ALL_LD_FLAGS="$CI_LD_FLAGS"
[[ $CI_SANITIZERS ]] && {
ALL_CC_FLAGS="-fsanitize=$CI_SANITIZERS ${ALL_CC_FLAGS:-"-O2"}"
ALL_LD_FLAGS="-fsanitize=$CI_SANITIZERS $ALL_LD_FLAGS"
}
# Initialize ALL_MAKE_FLAGS and ALL_MAKE_VARS as arrays.
local -a ALL_MAKE_FLAGS=($CI_MAKE_FLAGS)
local -a ALL_MAKE_VARS=()
[[ $CI_CC ]] && ALL_MAKE_VARS+=(CC="$CI_CC")
[[ $ALL_CC_FLAGS ]] && ALL_MAKE_VARS+=(CFLAGS="$ALL_CC_FLAGS")
[[ $CI_CPP ]] && ALL_MAKE_VARS+=(CPP="$CI_CPP")
[[ $CI_CPP_FLAGS ]] && ALL_MAKE_VARS+=(CPPFLAGS="$CI_CPP_FLAGS")
[[ $CI_AR ]] && ALL_MAKE_VARS+=(
AR="${CI_AR:-ar}"
AR_RC="${CI_AR:-ar} rc"
)
[[ $CI_RANLIB ]] && ALL_MAKE_VARS+=(RANLIB="$CI_RANLIB")
[[ $CI_LD ]] && ALL_MAKE_VARS+=(LD="$CI_LD")
[[ $ALL_LD_FLAGS ]] && ALL_MAKE_VARS+=(LDFLAGS="$ALL_LD_FLAGS")
ALL_MAKE_VARS+=(LIBS="$CI_LIBS")
ALL_MAKE_VARS+=($CI_MAKE_VARS)
# Build!
ci_spawn cd "$CI_SRCDIR"
local MY_MAKEFILE
for MY_MAKEFILE in $CI_LEGACY_MAKEFILES
do
ci_info "using makefile: $MY_MAKEFILE"
ci_spawn "$CI_MAKE" -f "$MY_MAKEFILE" \
"${ALL_MAKE_FLAGS[@]}" \
"${ALL_MAKE_VARS[@]}"
[[ $CI_NO_TEST ]] ||
ci_spawn "$CI_MAKE" -f "$MY_MAKEFILE" \
"${ALL_MAKE_FLAGS[@]}" \
"${ALL_MAKE_VARS[@]}" \
test
[[ $CI_NO_CLEAN ]] ||
ci_spawn "$CI_MAKE" -f "$MY_MAKEFILE" \
"${ALL_MAKE_FLAGS[@]}" \
"${ALL_MAKE_VARS[@]}" \
clean
done
ci_info "## END OF BUILD ##"
}
ci_init_legacy
ci_trace_legacy
[[ $# -eq 0 ]] || {
ci_info "note: this program accepts environment options only"
ci_err "unexpected command arguments: '$*'"
}
ci_build_legacy

View file

@ -3,7 +3,7 @@
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1999-2018 Free Software Foundation, Inc.
# Copyright (C) 1999-2021 Free Software Foundation, Inc.
# Written by Tom Tromey <tromey@cygnus.com>.
#
# This program is free software; you can redistribute it and/or modify
@ -53,7 +53,7 @@ func_file_conv ()
MINGW*)
file_conv=mingw
;;
CYGWIN*)
CYGWIN* | MSYS*)
file_conv=cygwin
;;
*)
@ -67,7 +67,7 @@ func_file_conv ()
mingw/*)
file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
;;
cygwin/*)
cygwin/* | msys/*)
file=`cygpath -m "$file" || echo "$file"`
;;
wine/*)

1486
libpng/config.guess vendored

File diff suppressed because it is too large Load diff

View file

@ -15,15 +15,15 @@
/* Define to 1 if you have the `z' library (-lz). */
#undef HAVE_LIBZ
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the `pow' function. */
#undef HAVE_POW
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdio.h> header file. */
#undef HAVE_STDIO_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
@ -96,7 +96,9 @@
/* Enable POWERPC VSX optimizations */
#undef PNG_POWERPC_VSX_OPT
/* Define to 1 if you have the ANSI C header files. */
/* Define to 1 if all of the C90 standard headers exist (not just the ones
required in a freestanding environment). This macro is provided for
backward compatibility; new code need not use it. */
#undef STDC_HEADERS
/* Define to 1 if your <sys/time.h> declares `struct tm'. */
@ -105,22 +107,17 @@
/* Version number of package */
#undef VERSION
/* Define to empty if `const' does not conform to ANSI C. */
#undef const
/* Define to the equivalent of the C99 'restrict' keyword, or to
nothing if this is not supported. Do not define if restrict is
supported directly. */
supported only directly. */
#undef restrict
/* Work around a bug in Sun C++: it does not support _Restrict or
__restrict__, even though the corresponding Sun C compiler ends up with
"#define restrict _Restrict" or "#define restrict __restrict__" in the
previous line. Perhaps some future version of Sun C++ will work with
restrict; if so, hopefully it defines __RESTRICT like Sun C does. */
#if defined __SUNPRO_CC && !defined __RESTRICT
/* Work around a bug in older versions of Sun C++, which did not
#define __restrict__ or support _Restrict or __restrict__
even though the corresponding Sun C compiler ended up with
"#define restrict _Restrict" or "#define restrict __restrict__"
in the previous line. This workaround can be removed once
we assume Oracle Developer Studio 12.5 (2016) or later. */
#if defined __SUNPRO_CC && !defined __RESTRICT && !defined __restrict__
# define _Restrict
# define __restrict__
#endif
/* Define to `unsigned int' if <sys/types.h> does not define. */
#undef size_t

2845
libpng/config.sub vendored

File diff suppressed because it is too large Load diff

5978
libpng/configure vendored

File diff suppressed because it is too large Load diff

View file

@ -1,6 +1,6 @@
# configure.ac
# Copyright (c) 2018 Cosmin Truta
# Copyright (c) 2018-2022 Cosmin Truta
# Copyright (c) 2004-2016 Glenn Randers-Pehrson
# This code is released under the libpng license.
@ -25,7 +25,7 @@ AC_PREREQ([2.68])
dnl Version number stuff here:
AC_INIT([libpng],[1.6.37],[png-mng-implement@lists.sourceforge.net])
AC_INIT([libpng],[1.6.38],[png-mng-implement@lists.sourceforge.net])
AC_CONFIG_MACRO_DIR([scripts])
# libpng does not follow GNU file name conventions (hence 'foreign')
@ -46,10 +46,10 @@ dnl automake, so the following is not necessary (and is not defined anyway):
dnl AM_PREREQ([1.11.2])
dnl stop configure from automagically running automake
PNGLIB_VERSION=1.6.37
PNGLIB_VERSION=1.6.38
PNGLIB_MAJOR=1
PNGLIB_MINOR=6
PNGLIB_RELEASE=37
PNGLIB_RELEASE=38
dnl End of version number stuff
@ -89,9 +89,9 @@ fi
DFNCPP="$CPP"
AC_SUBST(DFNCPP)
# -Werror cannot be passed to GCC in CFLAGS because configure will fail (it
# checks the compiler with a program that generates a warning), add the
# following option to deal with this
# -Werror cannot be passed to GCC in CFLAGS because configure will fail
# (it checks the compiler with a program that generates a warning).
# Add the following option to deal with this:
AC_ARG_VAR(PNG_COPTS,
[additional flags for the C compiler, use this for options that would]
[cause configure itself to fail])
@ -114,10 +114,10 @@ AC_ARG_ENABLE(werror,
CFLAGS="$sav_CFLAGS"
fi],)
# For GCC 5 the default mode for C is -std=gnu11 instead of -std=gnu89
# In pngpriv.h we request just the POSIX 1003.1 and C89 APIs by defining _POSIX_SOURCE to 1
# This is incompatible with the new default mode, so we test for that and force the
# "-std=c89" compiler option:
# For GCC 5 the default mode for C is -std=gnu11 instead of -std=gnu89.
# In pngpriv.h we request just the POSIX 1003.1 and C89 APIs by defining
# _POSIX_SOURCE to 1. This is incompatible with the new default mode, so
# we test for that and force the "-std=c89" compiler option:
AC_MSG_CHECKING([if we need to force back C standard to C89])
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM([
@ -133,22 +133,16 @@ AC_COMPILE_IFELSE(
CFLAGS="$CFLAGS -std=c89"
])
# Checks for header files.
AC_HEADER_STDC
# Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_TYPE_SIZE_T
# Checks for structures and compiler characteristics.
AC_STRUCT_TM
AC_C_RESTRICT
# Checks for library functions.
AC_FUNC_STRTOD
AC_CHECK_FUNCS([pow], , AC_CHECK_LIB(m, pow, , AC_MSG_ERROR(cannot find pow)) )
AC_CHECK_FUNCS([pow], , AC_CHECK_LIB(m, pow, , AC_MSG_ERROR(cannot find pow)))
# Some later POSIX 1003.1 functions are required for test programs, failure here
# is soft (the corresponding test program is not built).
AC_CHECK_FUNC([clock_gettime],,[AC_MSG_WARN([not building timepng])])
# Some later POSIX 1003.1 functions are required for test programs, failure
# here is soft (the corresponding test program is not built).
AC_CHECK_FUNC([clock_gettime], , [AC_MSG_WARN([not building timepng])])
AM_CONDITIONAL([HAVE_CLOCK_GETTIME], [test "$ac_cv_func_clock_gettime" = "yes"])
AC_ARG_WITH(zlib-prefix,
@ -296,7 +290,7 @@ AC_ARG_ENABLE([unversioned-libpng-config],
AM_CONDITIONAL([DO_INSTALL_LIBPNG_CONFIG],
[test "$enable_unversioned_libpng_config" != "no"])
# HOST SPECIFIC OPTIONS
# HOST-SPECIFIC OPTIONS
# =====================
#
# DEFAULT
@ -326,12 +320,12 @@ AC_ARG_ENABLE([hardware-optimizations],
case "$host_cpu" in
arm*|aarch64*)
enable_arm_neon=yes
AC_DEFINE([PNG_ARM_NEON_OPT], [0],
AC_DEFINE([PNG_ARM_NEON_OPT], [2],
[Enable ARM_NEON optimizations])
;;
mipsel*|mips64el*)
enable_mips_msa=yes
AC_DEFINE([PNG_MIPS_MSA_OPT], [0],
AC_DEFINE([PNG_MIPS_MSA_OPT], [2],
[Enable MIPS_MSA optimizations])
;;
i?86|x86_64)
@ -366,7 +360,7 @@ AC_ARG_ENABLE([arm-neon],
AC_DEFINE([PNG_ARM_NEON_OPT], [0],
[Disable ARM Neon optimizations])
# Prevent inclusion of the assembler files below:
enable_arm_neon=no;;
enable_arm_neon=no ;;
check)
AC_DEFINE([PNG_ARM_NEON_CHECK_SUPPORTED], [],
[Check for ARM Neon support at run-time]);;
@ -383,19 +377,19 @@ AC_ARG_ENABLE([arm-neon],
AC_MSG_ERROR([--enable-arm-neon=${enable_arm_neon}: invalid value])
esac])
# Add ARM specific files to all builds where the host_cpu is arm ('arm*') or
# where ARM optimizations were explicitly requested (this allows a fallback if a
# future host CPU does not match 'arm*')
# Add ARM-specific files to all builds where $host_cpu is arm ('arm*') or
# where ARM optimizations were explicitly requested (this allows a fallback
# if a future host CPU does not match 'arm*')
AM_CONDITIONAL([PNG_ARM_NEON],
[test "$enable_arm_neon" != 'no' &&
case "$host_cpu" in
arm*|aarch64*) :;;
*) test "$enable_arm_neon" != '';;
arm*|aarch64*) : ;;
*) test "$enable_arm_neon" != '' ;;
esac])
# MIPS
# ===
# ====
#
# MIPS MSA (SIMD) support.
@ -412,7 +406,7 @@ AC_ARG_ENABLE([mips-msa],
AC_DEFINE([PNG_MIPS_MSA_OPT], [0],
[Disable MIPS MSA optimizations])
# Prevent inclusion of the assembler files below:
enable_mips_msa=no;;
enable_mips_msa=no ;;
check)
AC_DEFINE([PNG_MIPS_MSA_CHECK_SUPPORTED], [],
[Check for MIPS MSA support at run-time]);;
@ -429,14 +423,14 @@ AC_ARG_ENABLE([mips-msa],
AC_MSG_ERROR([--enable-mips-msa=${enable_mips_msa}: invalid value])
esac])
# Add MIPS specific files to all builds where the host_cpu is mips ('mips*') or
# where MIPS optimizations were explicitly requested (this allows a fallback if a
# future host CPU does not match 'mips*')
# Add MIPS-specific files to all builds where $host_cpu is mips ('mips*') or
# where MIPS optimizations were explicitly requested (this allows a fallback
# if a future host CPU does not match 'mips*')
AM_CONDITIONAL([PNG_MIPS_MSA],
[test "$enable_mips_msa" != 'no' &&
case "$host_cpu" in
mipsel*|mips64el*) :;;
mipsel*|mips64el*) : ;;
esac])
# INTEL
@ -456,7 +450,7 @@ AC_ARG_ENABLE([intel-sse],
AC_DEFINE([PNG_INTEL_SSE_OPT], [0],
[Disable Intel SSE optimizations])
# Prevent inclusion of the assembler files below:
enable_intel_sse=no;;
enable_intel_sse=no ;;
yes|on)
AC_DEFINE([PNG_INTEL_SSE_OPT], [1],
[Enable Intel SSE optimizations]);;
@ -464,18 +458,18 @@ AC_ARG_ENABLE([intel-sse],
AC_MSG_ERROR([--enable-intel-sse=${enable_intel_sse}: invalid value])
esac])
# Add Intel specific files to all builds where the host_cpu is Intel ('x86*')
# or where Intel optimizations were explicitly requested (this allows a
# fallback if a future host CPU does not match 'x86*')
# Add Intel-specific files to all builds where $host_cpu is Intel ('x86*') or
# where Intel optimizations were explicitly requested (this allows a fallback
# if a future host CPU does not match 'x86*')
AM_CONDITIONAL([PNG_INTEL_SSE],
[test "$enable_intel_sse" != 'no' &&
case "$host_cpu" in
i?86|x86_64) :;;
*) test "$enable_intel_sse" != '';;
i?86|x86_64) : ;;
*) test "$enable_intel_sse" != '' ;;
esac])
# PowerPC
# ===
# =======
#
# PowerPC VSX (SIMD) support.
@ -491,8 +485,8 @@ AS_HELP_STRING([[[--enable-powerpc-vsx]]],
# disable the default enabling on __ppc64__ systems:
AC_DEFINE([PNG_POWERPC_VSX_OPT], [0],
[Disable POWERPC VSX optimizations])
# Prevent inclusion of the platform specific files below:
enable_powerpc_vsx=no;;
# Prevent inclusion of the platform-specific files below:
enable_powerpc_vsx=no ;;
check)
AC_DEFINE([PNG_POWERPC_VSX_CHECK_SUPPORTED], [],
[Check for POWERPC VSX support at run-time])
@ -506,22 +500,21 @@ AS_HELP_STRING([[[--enable-powerpc-vsx]]],
[Enable POWERPC VSX optimizations])
AC_MSG_WARN([--enable-powerpc-vsx: please specify 'check' or 'api', if]
[you want the optimizations unconditionally pass '-maltivec -mvsx']
[or '-mcpu=power8'to the compiler.]);;
[or '-mcpu=power8' to the compiler.]);;
*)
AC_MSG_ERROR([--enable-powerpc-vsx=${enable_powerpc_vsx}: invalid value])
esac])
# Add PowerPC specific files to all builds where the host_cpu is powerpc('powerpc*') or
# where POWERPC optimizations were explicitly requested (this allows a fallback if a
# future host CPU does not match 'powerpc*')
# Add PowerPC-specific files to all builds where $host_cpu is powerpc('powerpc*')
# or where PowerPC optimizations were explicitly requested (this allows a fallback
# if a future host CPU does not match 'powerpc*')
AM_CONDITIONAL([PNG_POWERPC_VSX],
[test "$enable_powerpc_vsx" != 'no' &&
case "$host_cpu" in
powerpc*|ppc64*) :;;
powerpc*|ppc64*) : ;;
esac])
AC_MSG_NOTICE([[Extra options for compiler: $PNG_COPTS]])
# Config files, substituting as above

View file

@ -2,8 +2,6 @@
#
# Copyright (c) 2013 John Cunningham Bowler
#
# Last changed in libpng 1.6.0 [February 14, 2013]
#
# This code is released under the libpng license.
# For conditions of distribution and use, see the disclaimer
# and license in png.h

View file

@ -3,8 +3,6 @@
/* Copyright: */
#define COPYRIGHT "\251 2013,2015 John Cunningham Bowler"
/*
* Last changed in libpng 1.6.20 [November 24, 2015]
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
* and license in png.h
@ -299,25 +297,28 @@ generate_palette(png_colorp palette, png_bytep trans, int bit_depth,
unsigned int x, y;
volatile unsigned int ip = 0;
for (x=0; x<size; ++x) for (y=0; y<size; ++y)
for (x=0; x<size; ++x)
{
ip = x + (size * y);
for (y=0; y<size; ++y)
{
ip = x + (size * y);
/* size is at most 16, so the scaled value below fits in 16 bits
*/
# define interp(pos, c1, c2) ((pos * c1) + ((size-pos) * c2))
# define xyinterp(x, y, c1, c2, c3, c4) (((size * size / 2) +\
(interp(x, c1, c2) * y + (size-y) * interp(x, c3, c4))) /\
(size*size))
/* size is at most 16, so the scaled value below fits in 16 bits
*/
# define interp(pos, c1, c2) ((pos * c1) + ((size-pos) * c2))
# define xyinterp(x, y, c1, c2, c3, c4) (((size * size / 2) +\
(interp(x, c1, c2) * y + (size-y) * interp(x, c3, c4))) /\
(size*size))
set_color(palette+ip, trans+ip,
/* color: green, red,blue,white */
xyinterp(x, y, 0, 255, 0, 255),
xyinterp(x, y, 255, 0, 0, 255),
xyinterp(x, y, 0, 0, 255, 255),
/* alpha: 0, 102, 204, 255) */
xyinterp(x, y, 0, 102, 204, 255),
gamma_table);
set_color(palette+ip, trans+ip,
/* color: green, red,blue,white */
xyinterp(x, y, 0, 255, 0, 255),
xyinterp(x, y, 255, 0, 0, 255),
xyinterp(x, y, 0, 0, 255, 255),
/* alpha: 0, 102, 204, 255) */
xyinterp(x, y, 0, 102, 204, 255),
gamma_table);
}
}
return ip+1;
@ -396,7 +397,7 @@ generate_row(png_bytep row, size_t rowbytes, unsigned int y, int color_type,
image_size_of_type(color_type, bit_depth, colors, small)-1;
png_uint_32 depth_max = (1U << bit_depth)-1; /* up to 65536 */
if (colors[0] == 0) if (small)
if (colors[0] == 0 && small)
{
unsigned int pixel_depth = pixel_depth_of_type(color_type, bit_depth);
@ -858,10 +859,13 @@ write_png(const char **name, FILE *fp, int color_type, int bit_depth,
{
unsigned int i;
if (real_gamma == 45455) for (i=0; i<256; ++i)
if (real_gamma == 45455)
{
gamma_table[i] = (png_byte)i;
conv = 1.;
for (i=0; i<256; ++i)
{
gamma_table[i] = (png_byte)i;
conv = 1.;
}
}
else
@ -1430,10 +1434,13 @@ find_parameters(png_const_charp what, png_charp param, png_charp *list,
for (i=0; *param && i<nparams; ++i)
{
list[i] = param;
while (*++param) if (*param == '\n' || *param == ':')
while (*++param)
{
*param++ = 0; /* Terminate last parameter */
break; /* And start a new one. */
if (*param == '\n' || *param == ':')
{
*param++ = 0; /* Terminate last parameter */
break; /* And start a new one. */
}
}
}
@ -1869,7 +1876,7 @@ main(int argc, char **argv)
}
}
/* small and colors are incomparible (will probably crash if both are used at
/* small and colors are incompatible (will probably crash if both are used at
* the same time!)
*/
if (small && colors[0] != 0)

View file

@ -1,9 +1,9 @@
/* pngimage.c
*
* Copyright (c) 2021 Cosmin Truta
* Copyright (c) 2015,2016 John Cunningham Bowler
*
* Last changed in libpng 1.6.24 [August 4, 2016]
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
* and license in png.h
@ -12,6 +12,7 @@
* using png_read_png and then write with png_write_png. Test all possible
* transforms.
*/
#include <stdarg.h>
#include <stdlib.h>
#include <string.h>
@ -317,11 +318,10 @@ transform_name(int t)
t &= -t; /* first set bit */
for (i=0; i<TTABLE_SIZE; ++i) if (transform_info[i].name != NULL)
{
if ((transform_info[i].transform & t) != 0)
return transform_info[i].name;
}
for (i=0; i<TTABLE_SIZE; ++i)
if (transform_info[i].name != NULL)
if ((transform_info[i].transform & t) != 0)
return transform_info[i].name;
return "invalid transform";
}
@ -338,13 +338,16 @@ validate_T(void)
{
unsigned int i;
for (i=0; i<TTABLE_SIZE; ++i) if (transform_info[i].name != NULL)
for (i=0; i<TTABLE_SIZE; ++i)
{
if (transform_info[i].when & TRANSFORM_R)
read_transforms |= transform_info[i].transform;
if (transform_info[i].name != NULL)
{
if (transform_info[i].when & TRANSFORM_R)
read_transforms |= transform_info[i].transform;
if (transform_info[i].when & TRANSFORM_W)
write_transforms |= transform_info[i].transform;
if (transform_info[i].when & TRANSFORM_W)
write_transforms |= transform_info[i].transform;
}
}
/* Reversible transforms are those which are supported on both read and
@ -962,21 +965,24 @@ update_display(struct display *dp)
int bd = dp->bit_depth;
unsigned int i;
for (i=0; i<TTABLE_SIZE; ++i) if (transform_info[i].name != NULL)
for (i=0; i<TTABLE_SIZE; ++i)
{
int transform = transform_info[i].transform;
if (transform_info[i].name != NULL)
{
int transform = transform_info[i].transform;
if ((transform_info[i].valid_chunks == 0 ||
(transform_info[i].valid_chunks & chunks) != 0) &&
(transform_info[i].color_mask_required & ct) ==
transform_info[i].color_mask_required &&
(transform_info[i].color_mask_absent & ct) == 0 &&
(transform_info[i].bit_depths & bd) != 0 &&
(transform_info[i].when & TRANSFORM_R) != 0)
active |= transform;
if ((transform_info[i].valid_chunks == 0 ||
(transform_info[i].valid_chunks & chunks) != 0) &&
(transform_info[i].color_mask_required & ct) ==
transform_info[i].color_mask_required &&
(transform_info[i].color_mask_absent & ct) == 0 &&
(transform_info[i].bit_depths & bd) != 0 &&
(transform_info[i].when & TRANSFORM_R) != 0)
active |= transform;
else if ((transform_info[i].when & TRANSFORM_R) != 0)
inactive |= transform;
else if ((transform_info[i].when & TRANSFORM_R) != 0)
inactive |= transform;
}
}
/* Some transforms appear multiple times in the table; the 'active' status
@ -1000,8 +1006,9 @@ compare_read(struct display *dp, int applied_transforms)
int interlace_method, compression_method, filter_method;
const char *e = NULL;
png_get_IHDR(dp->read_pp, dp->read_ip, &width, &height, &bit_depth,
&color_type, &interlace_method, &compression_method, &filter_method);
if (!png_get_IHDR(dp->read_pp, dp->read_ip, &width, &height, &bit_depth,
&color_type, &interlace_method, &compression_method, &filter_method))
display_log(dp, LIBPNG_BUG, "png_get_IHDR failed");
# define C(item) if (item != dp->item) \
display_log(dp, APP_WARNING, "IHDR " #item "(%lu) changed to %lu",\
@ -1081,8 +1088,9 @@ compare_read(struct display *dp, int applied_transforms)
size_t x;
/* Find the first error */
for (x=0; x<rowbytes-1; ++x) if (row[x] != orig[x])
break;
for (x=0; x<rowbytes-1; ++x)
if (row[x] != orig[x])
break;
display_log(dp, APP_FAIL,
"byte(%lu,%lu) changed 0x%.2x -> 0x%.2x",
@ -1137,6 +1145,7 @@ compare_read(struct display *dp, int applied_transforms)
display_log(dp, LIBPNG_ERROR, "invalid colour type %d",
color_type);
/*NOTREACHED*/
memset(sig_bits, 0, sizeof(sig_bits));
bpp = 0;
break;
}
@ -1198,7 +1207,7 @@ compare_read(struct display *dp, int applied_transforms)
sig_bits[0] = (png_byte)b;
break;
case 4: /* Relicate twice */
case 4: /* Replicate twice */
/* Value is 1, 2, 3 or 4 */
b = 0xf & ((0xf << 4) >> sig_bits[0]);
b |= b << 4;
@ -1686,8 +1695,9 @@ main(int argc, char **argv)
printf("%s: pngimage ", pass ? "PASS" : "FAIL");
for (j=1; j<option_end; ++j) if (j != ilog)
printf("%s ", argv[j]);
for (j=1; j<option_end; ++j)
if (j != ilog)
printf("%s ", argv[j]);
printf("%s\n", d.filename);
}

View file

@ -1,7 +1,7 @@
/*-
* pngstest.c
/* pngstest.c
*
* Last changed in libpng 1.6.31 [July 27, 2017]
* Copyright (c) 2021 Cosmin Truta
* Copyright (c) 2013-2017 John Cunningham Bowler
*
* This code is released under the libpng license.
@ -10,8 +10,9 @@
*
* Test for the PNG 'simplified' APIs.
*/
#define _ISOC90_SOURCE 1
#define MALLOC_CHECK_ 2/*glibc facility: turn on debugging*/
#define MALLOC_CHECK_ 2 /*glibc facility: turn on debugging*/
#include <stddef.h>
#include <stdlib.h>
@ -2701,7 +2702,7 @@ compare_two_images(Image *a, Image *b, int via_linear,
{
if ((a->opts & ACCUMULATE) == 0)
{
char pindex[9];
char pindex[16];
sprintf(pindex, "%lu[%lu]", (unsigned long)y,
(unsigned long)a->image.colormap_entries);
logerror(a, a->file_name, ": bad pixel index: ", pindex);
@ -2712,12 +2713,12 @@ compare_two_images(Image *a, Image *b, int via_linear,
else if (y >= b->image.colormap_entries)
{
if ((b->opts & ACCUMULATE) == 0)
{
char pindex[9];
{
char pindex[16];
sprintf(pindex, "%lu[%lu]", (unsigned long)y,
(unsigned long)b->image.colormap_entries);
logerror(b, b->file_name, ": bad pixel index: ", pindex);
}
}
result = 0;
}
@ -2820,8 +2821,11 @@ compare_two_images(Image *a, Image *b, int via_linear,
bchannels = component_loc(bloc, formatb);
/* Hence the btoa array. */
for (i=0; i<4; ++i) if (bloc[i] < 4)
btoa[bloc[i]] = aloc[i]; /* may be '4' for alpha */
for (i=0; i<4; ++i)
{
if (bloc[i] < 4)
btoa[bloc[i]] = aloc[i]; /* may be '4' for alpha */
}
if (alpha_added)
alpha_added = bloc[0]; /* location of alpha channel in image b */
@ -3209,10 +3213,10 @@ write_one_file(Image *output, Image *image, int convert_to_8bit)
else if (image->opts & USE_FILE)
{
#ifdef PNG_SIMPLIFIED_WRITE_STDIO_SUPPORTED
static int counter = 0;
static unsigned int counter = 0;
char name[32];
sprintf(name, "%s%d.png", tmpf, ++counter);
sprintf(name, "%s%u.png", tmpf, ++counter);
if (png_image_write_to_file(&image->image, name, convert_to_8bit,
image->buffer+16, (png_int_32)image->stride, image->colormap))

View file

@ -1,7 +1,7 @@
/* pngunknown.c - test the read side unknown chunk handling
*
* Last changed in libpng 1.6.32 [August 24, 2017]
* Copyright (c) 2021 Cosmin Truta
* Copyright (c) 2015,2017 Glenn Randers-Pehrson
* Written by John Cunningham Bowler
*
@ -370,7 +370,9 @@ find_by_flag(png_uint_32 flag)
{
int i = NINFO;
while (--i >= 0) if (chunk_info[i].flag == flag) return i;
while (--i >= 0)
if (chunk_info[i].flag == flag)
return i;
fprintf(stderr, "pngunknown: internal error\n");
exit(4);
@ -547,27 +549,30 @@ read_callback(png_structp pp, png_unknown_chunkp pc)
case PNG_HANDLE_CHUNK_AS_DEFAULT:
case PNG_HANDLE_CHUNK_NEVER:
discard = 1/*handled; discard*/;
discard = 1; /*handled; discard*/
break;
case PNG_HANDLE_CHUNK_IF_SAFE:
case PNG_HANDLE_CHUNK_ALWAYS:
discard = 0/*not handled; keep*/;
discard = 0; /*not handled; keep*/
break;
}
/* Also store information about this chunk in the display, the relevant flag
* is set if the chunk is to be kept ('not handled'.)
*/
if (chunk >= 0) if (!discard) /* stupidity to stop a GCC warning */
if (chunk >= 0)
{
png_uint_32 flag = chunk_info[chunk].flag;
if (!discard) /* stupidity to stop a GCC warning */
{
png_uint_32 flag = chunk_info[chunk].flag;
if (pc->location & PNG_AFTER_IDAT)
d->after_IDAT |= flag;
if (pc->location & PNG_AFTER_IDAT)
d->after_IDAT |= flag;
else
d->before_IDAT |= flag;
else
d->before_IDAT |= flag;
}
}
/* However if there is no support to store unknown chunks don't ask libpng to
@ -841,8 +846,9 @@ check(FILE *fp, int argc, const char **argv, png_uint_32p flags/*out*/,
{
png_uint_32 y;
for (y=0; y<height; ++y) if (PNG_ROW_IN_INTERLACE_PASS(y, ipass))
png_read_row(d->png_ptr, NULL, NULL);
for (y=0; y<height; ++y)
if (PNG_ROW_IN_INTERLACE_PASS(y, ipass))
png_read_row(d->png_ptr, NULL, NULL);
}
}
} /* interlaced */
@ -1091,15 +1097,15 @@ perform_one_test_safe(FILE *fp, int argc, const char **argv,
static const char *standard_tests[] =
{
"discard", "default=discard", 0,
"save", "default=save", 0,
"if-safe", "default=if-safe", 0,
"vpAg", "vpAg=if-safe", 0,
"sTER", "sTER=if-safe", 0,
"IDAT", "default=discard", "IDAT=save", 0,
"sAPI", "bKGD=save", "cHRM=save", "gAMA=save", "all=discard", "iCCP=save",
"sBIT=save", "sRGB=save", "eXIf=save", 0,
0/*end*/
"discard", "default=discard", NULL,
"save", "default=save", NULL,
"if-safe", "default=if-safe", NULL,
"vpAg", "vpAg=if-safe", NULL,
"sTER", "sTER=if-safe", NULL,
"IDAT", "default=discard", "IDAT=save", NULL,
"sAPI", "bKGD=save", "cHRM=save", "gAMA=save", "all=discard", "iCCP=save",
"sBIT=save", "sRGB=save", "eXIf=save", NULL,
NULL /*end*/
};
static PNG_NORETURN void
@ -1115,7 +1121,7 @@ int
main(int argc, const char **argv)
{
FILE *fp;
png_uint_32 default_flags[4/*valid,unknown{before,after}*/];
png_uint_32 default_flags[4]; /*valid,unknown{before,after}*/
int strict = 0, default_tests = 0;
const char *count_argv = "default=save";
const char *touch_file = NULL;
@ -1153,8 +1159,9 @@ main(int argc, const char **argv)
/* GCC BUG: if (default_tests && argc != 1) triggers some weird GCC argc
* optimization which causes warnings with -Wstrict-overflow!
*/
else if (default_tests) if (argc != 1)
usage(d.program, "extra arguments");
else if (default_tests)
if (argc != 1)
usage(d.program, "extra arguments");
/* The name of the test file is the last argument; remove it. */
d.file = argv[--argc];
@ -1216,7 +1223,11 @@ main(int argc, const char **argv)
const char *result;
int arg_count = 0;
while (*next) ++next, ++arg_count;
while (*next != NULL)
{
++next;
++arg_count;
}
perform_one_test_safe(fp, arg_count, test, default_flags, &d,
this_test);

View file

@ -1,7 +1,7 @@
/* pngvalid.c - validate libpng by constructing then reading png files.
*
* Last changed in libpng 1.6.31 [July 27, 2017]
* Copyright (c) 2021 Cosmin Truta
* Copyright (c) 2014-2017 John Cunningham Bowler
*
* This code is released under the libpng license.
@ -22,6 +22,7 @@
#define _ISOC99_SOURCE 1 /* For floating point */
#define _GNU_SOURCE 1 /* For the floating point exception extension */
#define _BSD_SOURCE 1 /* For the floating point exception extension */
#define _DEFAULT_SOURCE 1 /* For the floating point exception extension */
#include <signal.h>
#include <stdio.h>
@ -5822,8 +5823,9 @@ test_standard(png_modifier* const pm, png_byte const colour_type,
for (interlace_type = PNG_INTERLACE_NONE;
interlace_type < INTERLACE_LAST; ++interlace_type)
{
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo), 0/*palette*/,
interlace_type, 0, 0, 0), do_read_interlace, pm->use_update_info);
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo),
0/*palette*/, interlace_type, 0, 0, 0), do_read_interlace,
pm->use_update_info);
if (fail(pm))
return 0;
@ -5876,47 +5878,50 @@ test_size(png_modifier* const pm, png_byte const colour_type,
{
png_uint_32 h, w;
for (h=1; h<=16; h+=hinc[bdlo]) for (w=1; w<=16; w+=winc[bdlo])
for (h=1; h<=16; h+=hinc[bdlo])
{
/* First test all the 'size' images against the sequential
* reader using libpng to deinterlace (where required.) This
* validates the write side of libpng. There are four possibilities
* to validate.
*/
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo), 0/*palette*/,
PNG_INTERLACE_NONE, w, h, 0), 0/*do_interlace*/,
pm->use_update_info);
for (w=1; w<=16; w+=winc[bdlo])
{
/* First test all the 'size' images against the sequential
* reader using libpng to deinterlace (where required.) This
* validates the write side of libpng. There are four possibilities
* to validate.
*/
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo),
0/*palette*/, PNG_INTERLACE_NONE, w, h, 0), 0/*do_interlace*/,
pm->use_update_info);
if (fail(pm))
return 0;
if (fail(pm))
return 0;
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo), 0/*palette*/,
PNG_INTERLACE_NONE, w, h, 1), 0/*do_interlace*/,
pm->use_update_info);
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo),
0/*palette*/, PNG_INTERLACE_NONE, w, h, 1), 0/*do_interlace*/,
pm->use_update_info);
if (fail(pm))
return 0;
if (fail(pm))
return 0;
/* Now validate the interlaced read side - do_interlace true,
* in the progressive case this does actually make a difference
* to the code used in the non-interlaced case too.
*/
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo), 0/*palette*/,
PNG_INTERLACE_NONE, w, h, 0), 1/*do_interlace*/,
pm->use_update_info);
/* Now validate the interlaced read side - do_interlace true,
* in the progressive case this does actually make a difference
* to the code used in the non-interlaced case too.
*/
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo),
0/*palette*/, PNG_INTERLACE_NONE, w, h, 0), 1/*do_interlace*/,
pm->use_update_info);
if (fail(pm))
return 0;
if (fail(pm))
return 0;
# if CAN_WRITE_INTERLACE
/* Validate the pngvalid code itself: */
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo), 0/*palette*/,
PNG_INTERLACE_ADAM7, w, h, 1), 1/*do_interlace*/,
pm->use_update_info);
# if CAN_WRITE_INTERLACE
/* Validate the pngvalid code itself: */
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo),
0/*palette*/, PNG_INTERLACE_ADAM7, w, h, 1), 1/*do_interlace*/,
pm->use_update_info);
if (fail(pm))
return 0;
# endif
if (fail(pm))
return 0;
# endif
}
}
}
@ -5927,45 +5932,48 @@ test_size(png_modifier* const pm, png_byte const colour_type,
{
png_uint_32 h, w;
for (h=1; h<=16; h+=hinc[bdlo]) for (w=1; w<=16; w+=winc[bdlo])
for (h=1; h<=16; h+=hinc[bdlo])
{
# ifdef PNG_READ_INTERLACING_SUPPORTED
/* Test with pngvalid generated interlaced images first; we have
* already verify these are ok (unless pngvalid has self-consistent
* read/write errors, which is unlikely), so this detects errors in the
* read side first:
*/
# if CAN_WRITE_INTERLACE
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo), 0/*palette*/,
PNG_INTERLACE_ADAM7, w, h, 1), 0/*do_interlace*/,
pm->use_update_info);
for (w=1; w<=16; w+=winc[bdlo])
{
# ifdef PNG_READ_INTERLACING_SUPPORTED
/* Test with pngvalid generated interlaced images first; we have
* already verify these are ok (unless pngvalid has self-consistent
* read/write errors, which is unlikely), so this detects errors in
* the read side first:
*/
# if CAN_WRITE_INTERLACE
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo),
0/*palette*/, PNG_INTERLACE_ADAM7, w, h, 1), 0/*do_interlace*/,
pm->use_update_info);
if (fail(pm))
return 0;
# endif
# endif /* READ_INTERLACING */
if (fail(pm))
return 0;
# endif
# endif /* READ_INTERLACING */
# ifdef PNG_WRITE_INTERLACING_SUPPORTED
/* Test the libpng write side against the pngvalid read side: */
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo), 0/*palette*/,
PNG_INTERLACE_ADAM7, w, h, 0), 1/*do_interlace*/,
pm->use_update_info);
# ifdef PNG_WRITE_INTERLACING_SUPPORTED
/* Test the libpng write side against the pngvalid read side: */
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo),
0/*palette*/, PNG_INTERLACE_ADAM7, w, h, 0), 1/*do_interlace*/,
pm->use_update_info);
if (fail(pm))
return 0;
# endif
if (fail(pm))
return 0;
# endif
# ifdef PNG_READ_INTERLACING_SUPPORTED
# ifdef PNG_WRITE_INTERLACING_SUPPORTED
/* Test both together: */
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo), 0/*palette*/,
PNG_INTERLACE_ADAM7, w, h, 0), 0/*do_interlace*/,
pm->use_update_info);
# ifdef PNG_READ_INTERLACING_SUPPORTED
# ifdef PNG_WRITE_INTERLACING_SUPPORTED
/* Test both together: */
standard_test(&pm->this, FILEID(colour_type, DEPTH(bdlo),
0/*palette*/, PNG_INTERLACE_ADAM7, w, h, 0), 0/*do_interlace*/,
pm->use_update_info);
if (fail(pm))
return 0;
# endif
# endif /* READ_INTERLACING */
if (fail(pm))
return 0;
# endif
# endif /* READ_INTERLACING */
}
}
}
@ -7635,7 +7643,7 @@ image_transform_png_set_rgb_to_gray_ini(const image_transform *this,
else
{
/* The default (built in) coeffcients, as above: */
/* The default (built in) coefficients, as above: */
# if PNG_LIBPNG_VER < 10700
data.red_coefficient = 6968 / 32768.;
data.green_coefficient = 23434 / 32768.;
@ -10649,16 +10657,21 @@ static void perform_gamma_transform_tests(png_modifier *pm)
{
unsigned int i, j;
for (i=0; i<pm->ngamma_tests; ++i) for (j=0; j<pm->ngamma_tests; ++j)
if (i != j)
for (i=0; i<pm->ngamma_tests; ++i)
{
for (j=0; j<pm->ngamma_tests; ++j)
{
gamma_transform_test(pm, colour_type, bit_depth, palette_number,
pm->interlace_type, 1/pm->gammas[i], pm->gammas[j], 0/*sBIT*/,
pm->use_input_precision, 0 /*do not scale16*/);
if (i != j)
{
gamma_transform_test(pm, colour_type, bit_depth, palette_number,
pm->interlace_type, 1/pm->gammas[i], pm->gammas[j],
0/*sBIT*/, pm->use_input_precision, 0/*do not scale16*/);
if (fail(pm))
return;
if (fail(pm))
return;
}
}
}
}
}
@ -10687,14 +10700,17 @@ static void perform_gamma_sbit_tests(png_modifier *pm)
{
unsigned int j;
for (j=0; j<pm->ngamma_tests; ++j) if (i != j)
for (j=0; j<pm->ngamma_tests; ++j)
{
gamma_transform_test(pm, colour_type, bit_depth, npalette,
pm->interlace_type, 1/pm->gammas[i], pm->gammas[j],
sbit, pm->use_input_precision_sbit, 0 /*scale16*/);
if (i != j)
{
gamma_transform_test(pm, colour_type, bit_depth, npalette,
pm->interlace_type, 1/pm->gammas[i], pm->gammas[j],
sbit, pm->use_input_precision_sbit, 0 /*scale16*/);
if (fail(pm))
return;
if (fail(pm))
return;
}
}
}
}
@ -10946,14 +10962,17 @@ perform_gamma_composition_tests(png_modifier *pm, int do_background,
unsigned int i, j;
/* Don't skip the i==j case here - it's relevant. */
for (i=0; i<pm->ngamma_tests; ++i) for (j=0; j<pm->ngamma_tests; ++j)
for (i=0; i<pm->ngamma_tests; ++i)
{
gamma_composition_test(pm, colour_type, bit_depth, palette_number,
pm->interlace_type, 1/pm->gammas[i], pm->gammas[j],
pm->use_input_precision, do_background, expand_16);
for (j=0; j<pm->ngamma_tests; ++j)
{
gamma_composition_test(pm, colour_type, bit_depth, palette_number,
pm->interlace_type, 1/pm->gammas[i], pm->gammas[j],
pm->use_input_precision, do_background, expand_16);
if (fail(pm))
return;
if (fail(pm))
return;
}
}
}
}
@ -11056,7 +11075,7 @@ perform_gamma_test(png_modifier *pm, int summary)
pm->calculations_use_input_precision = 0;
if (summary)
summarize_gamma_errors(pm, 0/*who*/, 1/*low bit depth*/, 1/*indexed*/);
summarize_gamma_errors(pm, NULL/*who*/, 1/*low bit depth*/, 1/*indexed*/);
if (fail(pm))
return;
@ -11182,8 +11201,10 @@ png_pass_start_row(int pass)
{
int x, y;
++pass;
for (y=0; y<8; ++y) for (x=0; x<8; ++x) if (adam7[y][x] == pass)
return y;
for (y=0; y<8; ++y)
for (x=0; x<8; ++x)
if (adam7[y][x] == pass)
return y;
return 0xf;
}
@ -11192,8 +11213,10 @@ png_pass_start_col(int pass)
{
int x, y;
++pass;
for (x=0; x<8; ++x) for (y=0; y<8; ++y) if (adam7[y][x] == pass)
return x;
for (x=0; x<8; ++x)
for (y=0; y<8; ++y)
if (adam7[y][x] == pass)
return x;
return 0xf;
}
@ -11202,18 +11225,24 @@ png_pass_row_shift(int pass)
{
int x, y, base=(-1), inc=8;
++pass;
for (y=0; y<8; ++y) for (x=0; x<8; ++x) if (adam7[y][x] == pass)
for (y=0; y<8; ++y)
{
if (base == (-1))
base = y;
else if (base == y)
{}
else if (inc == y-base)
base=y;
else if (inc == 8)
inc = y-base, base=y;
else if (inc != y-base)
return 0xff; /* error - more than one 'inc' value! */
for (x=0; x<8; ++x)
{
if (adam7[y][x] == pass)
{
if (base == (-1))
base = y;
else if (base == y)
{}
else if (inc == y-base)
base=y;
else if (inc == 8)
inc = y-base, base=y;
else if (inc != y-base)
return 0xff; /* error - more than one 'inc' value! */
}
}
}
if (base == (-1)) return 0xfe; /* error - no row in pass! */
@ -11236,18 +11265,24 @@ png_pass_col_shift(int pass)
{
int x, y, base=(-1), inc=8;
++pass;
for (x=0; x<8; ++x) for (y=0; y<8; ++y) if (adam7[y][x] == pass)
for (x=0; x<8; ++x)
{
if (base == (-1))
base = x;
else if (base == x)
{}
else if (inc == x-base)
base=x;
else if (inc == 8)
inc = x-base, base=x;
else if (inc != x-base)
return 0xff; /* error - more than one 'inc' value! */
for (y=0; y<8; ++y)
{
if (adam7[y][x] == pass)
{
if (base == (-1))
base = x;
else if (base == x)
{}
else if (inc == x-base)
base=x;
else if (inc == 8)
inc = x-base, base=x;
else if (inc != x-base)
return 0xff; /* error - more than one 'inc' value! */
}
}
}
if (base == (-1)) return 0xfe; /* error - no row in pass! */
@ -11311,8 +11346,9 @@ png_row_in_interlace_pass(png_uint_32 y, int pass)
int x;
y &= 7;
++pass;
for (x=0; x<8; ++x) if (adam7[y][x] == pass)
return 1;
for (x=0; x<8; ++x)
if (adam7[y][x] == pass)
return 1;
return 0;
}
@ -11324,8 +11360,9 @@ png_col_in_interlace_pass(png_uint_32 x, int pass)
int y;
x &= 7;
++pass;
for (y=0; y<8; ++y) if (adam7[y][x] == pass)
return 1;
for (y=0; y<8; ++y)
if (adam7[y][x] == pass)
return 1;
return 0;
}
@ -11339,11 +11376,17 @@ png_pass_rows(png_uint_32 height, int pass)
height &= 7;
++pass;
for (y=0; y<8; ++y) for (x=0; x<8; ++x) if (adam7[y][x] == pass)
for (y=0; y<8; ++y)
{
rows += tiles;
if (y < height) ++rows;
break; /* i.e. break the 'x', column, loop. */
for (x=0; x<8; ++x)
{
if (adam7[y][x] == pass)
{
rows += tiles;
if (y < height) ++rows;
break; /* i.e. break the 'x', column, loop. */
}
}
}
return rows;
@ -11358,11 +11401,17 @@ png_pass_cols(png_uint_32 width, int pass)
width &= 7;
++pass;
for (x=0; x<8; ++x) for (y=0; y<8; ++y) if (adam7[y][x] == pass)
for (x=0; x<8; ++x)
{
cols += tiles;
if (x < width) ++cols;
break; /* i.e. break the 'y', row, loop. */
for (y=0; y<8; ++y)
{
if (adam7[y][x] == pass)
{
cols += tiles;
if (x < width) ++cols;
break; /* i.e. break the 'y', row, loop. */
}
}
}
return cols;
@ -11719,7 +11768,7 @@ int main(int argc, char **argv)
/* The following allows results to pass if they correspond to anything in the
* transformed range [input-.5,input+.5]; this is is required because of the
* way libpng treates the 16_TO_8 flag when building the gamma tables in
* way libpng treats the 16_TO_8 flag when building the gamma tables in
* releases up to 1.6.0.
*
* TODO: review this
@ -11810,21 +11859,21 @@ int main(int argc, char **argv)
#ifdef PNG_READ_TRANSFORMS_SUPPORTED
else if (strncmp(*argv, "--transform-disable=",
sizeof "--transform-disable") == 0)
{
{
pm.test_transform = 1;
transform_disable(*argv + sizeof "--transform-disable");
}
}
else if (strncmp(*argv, "--transform-enable=",
sizeof "--transform-enable") == 0)
{
{
pm.test_transform = 1;
transform_enable(*argv + sizeof "--transform-enable");
}
}
#endif /* PNG_READ_TRANSFORMS_SUPPORTED */
else if (strcmp(*argv, "--gamma") == 0)
{
{
/* Just do two gamma tests here (2.2 and linear) for speed: */
pm.ngamma_tests = 2U;
pm.test_gamma_threshold = 1;
@ -11833,7 +11882,7 @@ int main(int argc, char **argv)
pm.test_gamma_scale16 = 1;
pm.test_gamma_background = 1; /* composition */
pm.test_gamma_alpha_mode = 1;
}
}
else if (strcmp(*argv, "--nogamma") == 0)
pm.ngamma_tests = 0;

View file

@ -1,9 +1,8 @@
/* readpng.c
*
* Copyright (c) 2013 John Cunningham Bowler
*
* Last changed in libpng 1.6.1 [March 28, 2013]
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
* and license in png.h

View file

@ -1,10 +1,9 @@
/* tarith.c
*
* Copyright (c) 2021 Cosmin Truta
* Copyright (c) 2011-2013 John Cunningham Bowler
*
* Last changed in libpng 1.6.0 [February 14, 2013]
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
* and license in png.h
@ -88,6 +87,7 @@ int validation_ascii_to_fp(int count, int argc, char **argv)
int minorarith = 0;
while (--argc > 0)
{
if (strcmp(*++argv, "-a") == 0)
showall = 1;
else if (strcmp(*argv, "-e") == 0 && argc > 0)
@ -105,6 +105,7 @@ int validation_ascii_to_fp(int count, int argc, char **argv)
fprintf(stderr, "unknown argument %s\n", *argv);
return 1;
}
}
do
{
@ -130,8 +131,8 @@ int validation_ascii_to_fp(int count, int argc, char **argv)
*/
if (buffer[precision+7] != 71)
{
fprintf(stderr, "%g[%d] -> '%s'[%lu] buffer overflow\n", test,
precision, buffer, (unsigned long)strlen(buffer));
fprintf(stderr, "%g[%d] -> '%s'[%lu] buffer overflow\n",
test, precision, buffer, (unsigned long)strlen(buffer));
failed = 1;
}
@ -146,16 +147,16 @@ int validation_ascii_to_fp(int count, int argc, char **argv)
if (test >= 0 && strcmp(buffer, "inf") ||
test < 0 && strcmp(buffer, "-inf"))
{
fprintf(stderr, "%g[%d] -> '%s' but expected 'inf'\n", test,
precision, buffer);
fprintf(stderr, "%g[%d] -> '%s' but expected 'inf'\n",
test, precision, buffer);
failed = 1;
}
}
else if (!png_check_fp_number(buffer, precision+10, &state, &index) ||
buffer[index] != 0)
{
fprintf(stderr, "%g[%d] -> '%s' but has bad format ('%c')\n", test,
precision, buffer, buffer[index]);
fprintf(stderr, "%g[%d] -> '%s' but has bad format ('%c')\n",
test, precision, buffer, buffer[index]);
failed = 1;
}
else if (PNG_FP_IS_NEGATIVE(state) && !(test < 0))
@ -187,7 +188,7 @@ int validation_ascii_to_fp(int count, int argc, char **argv)
/* Check the result against the original. */
double out = atof(buffer);
double change = fabs((out - test)/test);
double allow = .5/pow(10,
double allow = .5 / pow(10,
(precision >= DBL_DIG) ? DBL_DIG-1 : precision-1);
/* NOTE: if you hit this error case are you compiling with gcc
@ -257,8 +258,9 @@ skip:
}
while (--count);
printf("Tested %d finite values, %d non-finite, %d OK (%d failed) %d minor "
"arithmetic errors\n", finite, nonfinite, ok, failcount, minorarith);
printf("Tested %d finite values, %d non-finite, %d OK (%d failed) "
"%d minor arithmetic errors\n",
finite, nonfinite, ok, failcount, minorarith);
printf(" Error with >=%d digit precision %.2f%%\n", DBL_DIG, max_abs);
printf(" Error with < %d digit precision %.2f%%\n", DBL_DIG, max);
@ -371,8 +373,8 @@ static int check_one_character(checkfp_command *co, checkfp_control c, int ch)
/* This should never fail (it's a serious bug if it does): */
if (index != 0 && index != 1)
{
fprintf(stderr, "%s: read beyond end of string (%lu)\n", co->number,
(unsigned long)index);
fprintf(stderr, "%s: read beyond end of string (%lu)\n",
co->number, (unsigned long)index);
return 0;
}
@ -503,8 +505,8 @@ static int check_one_character(checkfp_command *co, checkfp_control c, int ch)
if (number_is_valid != c.number_was_valid)
{
fprintf(stderr,
"%s: character '%c' [0x%.2x] changed number validity\n", co->number,
ch, ch);
"%s: character '%c' [0x%.2x] changed number validity\n",
co->number, ch, ch);
return 0;
}
@ -521,10 +523,13 @@ static int check_all_characters(checkfp_command *co, checkfp_control c)
{
int ch;
if (c.cnumber+4 < sizeof co->number) for (ch=0; ch<256; ++ch)
if (c.cnumber+4 < sizeof co->number)
{
if (!check_one_character(co, c, ch))
return 0;
for (ch=0; ch<256; ++ch)
{
if (!check_one_character(co, c, ch))
return 0;
}
}
return 1;
@ -539,10 +544,13 @@ static int check_some_characters(checkfp_command *co, checkfp_control c,
if (c.cnumber+4 < sizeof co->number && c.limit >= 0)
{
if (c.limit > 0) for (i=0; tests[i]; ++i)
if (c.limit > 0)
{
if (!check_one_character(co, c, tests[i]))
return 0;
for (i=0; tests[i]; ++i)
{
if (!check_one_character(co, c, tests[i]))
return 0;
}
}
/* At the end check all the characters. */
@ -616,10 +624,10 @@ int validation_muldiv(int count, int argc, char **argv)
png_int_32 times, div;
while (--argc > 0)
{
fprintf(stderr, "unknown argument %s\n", *++argv);
return 1;
}
{
fprintf(stderr, "unknown argument %s\n", *++argv);
return 1;
}
/* Find out about the random number generator. */
randbuffer = RAND_MAX;
@ -687,25 +695,25 @@ int validation_muldiv(int count, int argc, char **argv)
ok = 0, ++overflow, fpround = fp/*misleading*/;
if (verbose)
fprintf(stderr, "TEST %d * %d / %d -> %lld (%s)\n", a, times, div,
fp, ok ? "ok" : "overflow");
fprintf(stderr, "TEST %d * %d / %d -> %lld (%s)\n",
a, times, div, fp, ok ? "ok" : "overflow");
++tested;
if (png_muldiv(&result, a, times, div) != ok)
{
++error;
if (ok)
fprintf(stderr, "%d * %d / %d -> overflow (expected %lld)\n", a,
times, div, fp);
fprintf(stderr, "%d * %d / %d -> overflow (expected %lld)\n",
a, times, div, fp);
else
fprintf(stderr, "%d * %d / %d -> %d (expected overflow %lld)\n", a,
times, div, result, fp);
fprintf(stderr, "%d * %d / %d -> %d (expected overflow %lld)\n",
a, times, div, result, fp);
}
else if (ok && result != fpround)
{
++error;
fprintf(stderr, "%d * %d / %d -> %d not %lld\n", a, times, div, result,
fp);
fprintf(stderr, "%d * %d / %d -> %d not %lld\n",
a, times, div, result, fp);
}
else
++passed;
@ -721,8 +729,8 @@ int validation_muldiv(int count, int argc, char **argv)
}
while (--count > 0);
printf("%d tests including %d overflows, %d passed, %d failed (%d 64-bit "
"errors)\n", tested, overflow, passed, error, error64);
printf("%d tests including %d overflows, %d passed, %d failed "
"(%d 64-bit errors)\n", tested, overflow, passed, error, error64);
return 0;
}
@ -821,8 +829,9 @@ int validation_gamma(int argc, char **argv)
{
if (error > .68) /* By experiment error is less than .68 */
{
fprintf(stderr, "16-bit log error: %d: got %u, expected %f"
" error: %f\n", i, png_log16bit(i), correct, error);
fprintf(stderr,
"16-bit log error: %d: got %u, expected %f error: %f\n",
i, png_log16bit(i), correct, error);
}
}
}
@ -841,8 +850,9 @@ int validation_gamma(int argc, char **argv)
maxerr = fabs(error);
if (fabs(error) > 1883) /* By experiment. */
{
fprintf(stderr, "32-bit exp error: %d: got %u, expected %f"
" error: %f\n", i, png_exp(i), correct, error);
fprintf(stderr,
"32-bit exp error: %d: got %u, expected %f error: %f\n",
i, png_exp(i), correct, error);
}
}
@ -859,8 +869,9 @@ int validation_gamma(int argc, char **argv)
maxerr = fabs(error);
if (fabs(error) > .50002) /* By experiment */
{
fprintf(stderr, "8-bit exp error: %d: got %u, expected %f"
" error: %f\n", i, png_exp8bit(i), correct, error);
fprintf(stderr,
"8-bit exp error: %d: got %u, expected %f error: %f\n",
i, png_exp8bit(i), correct, error);
}
}
@ -877,8 +888,9 @@ int validation_gamma(int argc, char **argv)
maxerr = fabs(error);
if (fabs(error) > .524) /* By experiment */
{
fprintf(stderr, "16-bit exp error: %d: got %u, expected %f"
" error: %f\n", i, png_exp16bit(i), correct, error);
fprintf(stderr,
"16-bit exp error: %d: got %u, expected %f error: %f\n",
i, png_exp16bit(i), correct, error);
}
}

View file

@ -1,9 +1,8 @@
/* timepng.c
*
* Copyright (c) 2013,2016 John Cunningham Bowler
*
* Last changed in libpng 1.6.22 [May 26, 2016]
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
* and license in png.h
@ -528,7 +527,7 @@ int main(int argc, char **argv)
}
}
else if (nfiles == 0) /* Read from stdin withoout --dissemble */
else if (nfiles == 0) /* Read from stdin without --dissemble */
{
char filename[FILENAME_MAX+1];

View file

@ -1,8 +1,9 @@
/* contrib/mips-msa/linux.c
*
* Copyright (c) 2020 Cosmin Truta
* Copyright (c) 2016 Glenn Randers-Pehrson
* Written by Mandar Sahastrabuddhe, 2016.
* Last changed in libpng 1.6.25beta03 [August 29, 2016]
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
@ -47,8 +48,10 @@ png_have_msa(png_structp png_ptr)
int val = strcmp(string, word);
if (val == 0)
if (val == 0) {
fclose(f);
return 1;
}
i = 0;
memset(word, 0, 10);

View file

@ -78,6 +78,22 @@ void user_read_data(png_structp png_ptr, png_bytep data, size_t length) {
buf_state->data += length;
}
void* limited_malloc(png_structp, png_alloc_size_t size) {
// libpng may allocate large amounts of memory that the fuzzer reports as
// an error. In order to silence these errors, make libpng fail when trying
// to allocate a large amount. This allocator used to be in the Chromium
// version of this fuzzer.
// This number is chosen to match the default png_user_chunk_malloc_max.
if (size > 8000000)
return nullptr;
return malloc(size);
}
void default_free(png_structp, png_voidp ptr) {
return free(ptr);
}
static const int kPngHeaderSize = 8;
// Entry point for LibFuzzer.
@ -118,6 +134,9 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
return 0;
}
// Use a custom allocator that fails for large allocations to avoid OOM.
png_set_mem_fn(png_handler.png_ptr, nullptr, limited_malloc, default_free);
png_set_crc_action(png_handler.png_ptr, PNG_CRC_QUIET_USE, PNG_CRC_QUIET_USE);
#ifdef PNG_IGNORE_ADLER32
png_set_option(png_handler.png_ptr, PNG_IGNORE_ADLER32, PNG_OPTION_ON);

View file

@ -453,7 +453,7 @@ check_square(const struct arg *arg, double x, double y)
* { inside_circle_filled, check_circle_filled },
* { inside_circle, check_circle }
*
* The functions here are analoguous to the square ones; however, they check
* The functions here are analogous to the square ones; however, they check
* the corresponding ellipse as opposed to the rectangle.
*/
static int

View file

@ -336,7 +336,7 @@ static const option options[] =
# define VLC(name) VLCIDAT(name) VLCiCCP(name) VLCzTXt(name)
# ifdef PNG_SW_COMPRESS_png_level
/* The libpng compression level isn't searched because it justs sets the
/* The libpng compression level isn't searched because it just sets the
* other things that are searched!
*/
VLO("compression", compression, 0)

View file

@ -1598,7 +1598,7 @@ chunk_init(struct chunk * const chunk, struct file * const file)
chunk->chunk_length = file->length;
chunk->chunk_type = file->type;
/* Compresssed/uncompressed size information (from the zlib control structure
/* Compressed/uncompressed size information (from the zlib control structure
* that is used to check the compressed data in a chunk.)
*/
chunk->uncompressed_digits = 0;
@ -2929,7 +2929,7 @@ process_chunk(struct file *file, png_uint_32 file_crc, png_uint_32 next_length,
}
/* Control reaches this point if the chunk must be skipped. For chunks other
* than IDAT this means that the zlib compressed data is fatally damanged and
* than IDAT this means that the zlib compressed data is fatally damaged and
* the chunk will not be passed to libpng. For IDAT it means that the end of
* the IDAT stream has not yet been reached and we must handle the next
* (IDAT) chunk. If the LZ data in an IDAT stream cannot be read 'stop' must

View file

@ -3,7 +3,7 @@
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1999-2018 Free Software Foundation, Inc.
# Copyright (C) 1999-2021 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by

View file

@ -125,6 +125,7 @@ int main(int argc, const char **argv)
png_image_free(&image);
else
free(buffer);
}
}
/* Something went wrong reading or writing the image. libpng stores a

View file

@ -1,7 +1,7 @@
#!/bin/sh
# install - install a program, script, or datafile
scriptversion=2018-03-11.20; # UTC
scriptversion=2020-11-14.01; # UTC
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
@ -69,6 +69,11 @@ posix_mkdir=
# Desired mode of installed file.
mode=0755
# Create dirs (including intermediate dirs) using mode 755.
# This is like GNU 'install' as of coreutils 8.32 (2020).
mkdir_umask=22
backupsuffix=
chgrpcmd=
chmodcmd=$chmodprog
chowncmd=
@ -99,18 +104,28 @@ Options:
--version display version info and exit.
-c (ignored)
-C install only if different (preserve the last data modification time)
-C install only if different (preserve data modification time)
-d create directories instead of installing files.
-g GROUP $chgrpprog installed files to GROUP.
-m MODE $chmodprog installed files to MODE.
-o USER $chownprog installed files to USER.
-p pass -p to $cpprog.
-s $stripprog installed files.
-S SUFFIX attempt to back up existing files, with suffix SUFFIX.
-t DIRECTORY install into DIRECTORY.
-T report an error if DSTFILE is a directory.
Environment variables override the default commands:
CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG
RMPROG STRIPPROG
By default, rm is invoked with -f; when overridden with RMPROG,
it's up to you to specify -f if you want it.
If -S is not specified, no backups are attempted.
Email bug reports to bug-automake@gnu.org.
Automake home page: https://www.gnu.org/software/automake/
"
while test $# -ne 0; do
@ -137,8 +152,13 @@ while test $# -ne 0; do
-o) chowncmd="$chownprog $2"
shift;;
-p) cpprog="$cpprog -p";;
-s) stripcmd=$stripprog;;
-S) backupsuffix="$2"
shift;;
-t)
is_target_a_directory=always
dst_arg=$2
@ -255,6 +275,10 @@ do
dstdir=$dst
test -d "$dstdir"
dstdir_status=$?
# Don't chown directories that already exist.
if test $dstdir_status = 0; then
chowncmd=""
fi
else
# Waiting for this to be detected by the "$cpprog $src $dsttmp" command
@ -301,22 +325,6 @@ do
if test $dstdir_status != 0; then
case $posix_mkdir in
'')
# Create intermediate dirs using mode 755 as modified by the umask.
# This is like FreeBSD 'install' as of 1997-10-28.
umask=`umask`
case $stripcmd.$umask in
# Optimize common cases.
*[2367][2367]) mkdir_umask=$umask;;
.*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;;
*[0-7])
mkdir_umask=`expr $umask + 22 \
- $umask % 100 % 40 + $umask % 20 \
- $umask % 10 % 4 + $umask % 2
`;;
*) mkdir_umask=$umask,go-w;;
esac
# With -d, create the new directory with the user-specified mode.
# Otherwise, rely on $mkdir_umask.
if test -n "$dir_arg"; then
@ -326,52 +334,49 @@ do
fi
posix_mkdir=false
case $umask in
*[123567][0-7][0-7])
# POSIX mkdir -p sets u+wx bits regardless of umask, which
# is incompatible with FreeBSD 'install' when (umask & 300) != 0.
;;
*)
# Note that $RANDOM variable is not portable (e.g. dash); Use it
# here however when possible just to lower collision chance.
tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
# The $RANDOM variable is not portable (e.g., dash). Use it
# here however when possible just to lower collision chance.
tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0
trap '
ret=$?
rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null
exit $ret
' 0
# Because "mkdir -p" follows existing symlinks and we likely work
# directly in world-writeable /tmp, make sure that the '$tmpdir'
# directory is successfully created first before we actually test
# 'mkdir -p' feature.
if (umask $mkdir_umask &&
$mkdirprog $mkdir_mode "$tmpdir" &&
exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1
then
if test -z "$dir_arg" || {
# Check for POSIX incompatibilities with -m.
# HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
# other-writable bit of parent directory when it shouldn't.
# FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
test_tmpdir="$tmpdir/a"
ls_ld_tmpdir=`ls -ld "$test_tmpdir"`
case $ls_ld_tmpdir in
d????-?r-*) different_mode=700;;
d????-?--*) different_mode=755;;
*) false;;
esac &&
$mkdirprog -m$different_mode -p -- "$test_tmpdir" && {
ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"`
test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
}
}
then posix_mkdir=:
fi
rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir"
else
# Remove any dirs left behind by ancient mkdir implementations.
rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null
fi
trap '' 0;;
esac;;
# Because "mkdir -p" follows existing symlinks and we likely work
# directly in world-writeable /tmp, make sure that the '$tmpdir'
# directory is successfully created first before we actually test
# 'mkdir -p'.
if (umask $mkdir_umask &&
$mkdirprog $mkdir_mode "$tmpdir" &&
exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1
then
if test -z "$dir_arg" || {
# Check for POSIX incompatibilities with -m.
# HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
# other-writable bit of parent directory when it shouldn't.
# FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
test_tmpdir="$tmpdir/a"
ls_ld_tmpdir=`ls -ld "$test_tmpdir"`
case $ls_ld_tmpdir in
d????-?r-*) different_mode=700;;
d????-?--*) different_mode=755;;
*) false;;
esac &&
$mkdirprog -m$different_mode -p -- "$test_tmpdir" && {
ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"`
test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
}
}
then posix_mkdir=:
fi
rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir"
else
# Remove any dirs left behind by ancient mkdir implementations.
rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null
fi
trap '' 0;;
esac
if
@ -382,7 +387,7 @@ do
then :
else
# The umask is ridiculous, or mkdir does not conform to POSIX,
# mkdir does not conform to POSIX,
# or it failed possibly due to a race condition. Create the
# directory the slow way, step by step, checking for races as we go.
@ -411,7 +416,7 @@ do
prefixes=
else
if $posix_mkdir; then
(umask=$mkdir_umask &&
(umask $mkdir_umask &&
$doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break
# Don't fail if two instances are running concurrently.
test -d "$prefix" || exit 1
@ -451,7 +456,18 @@ do
trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
# Copy the file name to the temp name.
(umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") &&
(umask $cp_umask &&
{ test -z "$stripcmd" || {
# Create $dsttmp read-write so that cp doesn't create it read-only,
# which would cause strip to fail.
if test -z "$doit"; then
: >"$dsttmp" # No need to fork-exec 'touch'.
else
$doit touch "$dsttmp"
fi
}
} &&
$doit_exec $cpprog "$src" "$dsttmp") &&
# and set any options; do chmod last to preserve setuid bits.
#
@ -477,6 +493,13 @@ do
then
rm -f "$dsttmp"
else
# If $backupsuffix is set, and the file being installed
# already exists, attempt a backup. Don't worry if it fails,
# e.g., if mv doesn't support -f.
if test -n "$backupsuffix" && test -f "$dst"; then
$doit $mvcmd -f "$dst" "$dst$backupsuffix" 2>/dev/null
fi
# Rename the file to the real destination.
$doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null ||
@ -491,9 +514,9 @@ do
# file should still install successfully.
{
test ! -f "$dst" ||
$doit $rmcmd -f "$dst" 2>/dev/null ||
$doit $rmcmd "$dst" 2>/dev/null ||
{ $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null &&
{ $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }
{ $doit $rmcmd "$rmtmp" 2>/dev/null; :; }
} ||
{ echo "$0: cannot unlink or rename $dst" >&2
(exit 1); exit 1

View file

@ -1,6 +1,6 @@
libpng-manual.txt - A description on how to use and modify libpng
Copyright (c) 2018-2019 Cosmin Truta
Copyright (c) 2018-2022 Cosmin Truta
Copyright (c) 1998-2018 Glenn Randers-Pehrson
This document is released under the libpng license.
@ -9,9 +9,9 @@ libpng-manual.txt - A description on how to use and modify libpng
Based on:
libpng version 1.6.36, December 2018, through 1.6.37 - April 2019
libpng version 1.6.36, December 2018, through 1.6.38 - September 2022
Updated and distributed by Cosmin Truta
Copyright (c) 2018-2019 Cosmin Truta
Copyright (c) 2018-2022 Cosmin Truta
libpng versions 0.97, January 1998, through 1.6.35 - July 2018
Updated and distributed by Glenn Randers-Pehrson
@ -1792,7 +1792,7 @@ the information. If, instead, you want to convert the image to an opaque
version with no alpha channel use png_set_background; see below.
As of libpng version 1.5.2, almost all useful expansions are supported, the
major ommissions are conversion of grayscale to indexed images (which can be
major omissions are conversion of grayscale to indexed images (which can be
done trivially in the application) and conversion of indexed to grayscale (which
can be done by a trivial manipulation of the palette.)

View file

@ -1,6 +1,6 @@
.TH LIBPNG 3 "April 14, 2019"
.TH LIBPNG 3 "September 14, 2022"
.SH NAME
libpng \- Portable Network Graphics (PNG) Reference Library 1.6.37
libpng \- Portable Network Graphics (PNG) Reference Library 1.6.38
.SH SYNOPSIS
\fB#include <png.h>\fP
@ -519,7 +519,7 @@ Following is a copy of the libpng-manual.txt file that accompanies libpng.
.SH LIBPNG.TXT
libpng-manual.txt - A description on how to use and modify libpng
Copyright (c) 2018-2019 Cosmin Truta
Copyright (c) 2018-2022 Cosmin Truta
Copyright (c) 1998-2018 Glenn Randers-Pehrson
This document is released under the libpng license.
@ -528,9 +528,9 @@ libpng-manual.txt - A description on how to use and modify libpng
Based on:
libpng version 1.6.36, December 2018, through 1.6.37 - April 2019
libpng version 1.6.36, December 2018, through 1.6.38 - September 2022
Updated and distributed by Cosmin Truta
Copyright (c) 2018-2019 Cosmin Truta
Copyright (c) 2018-2022 Cosmin Truta
libpng versions 0.97, January 1998, through 1.6.35 - July 2018
Updated and distributed by Glenn Randers-Pehrson
@ -2311,7 +2311,7 @@ the information. If, instead, you want to convert the image to an opaque
version with no alpha channel use png_set_background; see below.
As of libpng version 1.5.2, almost all useful expansions are supported, the
major ommissions are conversion of grayscale to indexed images (which can be
major omissions are conversion of grayscale to indexed images (which can be
done trivially in the application) and conversion of indexed to grayscale (which
can be done by a trivial manipulation of the palette.)

View file

@ -6,7 +6,7 @@ includedir=@includedir@/libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@
Name: libpng
Description: Loads and saves PNG files
Version: @PNGLIB_VERSION@
Requires: zlib
Requires.private: zlib
Libs: -L${libdir} -lpng@PNGLIB_MAJOR@@PNGLIB_MINOR@
Libs.private: @LIBS@
Cflags: -I${includedir}

View file

@ -1,6 +1,6 @@
.TH LIBPNGPF 3 "April 14, 2019"
.TH LIBPNGPF 3 "September 14, 2022"
.SH NAME
libpng \- Portable Network Graphics (PNG) Reference Library 1.6.37
libpng \- Portable Network Graphics (PNG) Reference Library 1.6.38
(private functions)
.SH SYNOPSIS

File diff suppressed because it is too large Load diff

View file

@ -3,7 +3,7 @@
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1996-2018 Free Software Foundation, Inc.
# Copyright (C) 1996-2021 Free Software Foundation, Inc.
# Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
# This program is free software; you can redistribute it and/or modify

View file

@ -1,4 +1,4 @@
.TH PNG 5 "April 14, 2019"
.TH PNG 5 "September 14, 2022"
.SH NAME
png \- Portable Network Graphics (PNG) format
@ -43,7 +43,7 @@ or W3C Recommendation
https://www.w3.org/TR/REC-png-961001
.SH AUTHORS
This man page: Cosmin Truta, Glenn Randers-Pehrson
This man page: Glenn Randers-Pehrson, Cosmin Truta
.LP
Portable Network Graphics (PNG) Specification (Second Edition)
Information technology - Computer graphics and image processing -
@ -60,7 +60,7 @@ Thomas Boutell and others (png-list).
.LP
This man page is
.br
Copyright (c) 2018-2019 Cosmin Truta.
Copyright (c) 2018 Cosmin Truta.
.br
Copyright (c) 1998-2006 Glenn Randers-Pehrson.
.br

View file

@ -1,7 +1,7 @@
/* png.c - location for general purpose libpng functions
*
* Copyright (c) 2018-2019 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson
* Copyright (c) 1996-1997 Andreas Dilger
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -14,7 +14,7 @@
#include "pngpriv.h"
/* Generate a compiler error if there is an old png.h in the search path. */
typedef png_libpng_version_1_6_37 Your_png_h_is_not_version_1_6_37;
typedef png_libpng_version_1_6_38 Your_png_h_is_not_version_1_6_38;
#ifdef __GNUC__
/* The version tests may need to be added to, but the problem warning has
@ -720,7 +720,7 @@ png_init_io(png_structrp png_ptr, png_FILE_p fp)
*
* Where UNSIGNED_MAX is the appropriate maximum unsigned value, so when the
* negative integral value is added the result will be an unsigned value
* correspnding to the 2's complement representation.
* corresponding to the 2's complement representation.
*/
void PNGAPI
png_save_int_32(png_bytep buf, png_int_32 i)
@ -815,8 +815,8 @@ png_get_copyright(png_const_structrp png_ptr)
return PNG_STRING_COPYRIGHT
#else
return PNG_STRING_NEWLINE \
"libpng version 1.6.37" PNG_STRING_NEWLINE \
"Copyright (c) 2018-2019 Cosmin Truta" PNG_STRING_NEWLINE \
"libpng version 1.6.38" PNG_STRING_NEWLINE \
"Copyright (c) 2018-2022 Cosmin Truta" PNG_STRING_NEWLINE \
"Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson" \
PNG_STRING_NEWLINE \
"Copyright (c) 1996-1997 Andreas Dilger" PNG_STRING_NEWLINE \
@ -1843,12 +1843,12 @@ png_icc_profile_error(png_const_structrp png_ptr, png_colorspacerp colorspace,
# ifdef PNG_WARNINGS_SUPPORTED
else
{
char number[PNG_NUMBER_BUFFER_SIZE]; /* +24 = 114*/
char number[PNG_NUMBER_BUFFER_SIZE]; /* +24 = 114 */
pos = png_safecat(message, (sizeof message), pos,
png_format_number(number, number+(sizeof number),
PNG_NUMBER_FORMAT_x, value));
pos = png_safecat(message, (sizeof message), pos, "h: "); /*+2 = 116*/
pos = png_safecat(message, (sizeof message), pos, "h: "); /* +2 = 116 */
}
# endif
/* The 'reason' is an arbitrary message, allow +79 maximum 195 */

View file

@ -1,9 +1,9 @@
/* png.h - header file for PNG reference library
*
* libpng version 1.6.37 - April 14, 2019
* libpng version 1.6.38 - September 14, 2022
*
* Copyright (c) 2018-2019 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson
* Copyright (c) 1996-1997 Andreas Dilger
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -15,7 +15,7 @@
* libpng versions 0.89, June 1996, through 0.96, May 1997: Andreas Dilger
* libpng versions 0.97, January 1998, through 1.6.35, July 2018:
* Glenn Randers-Pehrson
* libpng versions 1.6.36, December 2018, through 1.6.37, April 2019:
* libpng versions 1.6.36, December 2018, through 1.6.38, September 2022:
* Cosmin Truta
* See also "Contributing Authors", below.
*/
@ -27,8 +27,8 @@
* PNG Reference Library License version 2
* ---------------------------------------
*
* * Copyright (c) 1995-2019 The PNG Reference Library Authors.
* * Copyright (c) 2018-2019 Cosmin Truta.
* * Copyright (c) 1995-2022 The PNG Reference Library Authors.
* * Copyright (c) 2018-2022 Cosmin Truta.
* * Copyright (c) 2000-2002, 2004, 2006-2018 Glenn Randers-Pehrson.
* * Copyright (c) 1996-1997 Andreas Dilger.
* * Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -239,7 +239,7 @@
* ...
* 1.5.30 15 10530 15.so.15.30[.0]
* ...
* 1.6.37 16 10637 16.so.16.37[.0]
* 1.6.38 16 10638 16.so.16.38[.0]
*
* Henceforth the source version will match the shared-library major and
* minor numbers; the shared-library major version number will be used for
@ -278,8 +278,8 @@
*/
/* Version information for png.h - this should match the version in png.c */
#define PNG_LIBPNG_VER_STRING "1.6.37"
#define PNG_HEADER_VERSION_STRING " libpng version 1.6.37 - April 14, 2019\n"
#define PNG_LIBPNG_VER_STRING "1.6.38"
#define PNG_HEADER_VERSION_STRING " libpng version 1.6.38 - September 14, 2022\n"
#define PNG_LIBPNG_VER_SONUM 16
#define PNG_LIBPNG_VER_DLLNUM 16
@ -287,7 +287,7 @@
/* These should match the first 3 components of PNG_LIBPNG_VER_STRING: */
#define PNG_LIBPNG_VER_MAJOR 1
#define PNG_LIBPNG_VER_MINOR 6
#define PNG_LIBPNG_VER_RELEASE 37
#define PNG_LIBPNG_VER_RELEASE 38
/* This should be zero for a public release, or non-zero for a
* development version. [Deprecated]
@ -318,7 +318,7 @@
* From version 1.0.1 it is:
* XXYYZZ, where XX=major, YY=minor, ZZ=release
*/
#define PNG_LIBPNG_VER 10637 /* 1.6.37 */
#define PNG_LIBPNG_VER 10638 /* 1.6.38 */
/* Library configuration: these options cannot be changed after
* the library has been built.
@ -428,7 +428,7 @@ extern "C" {
/* This triggers a compiler error in png.c, if png.c and png.h
* do not agree upon the version number.
*/
typedef char* png_libpng_version_1_6_37;
typedef char* png_libpng_version_1_6_38;
/* Basic control structions. Read libpng-manual.txt or libpng.3 for more info.
*
@ -1446,7 +1446,7 @@ PNG_EXPORT(66, void, png_set_crc_action, (png_structrp png_ptr, int crit_action,
* mainly useful for testing, as the defaults should work with most users.
* Those users who are tight on memory or want faster performance at the
* expense of compression can modify them. See the compression library
* header file (zlib.h) for an explination of the compression functions.
* header file (zlib.h) for an explanation of the compression functions.
*/
/* Set the filtering method(s) used by libpng. Currently, the only valid
@ -1501,7 +1501,7 @@ PNG_FIXED_EXPORT(209, void, png_set_filter_heuristics_fixed,
* 0 - 9, corresponding directly to the zlib compression levels 0 - 9
* (0 - no compression, 9 - "maximal" compression). Note that tests have
* shown that zlib compression levels 3-6 usually perform as well as level 9
* for PNG images, and do considerably fewer caclulations. In the future,
* for PNG images, and do considerably fewer calculations. In the future,
* these values may not correspond directly to the zlib compression levels.
*/
#ifdef PNG_WRITE_CUSTOMIZE_COMPRESSION_SUPPORTED

View file

@ -1,9 +1,9 @@
/* pngconf.h - machine-configurable file for libpng
*
* libpng version 1.6.37
* libpng version 1.6.38
*
* Copyright (c) 2018-2019 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 1998-2002,2004,2006-2016,2018 Glenn Randers-Pehrson
* Copyright (c) 1996-1997 Andreas Dilger
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -180,8 +180,8 @@
* compiler-specific macros to the values required to change the calling
* conventions of the various functions.
*/
#if defined(_Windows) || defined(_WINDOWS) || defined(WIN32) ||\
defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
#if defined(_WIN32) || defined(__WIN32__) || defined(__NT__) || \
defined(__CYGWIN__)
/* Windows system (DOS doesn't support DLLs). Includes builds under Cygwin or
* MinGW on any architecture currently supported by Windows. Also includes
* Watcom builds but these need special treatment because they are not

View file

@ -1151,7 +1151,7 @@ png_get_unknown_chunks(png_const_structrp png_ptr, png_inforp info_ptr,
#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED
png_byte PNGAPI
png_get_rgb_to_gray_status (png_const_structrp png_ptr)
png_get_rgb_to_gray_status(png_const_structrp png_ptr)
{
return (png_byte)(png_ptr ? png_ptr->rgb_to_gray_status : 0);
}
@ -1192,27 +1192,27 @@ png_get_compression_buffer_size(png_const_structrp png_ptr)
/* These functions were added to libpng 1.2.6 and were enabled
* by default in libpng-1.4.0 */
png_uint_32 PNGAPI
png_get_user_width_max (png_const_structrp png_ptr)
png_get_user_width_max(png_const_structrp png_ptr)
{
return (png_ptr ? png_ptr->user_width_max : 0);
}
png_uint_32 PNGAPI
png_get_user_height_max (png_const_structrp png_ptr)
png_get_user_height_max(png_const_structrp png_ptr)
{
return (png_ptr ? png_ptr->user_height_max : 0);
}
/* This function was added to libpng 1.4.0 */
png_uint_32 PNGAPI
png_get_chunk_cache_max (png_const_structrp png_ptr)
png_get_chunk_cache_max(png_const_structrp png_ptr)
{
return (png_ptr ? png_ptr->user_chunk_cache_max : 0);
}
/* This function was added to libpng 1.4.1 */
png_alloc_size_t PNGAPI
png_get_chunk_malloc_max (png_const_structrp png_ptr)
png_get_chunk_malloc_max(png_const_structrp png_ptr)
{
return (png_ptr ? png_ptr->user_chunk_malloc_max : 0);
}
@ -1221,13 +1221,13 @@ png_get_chunk_malloc_max (png_const_structrp png_ptr)
/* These functions were added to libpng 1.4.0 */
#ifdef PNG_IO_STATE_SUPPORTED
png_uint_32 PNGAPI
png_get_io_state (png_const_structrp png_ptr)
png_get_io_state(png_const_structrp png_ptr)
{
return png_ptr->io_state;
}
png_uint_32 PNGAPI
png_get_io_chunk_type (png_const_structrp png_ptr)
png_get_io_chunk_type(png_const_structrp png_ptr)
{
return png_ptr->chunk_name;
}

View file

@ -1,7 +1,7 @@
/* pngpriv.h - private declarations for use inside libpng
*
* Copyright (c) 2018-2019 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson
* Copyright (c) 1996-1997 Andreas Dilger
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -174,7 +174,7 @@
# else /* !defined __ARM_NEON__ */
/* The 'intrinsics' code simply won't compile without this -mfpu=neon:
*/
# if !defined(__aarch64__)
# if !defined(__aarch64__) && !defined(_M_ARM64)
/* The assembler code currently does not work on ARM64 */
# define PNG_ARM_NEON_IMPLEMENTATION 2
# endif /* __aarch64__ */
@ -185,6 +185,8 @@
/* Use the intrinsics code by default. */
# define PNG_ARM_NEON_IMPLEMENTATION 1
# endif
#else /* PNG_ARM_NEON_OPT == 0 */
# define PNG_ARM_NEON_IMPLEMENTATION 0
#endif /* PNG_ARM_NEON_OPT > 0 */
#ifndef PNG_MIPS_MSA_OPT
@ -263,11 +265,15 @@
# ifndef PNG_MIPS_MSA_IMPLEMENTATION
# define PNG_MIPS_MSA_IMPLEMENTATION 1
# endif
#else
# define PNG_MIPS_MSA_IMPLEMENTATION 0
#endif /* PNG_MIPS_MSA_OPT > 0 */
#if PNG_POWERPC_VSX_OPT > 0
# define PNG_FILTER_OPTIMIZATIONS png_init_filter_functions_vsx
# define PNG_POWERPC_VSX_IMPLEMENTATION 1
#else
# define PNG_POWERPC_VSX_IMPLEMENTATION 0
#endif
@ -492,16 +498,7 @@
static_cast<type>(static_cast<const void*>(value))
#else
# define png_voidcast(type, value) (value)
# ifdef _WIN64
# ifdef __GNUC__
typedef unsigned long long png_ptruint;
# else
typedef unsigned __int64 png_ptruint;
# endif
# else
typedef unsigned long png_ptruint;
# endif
# define png_constcast(type, value) ((type)(png_ptruint)(const void*)(value))
# define png_constcast(type, value) ((type)(void*)(const void*)(value))
# define png_aligncast(type, value) ((void*)(value))
# define png_aligncastconst(type, value) ((const void*)(value))
#endif /* __cplusplus */
@ -543,9 +540,8 @@
# include <alloc.h>
#endif
#if defined(WIN32) || defined(_Windows) || defined(_WINDOWS) || \
defined(_WIN32) || defined(__WIN32__)
# include <windows.h> /* defines _WINDOWS_ macro */
#if defined(_WIN32) || defined(__WIN32__) || defined(__NT__)
# include <windows.h>
#endif
#endif /* PNG_VERSION_INFO_ONLY */
@ -554,24 +550,20 @@
* functions that are passed far data must be model-independent.
*/
/* Memory model/platform independent fns */
/* Platform-independent functions */
#ifndef PNG_ABORT
# ifdef _WINDOWS_
# define PNG_ABORT() ExitProcess(0)
# else
# define PNG_ABORT() abort()
# endif
# define PNG_ABORT() abort()
#endif
/* These macros may need to be architecture dependent. */
#define PNG_ALIGN_NONE 0 /* do not use data alignment */
#define PNG_ALIGN_ALWAYS 1 /* assume unaligned accesses are OK */
#define PNG_ALIGN_NONE 0 /* do not use data alignment */
#define PNG_ALIGN_ALWAYS 1 /* assume unaligned accesses are OK */
#ifdef offsetof
# define PNG_ALIGN_OFFSET 2 /* use offsetof to determine alignment */
# define PNG_ALIGN_OFFSET 2 /* use offsetof to determine alignment */
#else
# define PNG_ALIGN_OFFSET -1 /* prevent the use of this */
#endif
#define PNG_ALIGN_SIZE 3 /* use sizeof to determine alignment */
#define PNG_ALIGN_SIZE 3 /* use sizeof to determine alignment */
#ifndef PNG_ALIGN_TYPE
/* Default to using aligned access optimizations and requiring alignment to a
@ -585,26 +577,25 @@
/* This is used because in some compiler implementations non-aligned
* structure members are supported, so the offsetof approach below fails.
* Set PNG_ALIGN_SIZE=0 for compiler combinations where unaligned access
* is good for performance. Do not do this unless you have tested the result
* and understand it.
* is good for performance. Do not do this unless you have tested the
* result and understand it.
*/
# define png_alignof(type) (sizeof (type))
# define png_alignof(type) (sizeof(type))
#else
# if PNG_ALIGN_TYPE == PNG_ALIGN_OFFSET
# define png_alignof(type) offsetof(struct{char c; type t;}, t)
# define png_alignof(type) offsetof(struct{char c; type t;}, t)
# else
# if PNG_ALIGN_TYPE == PNG_ALIGN_ALWAYS
# define png_alignof(type) (1)
# endif
/* Else leave png_alignof undefined to prevent use thereof */
# if PNG_ALIGN_TYPE == PNG_ALIGN_ALWAYS
# define png_alignof(type) 1
# endif
/* Else leave png_alignof undefined to prevent use thereof */
# endif
#endif
/* This implicitly assumes alignment is always to a power of 2. */
/* This implicitly assumes alignment is always a multiple of 2. */
#ifdef png_alignof
# define png_isaligned(ptr, type)\
(((type)((const char*)ptr-(const char*)0) & \
(type)(png_alignof(type)-1)) == 0)
# define png_isaligned(ptr, type) \
(((type)(size_t)((const void*)(ptr)) & (type)(png_alignof(type)-1)) == 0)
#else
# define png_isaligned(ptr, type) 0
#endif

View file

@ -3452,7 +3452,6 @@ png_image_read_background(png_voidp argument)
for (pass = 0; pass < passes; ++pass)
{
png_bytep row = png_voidcast(png_bytep, display->first_row);
unsigned int startx, stepx, stepy;
png_uint_32 y;
@ -3557,8 +3556,6 @@ png_image_read_background(png_voidp argument)
inrow += 2; /* gray and alpha channel */
}
row += display->row_bytes;
}
}
}

View file

@ -21,7 +21,7 @@
#ifdef PNG_ARM_NEON_IMPLEMENTATION
# if PNG_ARM_NEON_IMPLEMENTATION == 1
# define PNG_ARM_NEON_INTRINSICS_AVAILABLE
# if defined(_MSC_VER) && defined(_M_ARM64)
# if defined(_MSC_VER) && !defined(__clang__) && defined(_M_ARM64)
# include <arm64_neon.h>
# else
# include <arm_neon.h>

View file

@ -1,7 +1,7 @@
/* pngrutil.c - utilities to read a PNG file
*
* Copyright (c) 2018 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson
* Copyright (c) 1996-1997 Andreas Dilger
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -301,7 +301,6 @@ png_read_buffer(png_structrp png_ptr, png_alloc_size_t new_size, int warn)
if (buffer != NULL && new_size > png_ptr->read_buffer_size)
{
png_ptr->read_buffer = NULL;
png_ptr->read_buffer = NULL;
png_ptr->read_buffer_size = 0;
png_free(png_ptr, buffer);
@ -2076,21 +2075,22 @@ png_handle_eXIf(png_structrp png_ptr, png_inforp info_ptr, png_uint_32 length)
png_byte buf[1];
png_crc_read(png_ptr, buf, 1);
info_ptr->eXIf_buf[i] = buf[0];
if (i == 1 && buf[0] != 'M' && buf[0] != 'I'
&& info_ptr->eXIf_buf[0] != buf[0])
if (i == 1)
{
png_crc_finish(png_ptr, length);
png_chunk_benign_error(png_ptr, "incorrect byte-order specifier");
png_free(png_ptr, info_ptr->eXIf_buf);
info_ptr->eXIf_buf = NULL;
return;
if ((buf[0] != 'M' && buf[0] != 'I') ||
(info_ptr->eXIf_buf[0] != buf[0]))
{
png_crc_finish(png_ptr, length - 2);
png_chunk_benign_error(png_ptr, "incorrect byte-order specifier");
png_free(png_ptr, info_ptr->eXIf_buf);
info_ptr->eXIf_buf = NULL;
return;
}
}
}
if (png_crc_finish(png_ptr, 0) != 0)
return;
png_set_eXIf_1(png_ptr, info_ptr, length, info_ptr->eXIf_buf);
if (png_crc_finish(png_ptr, 0) == 0)
png_set_eXIf_1(png_ptr, info_ptr, length, info_ptr->eXIf_buf);
png_free(png_ptr, info_ptr->eXIf_buf);
info_ptr->eXIf_buf = NULL;
@ -2126,8 +2126,9 @@ png_handle_hIST(png_structrp png_ptr, png_inforp info_ptr, png_uint_32 length)
num = length / 2 ;
if (num != (unsigned int) png_ptr->num_palette ||
num > (unsigned int) PNG_MAX_PALETTE_LENGTH)
if (length != num * 2 ||
num != (unsigned int)png_ptr->num_palette ||
num > (unsigned int)PNG_MAX_PALETTE_LENGTH)
{
png_crc_finish(png_ptr, length);
png_chunk_benign_error(png_ptr, "invalid");
@ -4621,14 +4622,13 @@ defined(PNG_USER_TRANSFORM_PTR_SUPPORTED)
*/
{
png_bytep temp = png_ptr->big_row_buf + 32;
int extra = (int)((temp - (png_bytep)0) & 0x0f);
size_t extra = (size_t)temp & 0x0f;
png_ptr->row_buf = temp - extra - 1/*filter byte*/;
temp = png_ptr->big_prev_row + 32;
extra = (int)((temp - (png_bytep)0) & 0x0f);
extra = (size_t)temp & 0x0f;
png_ptr->prev_row = temp - extra - 1/*filter byte*/;
}
#else
/* Use 31 bytes of padding before and 17 bytes after row_buf. */
png_ptr->row_buf = png_ptr->big_row_buf + 31;

View file

@ -1,7 +1,7 @@
/* pngset.c - storage of image information into info struct
*
* Copyright (c) 2018 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 1998-2018 Glenn Randers-Pehrson
* Copyright (c) 1996-1997 Andreas Dilger
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -1019,6 +1019,9 @@ png_set_tRNS(png_structrp png_ptr, png_inforp info_ptr,
info_ptr->trans_alpha = png_voidcast(png_bytep,
png_malloc(png_ptr, PNG_MAX_PALETTE_LENGTH));
memcpy(info_ptr->trans_alpha, trans_alpha, (size_t)num_trans);
info_ptr->valid |= PNG_INFO_tRNS;
info_ptr->free_me |= PNG_FREE_TRNS;
}
png_ptr->trans_alpha = info_ptr->trans_alpha;
}
@ -1326,7 +1329,7 @@ png_set_unknown_chunk_location(png_const_structrp png_ptr, png_inforp info_ptr,
#ifdef PNG_MNG_FEATURES_SUPPORTED
png_uint_32 PNGAPI
png_permit_mng_features (png_structrp png_ptr, png_uint_32 mng_features)
png_permit_mng_features(png_structrp png_ptr, png_uint_32 mng_features)
{
png_debug(1, "in png_permit_mng_features");
@ -1633,7 +1636,7 @@ png_set_invalid(png_const_structrp png_ptr, png_inforp info_ptr, int mask)
#ifdef PNG_SET_USER_LIMITS_SUPPORTED
/* This function was added to libpng 1.2.6 */
void PNGAPI
png_set_user_limits (png_structrp png_ptr, png_uint_32 user_width_max,
png_set_user_limits(png_structrp png_ptr, png_uint_32 user_width_max,
png_uint_32 user_height_max)
{
/* Images with dimensions larger than these limits will be
@ -1649,7 +1652,7 @@ png_set_user_limits (png_structrp png_ptr, png_uint_32 user_width_max,
/* This function was added to libpng 1.4.0 */
void PNGAPI
png_set_chunk_cache_max (png_structrp png_ptr, png_uint_32 user_chunk_cache_max)
png_set_chunk_cache_max(png_structrp png_ptr, png_uint_32 user_chunk_cache_max)
{
if (png_ptr != NULL)
png_ptr->user_chunk_cache_max = user_chunk_cache_max;
@ -1657,7 +1660,7 @@ png_set_chunk_cache_max (png_structrp png_ptr, png_uint_32 user_chunk_cache_max)
/* This function was added to libpng 1.4.1 */
void PNGAPI
png_set_chunk_malloc_max (png_structrp png_ptr,
png_set_chunk_malloc_max(png_structrp png_ptr,
png_alloc_size_t user_chunk_malloc_max)
{
if (png_ptr != NULL)

View file

@ -1,7 +1,7 @@
/* pngstruct.h - header file for PNG reference library
*
* Copyright (c) 2018-2019 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson
* Copyright (c) 1996-1997 Andreas Dilger
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -334,18 +334,8 @@ struct png_struct_def
size_t current_buffer_size; /* amount of data now in current_buffer */
int process_mode; /* what push library is currently doing */
int cur_palette; /* current push library palette index */
#endif /* PROGRESSIVE_READ */
#if defined(__TURBOC__) && !defined(_Windows) && !defined(__FLAT__)
/* For the Borland special 64K segment handler */
png_bytepp offset_table_ptr;
png_bytep offset_table;
png_uint_16 offset_table_number;
png_uint_16 offset_table_count;
png_uint_16 offset_table_count_free;
#endif
#ifdef PNG_READ_QUANTIZE_SUPPORTED
png_bytep palette_lookup; /* lookup table for quantizing */
png_bytep quantize_index; /* index translation for palette files */

View file

@ -2155,4 +2155,4 @@ main(void)
#endif
/* Generate a compiler error if there is an old png.h in the search path. */
typedef png_libpng_version_1_6_37 Your_png_h_is_not_version_1_6_37;
typedef png_libpng_version_1_6_38 Your_png_h_is_not_version_1_6_38;

View file

@ -1,7 +1,7 @@
/* pngwrite.c - general routines to write a PNG file
*
* Copyright (c) 2018-2019 Cosmin Truta
* Copyright (c) 2018-2022 Cosmin Truta
* Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson
* Copyright (c) 1996-1997 Andreas Dilger
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@ -489,6 +489,16 @@ png_convert_from_time_t(png_timep ptime, time_t ttime)
png_debug(1, "in png_convert_from_time_t");
tbuf = gmtime(&ttime);
if (tbuf == NULL)
{
/* TODO: add a safe function which takes a png_ptr argument and raises
* a png_error if the ttime argument is invalid and the call to gmtime
* fails as a consequence.
*/
memset(ptime, 0, sizeof(*ptime));
return;
}
png_convert_from_struct_tm(ptime, tbuf);
}
#endif

View file

@ -1,7 +1,7 @@
Instructions for building libpng using Microsoft Visual Studio
==============================================================
Copyright (c) 2018 Cosmin Truta
Copyright (c) 2018,2022 Cosmin Truta
Copyright (c) 2010,2013,2015 Glenn Randers-Pehrson
This code is released under the libpng license.
@ -9,9 +9,9 @@ For conditions of distribution and use, see the disclaimer and license
in png.h
This directory contains a solution for building libpng under Microsoft
Visual Studio 2010. It may also work under later versions of Visual
Studio. You should be familiar with Visual Studio before using this
solution.
Visual Studio 2019. It may also work under earlier or later versions
of Visual Studio. You should be familiar with Visual Studio before
using this solution.
Initial preparations
--------------------

View file

@ -1,18 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug Library|ARM64">
<Configuration>Debug Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug Library|Win32">
<Configuration>Debug Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|ARM64">
<Configuration>Release Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|Win32">
<Configuration>Release Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@ -29,19 +45,45 @@
<ConfigurationType>DynamicLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
@ -49,15 +91,27 @@
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>false</LinkIncremental>
@ -65,22 +119,42 @@
</CustomBuildBeforeTargets>
<TargetName>$(ProjectName)16</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildBeforeTargets />
<TargetName>$(ProjectName)16</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildBeforeTargets />
<TargetName>$(ProjectName)16</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildBeforeTargets />
<TargetName>$(ProjectName)16</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildBeforeTargets>
</CustomBuildBeforeTargets>
<TargetName>$(ProjectName)16</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildBeforeTargets />
<TargetName>$(ProjectName)16</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildBeforeTargets />
<TargetName>$(ProjectName)16</TargetName>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildBeforeTargets />
<TargetName>$(ProjectName)16</TargetName>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>Use</PrecompiledHeader>
@ -88,7 +162,37 @@
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;_DEBUG;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<IntrinsicFunctions>true</IntrinsicFunctions>
<FunctionLevelLinking>true</FunctionLevelLinking>
<FloatingPointExceptions>false</FloatingPointExceptions>
<TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
<PrecompiledHeaderFile>pngpriv.h</PrecompiledHeaderFile>
<BrowseInformation>true</BrowseInformation>
<CompileAs>CompileAsC</CompileAs>
<StringPooling>true</StringPooling>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<AdditionalIncludeDirectories>$(ZLibSrcDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<Optimization>Disabled</Optimization>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>zlib.lib</AdditionalDependencies>
<Version>16</Version>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<ClCompile>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<PreprocessorDefinitions>WIN32;_DEBUG;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<IntrinsicFunctions>true</IntrinsicFunctions>
<FunctionLevelLinking>true</FunctionLevelLinking>
<FloatingPointExceptions>false</FloatingPointExceptions>
@ -114,12 +218,12 @@
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<ClCompile>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<IntrinsicFunctions>true</IntrinsicFunctions>
<FunctionLevelLinking>true</FunctionLevelLinking>
<FloatingPointExceptions>false</FloatingPointExceptions>
@ -130,7 +234,34 @@
<StringPooling>true</StringPooling>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<AdditionalIncludeDirectories>$(ZLibSrcDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<ClCompile>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<PreprocessorDefinitions>WIN32;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<IntrinsicFunctions>true</IntrinsicFunctions>
<FunctionLevelLinking>true</FunctionLevelLinking>
<FloatingPointExceptions>false</FloatingPointExceptions>
<TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
<PrecompiledHeaderFile>pngpriv.h</PrecompiledHeaderFile>
<BrowseInformation>true</BrowseInformation>
<CompileAs>CompileAsC</CompileAs>
<StringPooling>true</StringPooling>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<AdditionalIncludeDirectories>$(ZLibSrcDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<TreatWarningAsError>false</TreatWarningAsError>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
</ClCompile>
<Link>
@ -145,7 +276,37 @@
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;NDEBUG;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FloatingPointExceptions>false</FloatingPointExceptions>
<TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
<PrecompiledHeaderFile>pngpriv.h</PrecompiledHeaderFile>
<BrowseInformation>true</BrowseInformation>
<CompileAs>CompileAsC</CompileAs>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<AdditionalIncludeDirectories>$(ZLibSrcDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<Optimization>Full</Optimization>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>zlib.lib</AdditionalDependencies>
<Version>16</Version>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<PrecompiledHeader>Use</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FloatingPointExceptions>false</FloatingPointExceptions>
<TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
<PrecompiledHeaderFile>pngpriv.h</PrecompiledHeaderFile>
@ -170,13 +331,13 @@
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>Use</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FloatingPointExceptions>false</FloatingPointExceptions>
<TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
<PrecompiledHeaderFile>pngpriv.h</PrecompiledHeaderFile>
@ -186,7 +347,39 @@
<MinimalRebuild>false</MinimalRebuild>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<AdditionalIncludeDirectories>$(ZLibSrcDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<Optimization>Full</Optimization>
<WholeProgramOptimization>true</WholeProgramOptimization>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
<Lib>
<LinkTimeCodeGeneration>true</LinkTimeCodeGeneration>
</Lib>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>Use</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<FloatingPointExceptions>false</FloatingPointExceptions>
<TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
<PrecompiledHeaderFile>pngpriv.h</PrecompiledHeaderFile>
<BrowseInformation>true</BrowseInformation>
<CompileAs>CompileAsC</CompileAs>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<AdditionalIncludeDirectories>$(ZLibSrcDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<TreatWarningAsError>false</TreatWarningAsError>
<Optimization>Full</Optimization>
<WholeProgramOptimization>true</WholeProgramOptimization>
</ClCompile>
@ -201,11 +394,40 @@
</Lib>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\..\..\arm\arm_init.c">
<DeploymentContent>true</DeploymentContent>
<PreprocessorDefinitions Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">WIN32;_DEBUG;PNG_ARM_NEON_OPT=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">NotUsing</PrecompiledHeader>
</ClCompile>
<ClCompile Include="..\..\..\arm\filter_neon_intrinsics.c">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">NotUsing</PrecompiledHeader>
<PreprocessorDefinitions Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">WIN32;_DEBUG;PNG_ARM_NEON_OPT=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">NotUsing</PrecompiledHeader>
</ClCompile>
<ClCompile Include="..\..\..\arm\palette_neon_intrinsics.c">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">NotUsing</PrecompiledHeader>
<PreprocessorDefinitions Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">WIN32;_DEBUG;PNG_ARM_NEON_OPT=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">NotUsing</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">NotUsing</PrecompiledHeader>
</ClCompile>
<ClCompile Include="..\..\..\png.c">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">Create</PrecompiledHeader>
</ClCompile>
<ClCompile Include="..\..\..\pngerror.c" />
<ClCompile Include="..\..\..\pngget.c" />
@ -225,7 +447,9 @@
<ItemGroup>
<ResourceCompile Include="..\..\..\scripts\pngwin.rc">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">true</ExcludedFromBuild>
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">true</ExcludedFromBuild>
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">true</ExcludedFromBuild>
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">true</ExcludedFromBuild>
</ResourceCompile>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />

View file

@ -1,6 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@ -16,6 +20,14 @@
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(SolutionDir)\zlib.props" />
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
@ -24,10 +36,16 @@
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<CustomBuildBeforeTargets>Build</CustomBuildBeforeTargets>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<CustomBuildBeforeTargets>Build</CustomBuildBeforeTargets>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
@ -53,6 +71,31 @@
<Inputs>..\..\..\scripts\pnglibconf.h.prebuilt</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
</ClCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
<CustomBuildStep>
<Command>copy ..\..\..\scripts\pnglibconf.h.prebuilt ..\..\..\pnglibconf.h</Command>
</CustomBuildStep>
<CustomBuildStep>
<Message>Generating pnglibconf.h</Message>
</CustomBuildStep>
<CustomBuildStep>
<Outputs>..\..\..\pnglibconf.h</Outputs>
</CustomBuildStep>
<CustomBuildStep>
<Inputs>..\..\..\scripts\pnglibconf.h.prebuilt</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemGroup>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />

View file

@ -1,18 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug Library|ARM64">
<Configuration>Debug Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug Library|Win32">
<Configuration>Debug Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|ARM64">
<Configuration>Release Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|Win32">
<Configuration>Release Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@ -28,18 +44,42 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
@ -47,36 +87,64 @@
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
@ -85,7 +153,40 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
<BrowseInformation>true</BrowseInformation>
<FloatingPointExceptions>false</FloatingPointExceptions>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>libpng16.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing libpng simplified API test program</Message>
<Command>"$(OutDir)pngstest.exe" --strict --log --touch "$(IntDir)pngstest.out" ../../../contrib/pngsuite/basn0g01.png ../../../contrib/pngsuite/basn0g02.png ../../../contrib/pngsuite/basn0g04.png ../../../contrib/pngsuite/basn0g08.png ../../../contrib/pngsuite/basn0g16.png ../../../contrib/pngsuite/basn2c08.png ../../../contrib/pngsuite/basn2c16.png ../../../contrib/pngsuite/basn3p01.png ../../../contrib/pngsuite/basn3p02.png ../../../contrib/pngsuite/basn3p04.png ../../../contrib/pngsuite/basn3p08.png ../../../contrib/pngsuite/basn4a08.png ../../../contrib/pngsuite/basn4a16.png ../../../contrib/pngsuite/basn6a08.png ../../../contrib/pngsuite/basn6a16.png ../../../contrib/pngsuite/ftbbn0g01.png ../../../contrib/pngsuite/ftbbn0g02.png ../../../contrib/pngsuite/ftbbn0g04.png ../../../contrib/pngsuite/ftbbn2c16.png ../../../contrib/pngsuite/ftbbn3p08.png ../../../contrib/pngsuite/ftbgn2c16.png ../../../contrib/pngsuite/ftbgn3p08.png ../../../contrib/pngsuite/ftbrn2c08.png ../../../contrib/pngsuite/ftbwn0g16.png ../../../contrib/pngsuite/ftbwn3p08.png ../../../contrib/pngsuite/ftbyn3p08.png ../../../contrib/pngsuite/ftp0n0g08.png ../../../contrib/pngsuite/ftp0n2c08.png ../../../contrib/pngsuite/ftp0n3p08.png ../../../contrib/pngsuite/ftp1n3p08.png</Command>
<Outputs>$(IntDir)pngstest.out</Outputs>
<Inputs>$(OutDir)pngstest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;PNG_USE_DLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
@ -109,7 +210,7 @@
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
@ -119,7 +220,40 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
<BrowseInformation>true</BrowseInformation>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing libpng simplified API test program</Message>
<Command>"$(OutDir)pngstest.exe" --strict --log --touch "$(IntDir)pngstest.out" ../../../contrib/pngsuite/basn0g01.png ../../../contrib/pngsuite/basn0g02.png ../../../contrib/pngsuite/basn0g04.png ../../../contrib/pngsuite/basn0g08.png ../../../contrib/pngsuite/basn0g16.png ../../../contrib/pngsuite/basn2c08.png ../../../contrib/pngsuite/basn2c16.png ../../../contrib/pngsuite/basn3p01.png ../../../contrib/pngsuite/basn3p02.png ../../../contrib/pngsuite/basn3p04.png ../../../contrib/pngsuite/basn3p08.png ../../../contrib/pngsuite/basn4a08.png ../../../contrib/pngsuite/basn4a16.png ../../../contrib/pngsuite/basn6a08.png ../../../contrib/pngsuite/basn6a16.png ../../../contrib/pngsuite/ftbbn0g01.png ../../../contrib/pngsuite/ftbbn0g02.png ../../../contrib/pngsuite/ftbbn0g04.png ../../../contrib/pngsuite/ftbbn2c16.png ../../../contrib/pngsuite/ftbbn3p08.png ../../../contrib/pngsuite/ftbgn2c16.png ../../../contrib/pngsuite/ftbgn3p08.png ../../../contrib/pngsuite/ftbrn2c08.png ../../../contrib/pngsuite/ftbwn0g16.png ../../../contrib/pngsuite/ftbwn3p08.png ../../../contrib/pngsuite/ftbyn3p08.png ../../../contrib/pngsuite/ftp0n0g08.png ../../../contrib/pngsuite/ftp0n2c08.png ../../../contrib/pngsuite/ftp0n3p08.png ../../../contrib/pngsuite/ftp1n3p08.png</Command>
<Outputs>$(IntDir)pngstest.out</Outputs>
<Inputs>$(OutDir)pngstest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
@ -174,12 +308,47 @@
<Inputs>$(OutDir)pngstest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;PNG_USE_DLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>
<WholeProgramOptimization>true</WholeProgramOptimization>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>libpng16.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
</Link>
<CustomBuildStep>
<Message>Executing libpng simplified API test program</Message>
<Command>"$(OutDir)pngstest.exe" --strict --log --touch "$(IntDir)pngstest.out" ../../../contrib/pngsuite/basn0g01.png ../../../contrib/pngsuite/basn0g02.png ../../../contrib/pngsuite/basn0g04.png ../../../contrib/pngsuite/basn0g08.png ../../../contrib/pngsuite/basn0g16.png ../../../contrib/pngsuite/basn2c08.png ../../../contrib/pngsuite/basn2c16.png ../../../contrib/pngsuite/basn3p01.png ../../../contrib/pngsuite/basn3p02.png ../../../contrib/pngsuite/basn3p04.png ../../../contrib/pngsuite/basn3p08.png ../../../contrib/pngsuite/basn4a08.png ../../../contrib/pngsuite/basn4a16.png ../../../contrib/pngsuite/basn6a08.png ../../../contrib/pngsuite/basn6a16.png ../../../contrib/pngsuite/ftbbn0g01.png ../../../contrib/pngsuite/ftbbn0g02.png ../../../contrib/pngsuite/ftbbn0g04.png ../../../contrib/pngsuite/ftbbn2c16.png ../../../contrib/pngsuite/ftbbn3p08.png ../../../contrib/pngsuite/ftbgn2c16.png ../../../contrib/pngsuite/ftbgn3p08.png ../../../contrib/pngsuite/ftbrn2c08.png ../../../contrib/pngsuite/ftbwn0g16.png ../../../contrib/pngsuite/ftbwn3p08.png ../../../contrib/pngsuite/ftbyn3p08.png ../../../contrib/pngsuite/ftp0n0g08.png ../../../contrib/pngsuite/ftp0n2c08.png ../../../contrib/pngsuite/ftp0n3p08.png ../../../contrib/pngsuite/ftp1n3p08.png</Command>
<Outputs>$(IntDir)pngstest.out</Outputs>
<Inputs>$(OutDir)pngstest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
@ -187,7 +356,43 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>
<WholeProgramOptimization>true</WholeProgramOptimization>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
</Link>
<CustomBuildStep>
<Message>Executing libpng simplified API test program</Message>
<Command>"$(OutDir)pngstest.exe" --strict --log --touch "$(IntDir)pngstest.out" ../../../contrib/pngsuite/basn0g01.png ../../../contrib/pngsuite/basn0g02.png ../../../contrib/pngsuite/basn0g04.png ../../../contrib/pngsuite/basn0g08.png ../../../contrib/pngsuite/basn0g16.png ../../../contrib/pngsuite/basn2c08.png ../../../contrib/pngsuite/basn2c16.png ../../../contrib/pngsuite/basn3p01.png ../../../contrib/pngsuite/basn3p02.png ../../../contrib/pngsuite/basn3p04.png ../../../contrib/pngsuite/basn3p08.png ../../../contrib/pngsuite/basn4a08.png ../../../contrib/pngsuite/basn4a16.png ../../../contrib/pngsuite/basn6a08.png ../../../contrib/pngsuite/basn6a16.png ../../../contrib/pngsuite/ftbbn0g01.png ../../../contrib/pngsuite/ftbbn0g02.png ../../../contrib/pngsuite/ftbbn0g04.png ../../../contrib/pngsuite/ftbbn2c16.png ../../../contrib/pngsuite/ftbbn3p08.png ../../../contrib/pngsuite/ftbgn2c16.png ../../../contrib/pngsuite/ftbgn3p08.png ../../../contrib/pngsuite/ftbrn2c08.png ../../../contrib/pngsuite/ftbwn0g16.png ../../../contrib/pngsuite/ftbwn3p08.png ../../../contrib/pngsuite/ftbyn3p08.png ../../../contrib/pngsuite/ftp0n0g08.png ../../../contrib/pngsuite/ftp0n2c08.png ../../../contrib/pngsuite/ftp0n3p08.png ../../../contrib/pngsuite/ftp1n3p08.png</Command>
<Outputs>$(IntDir)pngstest.out</Outputs>
<Inputs>$(OutDir)pngstest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>

View file

@ -1,18 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug Library|ARM64">
<Configuration>Debug Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug Library|Win32">
<Configuration>Debug Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|ARM64">
<Configuration>Release Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|Win32">
<Configuration>Release Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@ -28,18 +44,42 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
@ -47,36 +87,64 @@
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
@ -85,7 +153,40 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
<BrowseInformation>true</BrowseInformation>
<FloatingPointExceptions>false</FloatingPointExceptions>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>libpng16.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing PNG test program</Message>
<Command>"$(OutDir)pngtest.exe" ..\..\..\pngtest.png "$(IntDir)pngout.png"</Command>
<Outputs>$(IntDir)pngout.png</Outputs>
<Inputs>..\..\..\pngtest.png;$(OutDir)pngtest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
@ -109,7 +210,7 @@
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
@ -119,7 +220,40 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
<BrowseInformation>true</BrowseInformation>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing PNG test program</Message>
<Command>"$(OutDir)pngtest.exe" ..\..\..\pngtest.png "$(IntDir)pngout.png"</Command>
<Outputs>$(IntDir)pngout.png</Outputs>
<Inputs>..\..\..\pngtest.png;$(OutDir)pngtest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
@ -174,12 +308,47 @@
<Inputs>..\..\..\pngtest.png;$(OutDir)pngtest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>
<WholeProgramOptimization>true</WholeProgramOptimization>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
<AdditionalDependencies>libpng16.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing PNG test program</Message>
<Command>"$(OutDir)pngtest.exe" ..\..\..\pngtest.png "$(IntDir)pngout.png"</Command>
<Outputs>$(IntDir)pngout.png</Outputs>
<Inputs>..\..\..\pngtest.png;$(OutDir)pngtest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
@ -187,7 +356,44 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>
<WholeProgramOptimization>true</WholeProgramOptimization>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing PNG test program</Message>
<Command>$(OutDir)pngtest.exe ..\..\..\pngtest.png $(IntDir)pngout.png</Command>
<Command>"$(OutDir)pngtest.exe" ..\..\..\pngtest.png "$(IntDir)pngout.png"</Command>
<Outputs>$(IntDir)pngout.png</Outputs>
<Inputs>..\..\..\pngtest.png;$(OutDir)pngtest.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>

View file

@ -1,18 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug Library|ARM64">
<Configuration>Debug Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug Library|Win32">
<Configuration>Debug Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|ARM64">
<Configuration>Release Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|Win32">
<Configuration>Release Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@ -28,18 +44,42 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
@ -47,36 +87,64 @@
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
@ -85,7 +153,40 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
<BrowseInformation>true</BrowseInformation>
<FloatingPointExceptions>false</FloatingPointExceptions>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>libpng16.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing PNG validation program</Message>
<Command>"$(OutDir)pngunknown.exe" --strict --default --touch "$(IntDir)pngunknown.out" ../../../pngtest.png</Command>
<Outputs>$(IntDir)pngunknown.out</Outputs>
<Inputs>$(OutDir)pngunknown.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;PNG_USE_DLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
@ -109,7 +210,7 @@
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
@ -119,7 +220,40 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
<BrowseInformation>true</BrowseInformation>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing PNG validation program</Message>
<Command>"$(OutDir)pngunknown.exe" --strict --default --touch "$(IntDir)pngunknown.out" ../../../pngtest.png</Command>
<Outputs>$(IntDir)pngunknown.out</Outputs>
<Inputs>$(OutDir)pngunknown.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
@ -174,12 +308,47 @@
<Inputs>$(OutDir)pngunknown.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;PNG_USE_DLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>
<WholeProgramOptimization>true</WholeProgramOptimization>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>libpng16.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
</Link>
<CustomBuildStep>
<Message>Executing PNG validation program</Message>
<Command>"$(OutDir)pngunknown.exe" --strict --default --touch "$(IntDir)pngunknown.out" ../../../pngtest.png</Command>
<Outputs>$(IntDir)pngunknown.out</Outputs>
<Inputs>$(OutDir)pngunknown.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
@ -187,7 +356,43 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>
<WholeProgramOptimization>true</WholeProgramOptimization>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
</Link>
<CustomBuildStep>
<Message>Executing PNG validation program</Message>
<Command>"$(OutDir)pngunknown.exe" --strict --default --touch "$(IntDir)pngunknown.out" ../../../pngtest.png</Command>
<Outputs>$(IntDir)pngunknown.out</Outputs>
<Inputs>$(OutDir)pngunknown.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>

View file

@ -1,18 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug Library|ARM64">
<Configuration>Debug Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug Library|Win32">
<Configuration>Debug Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|ARM64">
<Configuration>Release Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|Win32">
<Configuration>Release Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@ -28,18 +44,42 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
@ -47,36 +87,64 @@
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<LinkIncremental>false</LinkIncremental>
<CustomBuildAfterTargets />
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
@ -85,7 +153,40 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
<BrowseInformation>true</BrowseInformation>
<FloatingPointExceptions>false</FloatingPointExceptions>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing PNG validation program</Message>
<Command>"$(OutDir)pngvalid.exe" --touch "$(IntDir)pngvalid.out"</Command>
<Outputs>$(IntDir)pngvalid.out</Outputs>
<Inputs>$(OutDir)pngvalid.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;PNG_USE_DLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
@ -109,7 +210,7 @@
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
@ -119,7 +220,40 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
<BrowseInformation>true</BrowseInformation>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
</Link>
<CustomBuildStep>
<Message>Executing PNG validation program</Message>
<Command>"$(OutDir)pngvalid.exe" --touch "$(IntDir)pngvalid.out"</Command>
<Outputs>$(IntDir)pngvalid.out</Outputs>
<Inputs>$(OutDir)pngvalid.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<MinimalRebuild>false</MinimalRebuild>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<IntrinsicFunctions>true</IntrinsicFunctions>
<StringPooling>true</StringPooling>
<FunctionLevelLinking>false</FunctionLevelLinking>
@ -174,12 +308,47 @@
<Inputs>$(OutDir)pngvalid.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;PNG_USE_DLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>
<WholeProgramOptimization>true</WholeProgramOptimization>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
</Link>
<CustomBuildStep>
<Message>Executing PNG validation program</Message>
<Command>"$(OutDir)pngvalid.exe" --touch "$(IntDir)pngvalid.out"</Command>
<Outputs>$(IntDir)pngvalid.out</Outputs>
<Inputs>$(OutDir)pngvalid.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
@ -187,7 +356,43 @@
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>
<WholeProgramOptimization>true</WholeProgramOptimization>
<FloatingPointExceptions>false</FloatingPointExceptions>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>libpng16.lib;zlib.lib</AdditionalDependencies>
<AdditionalLibraryDirectories>$(OutDir)</AdditionalLibraryDirectories>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
</Link>
<CustomBuildStep>
<Message>Executing PNG validation program</Message>
<Command>"$(OutDir)pngvalid.exe" --touch "$(IntDir)pngvalid.out"</Command>
<Outputs>$(IntDir)pngvalid.out</Outputs>
<Inputs>$(OutDir)pngvalid.exe</Inputs>
</CustomBuildStep>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<FunctionLevelLinking>false</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>$(ZLibSrcDir);..\..\..\scripts;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<DisableSpecificWarnings>$(DisableSpecificWarnings)</DisableSpecificWarnings>
<CompileAsManaged>false</CompileAsManaged>
<TreatWarningAsError>false</TreatWarningAsError>
<StringPooling>true</StringPooling>
<MinimalRebuild>false</MinimalRebuild>
<BrowseInformation>true</BrowseInformation>

View file

@ -1,5 +1,7 @@
Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.31515.178
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "zlib", "zlib\zlib.vcxproj", "{60F89955-91C6-3A36-8000-13C592FEC2DF}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "pnglibconf", "pnglibconf\pnglibconf.vcxproj", "{EB33566E-DA7F-4D28-9077-88C0B7C77E35}"
@ -40,70 +42,133 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "pngunknown", "pngunknown\pn
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug Library|ARM64 = Debug Library|ARM64
Debug Library|Win32 = Debug Library|Win32
Debug|ARM64 = Debug|ARM64
Debug|Win32 = Debug|Win32
Release Library|ARM64 = Release Library|ARM64
Release Library|Win32 = Release Library|Win32
Release|ARM64 = Release|ARM64
Release|Win32 = Release|Win32
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug Library|Win32.Build.0 = Debug Library|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug|Win32.ActiveCfg = Debug|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug|Win32.Build.0 = Debug|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release Library|Win32.ActiveCfg = Release Library|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release Library|Win32.Build.0 = Release Library|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release|Win32.ActiveCfg = Release|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release|Win32.Build.0 = Release|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug Library|Win32.Build.0 = Debug Library|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug|Win32.ActiveCfg = Debug|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug|Win32.Build.0 = Debug|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release Library|Win32.ActiveCfg = Release Library|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release Library|Win32.Build.0 = Release Library|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release|Win32.ActiveCfg = Release|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release|Win32.Build.0 = Release|Win32
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Debug Library|ARM64.ActiveCfg = Debug Library|ARM64
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Debug Library|ARM64.Build.0 = Debug Library|ARM64
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Debug Library|Win32.Build.0 = Debug Library|Win32
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Debug|ARM64.ActiveCfg = Debug|ARM64
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Debug|ARM64.Build.0 = Debug|ARM64
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Debug|Win32.ActiveCfg = Debug|Win32
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Debug|Win32.Build.0 = Debug|Win32
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Release Library|ARM64.ActiveCfg = Release Library|ARM64
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Release Library|ARM64.Build.0 = Release Library|ARM64
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Release Library|Win32.ActiveCfg = Release Library|Win32
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Release Library|Win32.Build.0 = Release Library|Win32
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Release|ARM64.ActiveCfg = Release|ARM64
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Release|ARM64.Build.0 = Release|ARM64
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Release|Win32.ActiveCfg = Release|Win32
{60F89955-91C6-3A36-8000-13C592FEC2DF}.Release|Win32.Build.0 = Release|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug Library|Win32.Build.0 = Debug Library|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug|Win32.ActiveCfg = Debug|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug|Win32.Build.0 = Debug|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release Library|Win32.ActiveCfg = Release Library|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release Library|Win32.Build.0 = Release Library|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release|Win32.ActiveCfg = Release|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release|Win32.Build.0 = Release|Win32
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Debug Library|ARM64.ActiveCfg = Release|ARM64
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Debug Library|ARM64.Build.0 = Release|ARM64
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Debug Library|Win32.ActiveCfg = Release|Win32
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Debug Library|Win32.Build.0 = Release|Win32
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Debug|ARM64.ActiveCfg = Release|ARM64
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Debug|ARM64.Build.0 = Release|ARM64
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Debug|Win32.ActiveCfg = Release|Win32
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Debug|Win32.Build.0 = Release|Win32
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Release Library|ARM64.ActiveCfg = Release|ARM64
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Release Library|ARM64.Build.0 = Release|ARM64
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Release Library|Win32.ActiveCfg = Release|Win32
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Release Library|Win32.Build.0 = Release|Win32
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Release|ARM64.ActiveCfg = Release|ARM64
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Release|ARM64.Build.0 = Release|ARM64
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Release|Win32.ActiveCfg = Release|Win32
{EB33566E-DA7F-4D28-9077-88C0B7C77E35}.Release|Win32.Build.0 = Release|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug Library|ARM64.ActiveCfg = Debug Library|ARM64
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug Library|ARM64.Build.0 = Debug Library|ARM64
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug Library|Win32.Build.0 = Debug Library|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug|ARM64.ActiveCfg = Debug|ARM64
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug|ARM64.Build.0 = Debug|ARM64
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug|Win32.ActiveCfg = Debug|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Debug|Win32.Build.0 = Debug|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release Library|ARM64.ActiveCfg = Release Library|ARM64
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release Library|ARM64.Build.0 = Release Library|ARM64
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release Library|Win32.ActiveCfg = Release Library|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release Library|Win32.Build.0 = Release Library|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release|ARM64.ActiveCfg = Release|ARM64
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release|ARM64.Build.0 = Release|ARM64
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release|Win32.ActiveCfg = Release|Win32
{D6973076-9317-4EF2-A0B8-B7A18AC0713E}.Release|Win32.Build.0 = Release|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug Library|ARM64.ActiveCfg = Debug Library|ARM64
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug Library|ARM64.Build.0 = Debug Library|ARM64
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug Library|Win32.Build.0 = Debug Library|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug|ARM64.ActiveCfg = Debug|ARM64
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug|ARM64.Build.0 = Debug|ARM64
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug|Win32.ActiveCfg = Debug|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Debug|Win32.Build.0 = Debug|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release Library|ARM64.ActiveCfg = Release Library|ARM64
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release Library|ARM64.Build.0 = Release Library|ARM64
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release Library|Win32.ActiveCfg = Release Library|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release Library|Win32.Build.0 = Release Library|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release|ARM64.ActiveCfg = Release|ARM64
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release|ARM64.Build.0 = Release|ARM64
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release|Win32.ActiveCfg = Release|Win32
{228BA965-50D5-42B2-8BCF-AFCC227E3C1D}.Release|Win32.Build.0 = Release|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug Library|ARM64.ActiveCfg = Debug Library|ARM64
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug Library|ARM64.Build.0 = Debug Library|ARM64
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug Library|Win32.Build.0 = Debug Library|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug|ARM64.ActiveCfg = Debug|ARM64
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug|ARM64.Build.0 = Debug|ARM64
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug|Win32.ActiveCfg = Debug|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Debug|Win32.Build.0 = Debug|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release Library|ARM64.ActiveCfg = Release Library|ARM64
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release Library|ARM64.Build.0 = Release Library|ARM64
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release Library|Win32.ActiveCfg = Release Library|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release Library|Win32.Build.0 = Release Library|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release|ARM64.ActiveCfg = Release|ARM64
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release|ARM64.Build.0 = Release|ARM64
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release|Win32.ActiveCfg = Release|Win32
{9B36B6FE-7FC0-434F-A71F-BBEF8099F1D8}.Release|Win32.Build.0 = Release|Win32
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Debug Library|ARM64.ActiveCfg = Debug Library|ARM64
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Debug Library|ARM64.Build.0 = Debug Library|ARM64
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Debug Library|Win32.Build.0 = Debug Library|Win32
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Debug|ARM64.ActiveCfg = Debug|ARM64
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Debug|ARM64.Build.0 = Debug|ARM64
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Debug|Win32.ActiveCfg = Debug|Win32
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Debug|Win32.Build.0 = Debug|Win32
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Release Library|ARM64.ActiveCfg = Release Library|ARM64
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Release Library|ARM64.Build.0 = Release Library|ARM64
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Release Library|Win32.ActiveCfg = Release Library|Win32
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Release Library|Win32.Build.0 = Release Library|Win32
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Release|ARM64.ActiveCfg = Release|ARM64
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Release|ARM64.Build.0 = Release|ARM64
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Release|Win32.ActiveCfg = Release|Win32
{277AC57F-313B-4D06-B119-A3CDB672D2FF}.Release|Win32.Build.0 = Release|Win32
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Debug Library|ARM64.ActiveCfg = Debug Library|ARM64
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Debug Library|ARM64.Build.0 = Debug Library|ARM64
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Debug Library|Win32.ActiveCfg = Debug Library|Win32
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Debug Library|Win32.Build.0 = Debug Library|Win32
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Debug|ARM64.ActiveCfg = Debug|ARM64
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Debug|ARM64.Build.0 = Debug|ARM64
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Debug|Win32.ActiveCfg = Debug|Win32
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Debug|Win32.Build.0 = Debug|Win32
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Release Library|ARM64.ActiveCfg = Release Library|ARM64
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Release Library|ARM64.Build.0 = Release Library|ARM64
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Release Library|Win32.ActiveCfg = Release Library|Win32
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Release Library|Win32.Build.0 = Release Library|Win32
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Release|ARM64.ActiveCfg = Release|ARM64
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Release|ARM64.Build.0 = Release|ARM64
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Release|Win32.ActiveCfg = Release|Win32
{C5D3156C-8C8C-4936-B35F-2B829BA36FEC}.Release|Win32.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {785775C5-509E-4727-A290-F1B65E1B68B2}
EndGlobalSection
EndGlobal

View file

@ -1,18 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug Library|ARM64">
<Configuration>Debug Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug Library|Win32">
<Configuration>Debug Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|ARM64">
<Configuration>Release Library</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release Library|Win32">
<Configuration>Release Library</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@ -40,18 +56,41 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
@ -59,42 +98,69 @@
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|Win32'">
<ClCompile>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;_DEBUG;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BrowseInformation>true</BrowseInformation>
<FunctionLevelLinking>true</FunctionLevelLinking>
<DisableSpecificWarnings>$(DisableSpecificWarnings);4127;4131;4242;4244</DisableSpecificWarnings>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<Link>
<TargetMachine>MachineX86</TargetMachine>
@ -102,16 +168,33 @@
<SubSystem>Windows</SubSystem>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug Library|ARM64'">
<ClCompile>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<WarningLevel>$(WarningLevel)</WarningLevel>
<PreprocessorDefinitions>WIN32;_DEBUG;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BrowseInformation>true</BrowseInformation>
<FunctionLevelLinking>true</FunctionLevelLinking>
<DisableSpecificWarnings>$(DisableSpecificWarnings);4127;4131;4242;4244</DisableSpecificWarnings>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PreprocessorDefinitions>WIN32;_DEBUG;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BrowseInformation>true</BrowseInformation>
<FunctionLevelLinking>true</FunctionLevelLinking>
<DisableSpecificWarnings>$(DisableSpecificWarnings);4127;4131;4242;4244</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
</ClCompile>
<Link>
@ -120,9 +203,26 @@
<SubSystem>Windows</SubSystem>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<ClCompile>
<PreprocessorDefinitions>WIN32;_DEBUG;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<BrowseInformation>true</BrowseInformation>
<FunctionLevelLinking>true</FunctionLevelLinking>
<DisableSpecificWarnings>$(DisableSpecificWarnings);4127;4131;4242;4244</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
</ClCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|Win32'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<IntrinsicFunctions>true</IntrinsicFunctions>
@ -131,9 +231,9 @@
<BrowseInformation>true</BrowseInformation>
<FunctionLevelLinking>true</FunctionLevelLinking>
<DisableSpecificWarnings>$(DisableSpecificWarnings);4127;4131;4242;4244</DisableSpecificWarnings>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<TreatWarningAsError>false</TreatWarningAsError>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;NDEBUG;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
<Link>
<TargetMachine>MachineX86</TargetMachine>
@ -144,6 +244,29 @@
<LinkTimeCodeGeneration>true</LinkTimeCodeGeneration>
</Lib>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release Library|ARM64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<IntrinsicFunctions>true</IntrinsicFunctions>
<WholeProgramOptimization>true</WholeProgramOptimization>
<BufferSecurityCheck>false</BufferSecurityCheck>
<BrowseInformation>true</BrowseInformation>
<FunctionLevelLinking>true</FunctionLevelLinking>
<DisableSpecificWarnings>$(DisableSpecificWarnings);4127;4131;4242;4244</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<PreprocessorDefinitions>WIN32;NDEBUG;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
</Link>
<Lib>
<LinkTimeCodeGeneration>true</LinkTimeCodeGeneration>
</Lib>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
@ -156,7 +279,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<DisableSpecificWarnings>$(DisableSpecificWarnings);4127;4131;4242;4244</DisableSpecificWarnings>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;NDEBUG;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
<Link>
<TargetMachine>MachineX86</TargetMachine>
@ -169,6 +292,30 @@
<LinkTimeCodeGeneration>true</LinkTimeCodeGeneration>
</Lib>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>$(WarningLevel)</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Full</Optimization>
<IntrinsicFunctions>true</IntrinsicFunctions>
<WholeProgramOptimization>true</WholeProgramOptimization>
<BufferSecurityCheck>false</BufferSecurityCheck>
<BrowseInformation>true</BrowseInformation>
<FunctionLevelLinking>true</FunctionLevelLinking>
<DisableSpecificWarnings>$(DisableSpecificWarnings);4127;4131;4242;4244</DisableSpecificWarnings>
<TreatWarningAsError>$(TreatWarningAsError)</TreatWarningAsError>
<PreprocessorDefinitions>WIN32;NDEBUG;Z_SOLO;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
<Lib>
<LinkTimeCodeGeneration>true</LinkTimeCodeGeneration>
</Lib>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>

View file

@ -75,5 +75,5 @@ Other supporting scripts:
macro.lst => Used by autoconf tools
prefix.dfn => Used by autoconf tools
Further information can be found in comments in the individual makefiles.
Further information can be found in comments in the individual scripts and
makefiles.

View file

@ -6,14 +6,11 @@ c_deb =
pref = /prefix=all
.endif
OBJS = png.obj, pngerror.obj, pngget.obj, pngmem.obj, pngpread.obj,\
pngread.obj, pngrio.obj, pngrtran.obj, pngrutil.obj, pngset.obj,\
pngtrans.obj, pngwio.obj, pngwrite.obj, pngwtran.obj, pngwutil.obj
OBJS = png.obj, pngset.obj, pngget.obj, pngrutil.obj, pngtrans.obj,\
pngwutil.obj, pngread.obj, pngmem.obj, pngwrite.obj, pngrtran.obj,\
pngwtran.obj, pngrio.obj, pngwio.obj, pngerror.obj, pngpread.obj
CFLAGS= $(C_DEB) $(CC_DEFS) $(PREF)
CFLAGS = $(C_DEB) $(CC_DEFS) $(PREF)
all : pngtest.exe libpng.olb
@ write sys$output " pngtest available"
@ -21,32 +18,30 @@ all : pngtest.exe libpng.olb
libpng.olb : libpng.olb($(OBJS))
@ write sys$output " libpng available"
pngtest.exe : pngtest.obj libpng.olb
link pngtest,libpng.olb/lib,$(ZLIBSRC)libz.olb/lib
link pngtest,libpng.olb/lib,$(ZLIBSRC)libz.olb/lib
test : pngtest.exe
run pngtest
run pngtest
clean :
delete *.obj;*,*.exe;
# Other dependencies.
png.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
png.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngerror.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngget.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngmem.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngpread.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngset.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngget.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngread.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngread.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngrio.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngrtran.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngrutil.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngerror.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngmem.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngrio.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngwio.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngset.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngtrans.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngwio.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngwrite.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngwtran.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngwutil.obj : png.h, pngconf.h, pnglibconf.h, pngpriv.h, pngstruct.h,pnginfo.h, pngdebug.h
pngtest.obj : png.h, pngconf.h, pnglibconf.h
pngtest.obj : png.h, pngconf.h, pnglibconf.h

View file

@ -125,7 +125,7 @@ $1 ~ /^PNG_DFN_END_SORT/{
# There is no matching "@. Assume a split line
else while (1) {
if (getline nextline) {
# If the line starts with '#' it is a preprocesor line directive
# If the line starts with '#' it is a preprocessor line directive
# from cc -E; skip it:
if (nextline !~ /^#/) {
line = line " " nextline

View file

@ -10,6 +10,7 @@
# Variables substituted from CMakeLists.txt
set(SRCDIR "@CMAKE_CURRENT_SOURCE_DIR@")
set(BINDIR "@CMAKE_CURRENT_BINARY_DIR@")
set(AWK "@AWK@")
@ -23,7 +24,7 @@ get_filename_component(OUTPUTDIR "${OUTPUT}" PATH)
if("${INPUTEXT}" STREQUAL ".out" AND "${OUTPUTEXT}" STREQUAL ".chk")
# Generate .chk from .out with awk (generic)
file(REMOVE "${OUTPUT}" "${OUTPUTDIR}/${OUTPUTBASE}.new")
execute_process(COMMAND "${AWK}" -f "${SRCDIR}/scripts/checksym.awk"
execute_process(COMMAND "${AWK}" -f "${BINDIR}/scripts/checksym.awk"
"${SRCDIR}/scripts/${INPUTBASE}.def"
"of=${OUTPUTDIR}/${OUTPUTBASE}.new"
"${INPUT}"

View file

@ -11,7 +11,7 @@
# Modeled after libxml-config.
version=1.6.37
version=1.6.38
prefix=""
libdir=""
libs=""

View file

@ -5,6 +5,6 @@ includedir=@includedir@/libpng16
Name: libpng
Description: Loads and saves PNG files
Version: 1.6.37
Version: 1.6.38
Libs: -L${libdir} -lpng16
Cflags: -I${includedir}

View file

@ -1,6 +1,7 @@
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
#
# Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc.
# Copyright (C) 1996-2001, 2003-2019, 2021-2022 Free Software
# Foundation, Inc.
# Written by Gordon Matzigkeit, 1996
#
# This file is free software; the Free Software Foundation gives
@ -31,7 +32,7 @@ m4_define([_LT_COPYING], [dnl
# along with this program. If not, see <http://www.gnu.org/licenses/>.
])
# serial 58 LT_INIT
# serial 59 LT_INIT
# LT_PREREQ(VERSION)
@ -181,6 +182,7 @@ m4_require([_LT_FILEUTILS_DEFAULTS])dnl
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
m4_require([_LT_CMD_RELOAD])dnl
m4_require([_LT_DECL_FILECMD])dnl
m4_require([_LT_CHECK_MAGIC_METHOD])dnl
m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
m4_require([_LT_CMD_OLD_ARCHIVE])dnl
@ -219,8 +221,8 @@ esac
ofile=libtool
can_build_shared=yes
# All known linkers require a '.a' archive for static linking (except MSVC,
# which needs '.lib').
# All known linkers require a '.a' archive for static linking (except MSVC and
# ICC, which need '.lib').
libext=a
with_gnu_ld=$lt_cv_prog_gnu_ld
@ -778,7 +780,7 @@ _LT_EOF
# if finds mixed CR/LF and LF-only lines. Since sed operates in
# text mode, it properly converts lines to CR/LF. This bash problem
# is reportedly fixed, but why not run on old versions too?
sed '$q' "$ltmain" >> "$cfgfile" \
$SED '$q' "$ltmain" >> "$cfgfile" \
|| (rm -f "$cfgfile"; exit 1)
mv -f "$cfgfile" "$ofile" ||
@ -1042,8 +1044,8 @@ int forced_loaded() { return 2;}
_LT_EOF
echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
$LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
$AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
$AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
$RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
cat > conftest.c << _LT_EOF
@ -1067,17 +1069,12 @@ _LT_EOF
_lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
darwin1.*)
_lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
darwin*) # darwin 5.x on
# if running on 10.5 or later, the deployment target defaults
# to the OS version, if on x86, and 10.4, the deployment
# target defaults to 10.4. Don't you love it?
case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
_lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10.[[012]][[,.]]*)
_lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10.*)
_lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
darwin*)
case $MACOSX_DEPLOYMENT_TARGET,$host in
10.[[012]],*|,*powerpc*-darwin[[5-8]]*)
_lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
*)
_lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
esac
;;
esac
@ -1126,12 +1123,12 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES],
output_verbose_link_cmd=func_echo_all
_LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
_LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
_LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil"
_LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
_LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil"
_LT_TAGVAR(module_expsym_cmds, $1)="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
m4_if([$1], [CXX],
[ if test yes != "$lt_cv_apple_cc_single_mod"; then
_LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil"
_LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil"
_LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil"
fi
],[])
else
@ -1245,7 +1242,8 @@ _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
# _LT_WITH_SYSROOT
# ----------------
AC_DEFUN([_LT_WITH_SYSROOT],
[AC_MSG_CHECKING([for sysroot])
[m4_require([_LT_DECL_SED])dnl
AC_MSG_CHECKING([for sysroot])
AC_ARG_WITH([sysroot],
[AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@],
[Search for dependent libraries within DIR (or the compiler's sysroot
@ -1262,7 +1260,7 @@ case $with_sysroot in #(
fi
;; #(
/*)
lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"`
;; #(
no|'')
;; #(
@ -1292,7 +1290,7 @@ ia64-*-hpux*)
# options accordingly.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
case `/usr/bin/file conftest.$ac_objext` in
case `$FILECMD conftest.$ac_objext` in
*ELF-32*)
HPUX_IA64_MODE=32
;;
@ -1309,7 +1307,7 @@ ia64-*-hpux*)
echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
if test yes = "$lt_cv_prog_gnu_ld"; then
case `/usr/bin/file conftest.$ac_objext` in
case `$FILECMD conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -melf32bsmip"
;;
@ -1321,7 +1319,7 @@ ia64-*-hpux*)
;;
esac
else
case `/usr/bin/file conftest.$ac_objext` in
case `$FILECMD conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
;;
@ -1343,7 +1341,7 @@ mips64*-*linux*)
echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
emul=elf
case `/usr/bin/file conftest.$ac_objext` in
case `$FILECMD conftest.$ac_objext` in
*32-bit*)
emul="${emul}32"
;;
@ -1351,7 +1349,7 @@ mips64*-*linux*)
emul="${emul}64"
;;
esac
case `/usr/bin/file conftest.$ac_objext` in
case `$FILECMD conftest.$ac_objext` in
*MSB*)
emul="${emul}btsmip"
;;
@ -1359,7 +1357,7 @@ mips64*-*linux*)
emul="${emul}ltsmip"
;;
esac
case `/usr/bin/file conftest.$ac_objext` in
case `$FILECMD conftest.$ac_objext` in
*N32*)
emul="${emul}n32"
;;
@ -1379,14 +1377,14 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
# not appear in the list.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
case `/usr/bin/file conftest.o` in
case `$FILECMD conftest.o` in
*32-bit*)
case $host in
x86_64-*kfreebsd*-gnu)
LD="${LD-ld} -m elf_i386_fbsd"
;;
x86_64-*linux*)
case `/usr/bin/file conftest.o` in
case `$FILECMD conftest.o` in
*x86-64*)
LD="${LD-ld} -m elf32_x86_64"
;;
@ -1454,7 +1452,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
# options accordingly.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
case `/usr/bin/file conftest.o` in
case `$FILECMD conftest.o` in
*64-bit*)
case $lt_cv_prog_gnu_ld in
yes*)
@ -1493,9 +1491,22 @@ need_locks=$enable_libtool_lock
m4_defun([_LT_PROG_AR],
[AC_CHECK_TOOLS(AR, [ar], false)
: ${AR=ar}
: ${AR_FLAGS=cru}
_LT_DECL([], [AR], [1], [The archiver])
_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
# Use ARFLAGS variable as AR's operation code to sync the variable naming with
# Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have
# higher priority because thats what people were doing historically (setting
# ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS
# variable obsoleted/removed.
test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr}
lt_ar_flags=$AR_FLAGS
_LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)])
# Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override
# by AR_FLAGS because that was never working and AR_FLAGS is about to die.
_LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}],
[Flags to create an archive])
AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
[lt_cv_ar_at_file=no
@ -1714,7 +1725,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
lt_cv_sys_max_cmd_len=8192;
;;
bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*)
# This has been around since 386BSD, at least. Likely further.
if test -x /sbin/sysctl; then
lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
@ -1757,7 +1768,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
sysv5* | sco5v6* | sysv4.2uw2*)
kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
if test -n "$kargmax"; then
lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'`
else
lt_cv_sys_max_cmd_len=32768
fi
@ -2207,26 +2218,35 @@ m4_defun([_LT_CMD_STRIPLIB],
striplib=
old_striplib=
AC_MSG_CHECKING([whether stripping libraries is possible])
if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
test -z "$striplib" && striplib="$STRIP --strip-unneeded"
AC_MSG_RESULT([yes])
if test -z "$STRIP"; then
AC_MSG_RESULT([no])
else
# FIXME - insert some real tests, host_os isn't really good enough
case $host_os in
darwin*)
if test -n "$STRIP"; then
if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
old_striplib="$STRIP --strip-debug"
striplib="$STRIP --strip-unneeded"
AC_MSG_RESULT([yes])
else
case $host_os in
darwin*)
# FIXME - insert some real tests, host_os isn't really good enough
striplib="$STRIP -x"
old_striplib="$STRIP -S"
AC_MSG_RESULT([yes])
else
;;
freebsd*)
if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then
old_striplib="$STRIP --strip-debug"
striplib="$STRIP --strip-unneeded"
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
fi
;;
*)
AC_MSG_RESULT([no])
fi
;;
*)
AC_MSG_RESULT([no])
;;
esac
;;
esac
fi
fi
_LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
_LT_DECL([], [striplib], [1])
@ -2549,7 +2569,7 @@ cygwin* | mingw* | pw32* | cegcc*)
case $host_os in
cygwin*)
# Cygwin DLLs use 'cyg' prefix rather than 'lib'
soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
m4_if([$1], [],[
sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
;;
@ -2559,14 +2579,14 @@ m4_if([$1], [],[
;;
pw32*)
# pw32 DLLs use 'pw' prefix rather than 'lib'
library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
;;
esac
dynamic_linker='Win32 ld.exe'
;;
*,cl*)
# Native MSVC
*,cl* | *,icl*)
# Native MSVC or ICC
libname_spec='$name'
soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
library_names_spec='$libname.dll.lib'
@ -2585,7 +2605,7 @@ m4_if([$1], [],[
done
IFS=$lt_save_ifs
# Convert to MSYS style.
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
;;
cygwin*)
# Convert to unix form, then to dos form, then back to unix form
@ -2622,7 +2642,7 @@ m4_if([$1], [],[
;;
*)
# Assume MSVC wrapper
# Assume MSVC and ICC wrapper
library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib'
dynamic_linker='Win32 ld.exe'
;;
@ -2655,7 +2675,7 @@ dgux*)
shlibpath_var=LD_LIBRARY_PATH
;;
freebsd* | dragonfly*)
freebsd* | dragonfly* | midnightbsd*)
# DragonFly does not have aout. When/if they implement a new
# versioning mechanism, adjust this.
if test -x /usr/bin/objformat; then
@ -3454,7 +3474,7 @@ beos*)
bsdi[[45]]*)
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
lt_cv_file_magic_cmd='/usr/bin/file -L'
lt_cv_file_magic_cmd='$FILECMD -L'
lt_cv_file_magic_test_file=/shlib/libc.so
;;
@ -3488,14 +3508,14 @@ darwin* | rhapsody*)
lt_cv_deplibs_check_method=pass_all
;;
freebsd* | dragonfly*)
freebsd* | dragonfly* | midnightbsd*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
case $host_cpu in
i*86 )
# Not sure whether the presence of OpenBSD here was a mistake.
# Let's accept both of them until this is cleared up.
lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
lt_cv_file_magic_cmd=/usr/bin/file
lt_cv_file_magic_cmd=$FILECMD
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
;;
esac
@ -3509,7 +3529,7 @@ haiku*)
;;
hpux10.20* | hpux11*)
lt_cv_file_magic_cmd=/usr/bin/file
lt_cv_file_magic_cmd=$FILECMD
case $host_cpu in
ia64*)
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
@ -3556,7 +3576,7 @@ netbsd*)
newos6*)
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
lt_cv_file_magic_cmd=/usr/bin/file
lt_cv_file_magic_cmd=$FILECMD
lt_cv_file_magic_test_file=/usr/lib/libnls.so
;;
@ -3683,13 +3703,13 @@ else
mingw*) lt_bad_file=conftest.nm/nofile ;;
*) lt_bad_file=/dev/null ;;
esac
case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in
*$lt_bad_file* | *'Invalid file or object type'*)
lt_cv_path_NM="$tmp_nm -B"
break 2
;;
*)
case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in
*/dev/null*)
lt_cv_path_NM="$tmp_nm -p"
break 2
@ -3715,7 +3735,7 @@ else
# Let the user override the test.
else
AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in
*COFF*)
DUMPBIN="$DUMPBIN -symbols -headers"
;;
@ -3955,7 +3975,7 @@ esac
if test "$lt_cv_nm_interface" = "MS dumpbin"; then
# Gets list of data symbols to import.
lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'"
# Adjust the below global symbol transforms to fixup imported variables.
lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
@ -3973,20 +3993,20 @@ fi
# Transform an extracted symbol line into a proper C declaration.
# Some systems (esp. on ia64) link data and code symbols differently,
# so use this general approach.
lt_cv_sys_global_symbol_to_cdecl="sed -n"\
lt_cv_sys_global_symbol_to_cdecl="$SED -n"\
$lt_cdecl_hook\
" -e 's/^T .* \(.*\)$/extern int \1();/p'"\
" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
# Transform an extracted symbol line into symbol name and symbol address
lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\
$lt_c_name_hook\
" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
# Transform an extracted symbol line into symbol name with lib prefix and
# symbol address.
lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\
$lt_c_name_lib_hook\
" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
@ -4010,7 +4030,7 @@ for ac_symprfx in "" "_"; do
if test "$lt_cv_nm_interface" = "MS dumpbin"; then
# Fake it for dumpbin and say T for any non-static function,
# D for any global variable and I for any imported variable.
# Also find C++ and __fastcall symbols from MSVC++,
# Also find C++ and __fastcall symbols from MSVC++ or ICC,
# which start with @ or ?.
lt_cv_sys_global_symbol_pipe="$AWK ['"\
" {last_section=section; section=\$ 3};"\
@ -4028,9 +4048,9 @@ for ac_symprfx in "" "_"; do
" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
" ' prfx=^$ac_symprfx]"
else
lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
fi
lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'"
# Check to see that the pipe works correctly.
pipe_works=no
@ -4317,7 +4337,7 @@ m4_if([$1], [CXX], [
;;
esac
;;
freebsd* | dragonfly*)
freebsd* | dragonfly* | midnightbsd*)
# FreeBSD uses GNU C++
;;
hpux9* | hpux10* | hpux11*)
@ -4400,7 +4420,7 @@ m4_if([$1], [CXX], [
_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
;;
*)
case `$CC -V 2>&1 | sed 5q` in
case `$CC -V 2>&1 | $SED 5q` in
*Sun\ C*)
# Sun C++ 5.9
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
@ -4736,7 +4756,7 @@ m4_if([$1], [CXX], [
_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
;;
*)
case `$CC -V 2>&1 | sed 5q` in
case `$CC -V 2>&1 | $SED 5q` in
*Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
# Sun Fortran 8.3 passes all unrecognized flags to the linker
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
@ -4919,7 +4939,7 @@ m4_if([$1], [CXX], [
if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
else
_LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
_LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
fi
;;
pw32*)
@ -4927,7 +4947,7 @@ m4_if([$1], [CXX], [
;;
cygwin* | mingw* | cegcc*)
case $cc_basename in
cl*)
cl* | icl*)
_LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
;;
*)
@ -4984,15 +5004,15 @@ dnl Note also adjust exclude_expsyms for C++ above.
case $host_os in
cygwin* | mingw* | pw32* | cegcc*)
# FIXME: the MSVC++ port hasn't been tested in a loooong time
# FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
# Microsoft Visual C++ or Intel C++ Compiler.
if test yes != "$GCC"; then
with_gnu_ld=no
fi
;;
interix*)
# we just hope/assume this is gcc and not c89 (= MSVC++)
# we just hope/assume this is gcc and not c89 (= MSVC++ or ICC)
with_gnu_ld=yes
;;
openbsd* | bitrig*)
@ -5044,7 +5064,7 @@ dnl Note also adjust exclude_expsyms for C++ above.
_LT_TAGVAR(whole_archive_flag_spec, $1)=
fi
supports_anon_versioning=no
case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in
case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in
*GNU\ gold*) supports_anon_versioning=yes ;;
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
*\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
@ -5156,6 +5176,7 @@ _LT_EOF
emximp -o $lib $output_objdir/$libname.def'
_LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
_LT_TAGVAR(file_list_spec, $1)='@'
;;
interix[[3-9]]*)
@ -5170,7 +5191,7 @@ _LT_EOF
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
;;
gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
@ -5213,7 +5234,7 @@ _LT_EOF
_LT_TAGVAR(compiler_needs_object, $1)=yes
;;
esac
case `$CC -V 2>&1 | sed 5q` in
case `$CC -V 2>&1 | $SED 5q` in
*Sun\ C*) # Sun C 5.9
_LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
_LT_TAGVAR(compiler_needs_object, $1)=yes
@ -5225,7 +5246,7 @@ _LT_EOF
if test yes = "$supports_anon_versioning"; then
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
echo "local: *; };" >> $output_objdir/$libname.ver~
$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
fi
@ -5241,7 +5262,7 @@ _LT_EOF
_LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
if test yes = "$supports_anon_versioning"; then
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
echo "local: *; };" >> $output_objdir/$libname.ver~
$LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
fi
@ -5373,7 +5394,7 @@ _LT_EOF
if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
else
_LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
_LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
fi
aix_use_runtimelinking=no
@ -5556,12 +5577,12 @@ _LT_EOF
cygwin* | mingw* | pw32* | cegcc*)
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
# Microsoft Visual C++ or Intel C++ Compiler.
# hardcode_libdir_flag_spec is actually meaningless, as there is
# no search path for DLLs.
case $cc_basename in
cl*)
# Native MSVC
cl* | icl*)
# Native MSVC or ICC
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
_LT_TAGVAR(always_export_symbols, $1)=yes
@ -5602,7 +5623,7 @@ _LT_EOF
fi'
;;
*)
# Assume MSVC wrapper
# Assume MSVC and ICC wrapper
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
# Tell ltmain to make .lib files, not .a files.
@ -5650,7 +5671,7 @@ _LT_EOF
;;
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
freebsd* | dragonfly*)
freebsd* | dragonfly* | midnightbsd*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(hardcode_direct, $1)=yes
@ -5861,6 +5882,7 @@ _LT_EOF
emximp -o $lib $output_objdir/$libname.def'
_LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
_LT_TAGVAR(file_list_spec, $1)='@'
;;
osf3*)
@ -6631,8 +6653,8 @@ if test yes != "$_lt_caught_CXX_error"; then
cygwin* | mingw* | pw32* | cegcc*)
case $GXX,$cc_basename in
,cl* | no,cl*)
# Native MSVC
,cl* | no,cl* | ,icl* | no,icl*)
# Native MSVC or ICC
# hardcode_libdir_flag_spec is actually meaningless, as there is
# no search path for DLLs.
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
@ -6730,6 +6752,7 @@ if test yes != "$_lt_caught_CXX_error"; then
emximp -o $lib $output_objdir/$libname.def'
_LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
_LT_TAGVAR(file_list_spec, $1)='@'
;;
dgux*)
@ -6760,7 +6783,7 @@ if test yes != "$_lt_caught_CXX_error"; then
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
;;
freebsd* | dragonfly*)
freebsd* | dragonfly* | midnightbsd*)
# FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
# conventions
_LT_TAGVAR(ld_shlibs, $1)=yes
@ -6897,7 +6920,7 @@ if test yes != "$_lt_caught_CXX_error"; then
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
;;
irix5* | irix6*)
case $cc_basename in
@ -7037,13 +7060,13 @@ if test yes != "$_lt_caught_CXX_error"; then
_LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
if test yes = "$supports_anon_versioning"; then
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
echo "local: *; };" >> $output_objdir/$libname.ver~
$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
fi
;;
*)
case `$CC -V 2>&1 | sed 5q` in
case `$CC -V 2>&1 | $SED 5q` in
*Sun\ C*)
# Sun C++ 5.9
_LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
@ -8189,6 +8212,14 @@ _LT_DECL([], [DLLTOOL], [1], [DLL creation program])
AC_SUBST([DLLTOOL])
])
# _LT_DECL_FILECMD
# ----------------
# Check for a file(cmd) program that can be used to detect file type and magic
m4_defun([_LT_DECL_FILECMD],
[AC_CHECK_TOOL([FILECMD], [file], [:])
_LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types])
])# _LD_DECL_FILECMD
# _LT_DECL_SED
# ------------
# Check for a fully-functional sed program, that truncates

View file

@ -1,7 +1,7 @@
# Helper functions for option handling. -*- Autoconf -*-
#
# Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software
# Foundation, Inc.
# Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free
# Software Foundation, Inc.
# Written by Gary V. Vaughan, 2004
#
# This file is free software; the Free Software Foundation gives

View file

@ -1,6 +1,6 @@
# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
#
# Copyright (C) 2004-2005, 2007-2008, 2011-2015 Free Software
# Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2022 Free Software
# Foundation, Inc.
# Written by Gary V. Vaughan, 2004
#

View file

@ -1,6 +1,7 @@
# ltversion.m4 -- version numbers -*- Autoconf -*-
#
# Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc.
# Copyright (C) 2004, 2011-2019, 2021-2022 Free Software Foundation,
# Inc.
# Written by Scott James Remnant, 2004
#
# This file is free software; the Free Software Foundation gives
@ -9,15 +10,15 @@
# @configure_input@
# serial 4179 ltversion.m4
# serial 4245 ltversion.m4
# This file is part of GNU Libtool
m4_define([LT_PACKAGE_VERSION], [2.4.6])
m4_define([LT_PACKAGE_REVISION], [2.4.6])
m4_define([LT_PACKAGE_VERSION], [2.4.7])
m4_define([LT_PACKAGE_REVISION], [2.4.7])
AC_DEFUN([LTVERSION_VERSION],
[macro_version='2.4.6'
macro_revision='2.4.6'
[macro_version='2.4.7'
macro_revision='2.4.7'
_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
_LT_DECL(, macro_revision, 0)
])

View file

@ -1,7 +1,7 @@
# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
#
# Copyright (C) 2004-2005, 2007, 2009, 2011-2015 Free Software
# Foundation, Inc.
# Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2022 Free
# Software Foundation, Inc.
# Written by Scott James Remnant, 2004.
#
# This file is free software; the Free Software Foundation gives

View file

@ -1,5 +1,6 @@
# makefile for libpng on Solaris 2.x with cc
# Contributed by William L. Sebok, based on makefile.linux
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 2002, 2006, 2010-2014 Glenn Randers-Pehrson
# Copyright (C) 1998 Greg Roelofs
# Copyright (C) 1996, 1997 Andreas Dilger
@ -21,9 +22,9 @@ OLDSO=libpng.so
# Utilities:
CC=cc
AR_RC=ar rc
RANLIB=echo
MKDIR_P=mkdir -p
LN_SF=ln -f -s
RANLIB=echo
RM_F=/bin/rm -f
SUN_CC_FLAGS=-fast -xtarget=ultra
@ -44,7 +45,7 @@ ZLIBINC=/usr/include
WARNMORE=-Wwrite-strings -Wpointer-arith -Wshadow \
-Wmissing-declarations -Wtraditional -Wcast-align \
-Wstrict-prototypes -Wmissing-prototypes #-Wconversion
-Wstrict-prototypes -Wmissing-prototypes # -Wconversion
CPPFLAGS=-I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS=$(SUN_CC_FLAGS) # $(WARNMORE) -g
LDFLAGS=$(SUN_LD_FLAGS) -L$(ZLIBLIB) -R$(ZLIBLIB) libpng.a -lz -lm
@ -69,9 +70,9 @@ DI=$(DESTDIR)$(INCPATH)
DL=$(DESTDIR)$(LIBPATH)
DM=$(DESTDIR)$(MANPATH)
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
OBJSDLL = $(OBJS:.o=.pic.o)
@ -219,26 +220,22 @@ clean:
libpng-config $(LIBSO) $(LIBSOMAJ)* \
libpng.pc
DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO
writelock:
chmod a-w *.[ch35] $(DOCS) scripts/*
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o pngerror.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o pngrtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o pngrutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o pngtrans.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o pngwrite.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o pngwtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o pngwutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,5 +1,6 @@
# makefile for libpng on Solaris 2.x with cc
# Contributed by William L. Sebok, based on makefile.linux
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 2002, 2006, 2010-2014 Glenn Randers-Pehrson
# Copyright (C) 1998 Greg Roelofs
# Copyright (C) 1996, 1997 Andreas Dilger
@ -21,9 +22,9 @@ OLDSO=libpng.so
# Utilities:
CC=cc
AR_RC=ar rc
RANLIB=echo
MKDIR_P=mkdir -p
LN_SF=ln -f -s
RANLIB=echo
RM_F=/bin/rm -f
SUN_CC_FLAGS=-fast -xtarget=ultra -xarch=v9
@ -44,7 +45,7 @@ ZLIBINC=/usr/include
WARNMORE=-Wwrite-strings -Wpointer-arith -Wshadow \
-Wmissing-declarations -Wtraditional -Wcast-align \
-Wstrict-prototypes -Wmissing-prototypes #-Wconversion
-Wstrict-prototypes -Wmissing-prototypes # -Wconversion
CPPFLAGS=-I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS= $(SUN_CC_FLAGS) # $(WARNMORE) -g
LDFLAGS=-L. -R. $(SUN_LD_FLAGS) -L$(ZLIBLIB) -R$(ZLIBLIB) -lpng16 -lz -lm
@ -69,9 +70,9 @@ DI=$(DESTDIR)$(INCPATH)
DL=$(DESTDIR)$(LIBPATH)
DM=$(DESTDIR)$(MANPATH)
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
OBJSDLL = $(OBJS:.o=.pic.o)
@ -219,26 +220,22 @@ clean:
libpng-config $(LIBSO) $(LIBSOMAJ)* \
libpng.pc
DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO
writelock:
chmod a-w *.[ch35] $(DOCS) scripts/*
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o pngerror.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o pngrtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o pngrutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o pngtrans.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o pngwrite.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o pngwtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o pngwutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,6 +1,6 @@
# makefile for libpng using gcc (generic, static library)
# Copyright (C) 2000, 2022 Cosmin Truta
# Copyright (C) 2002, 2006-2009, 2014 Glenn Randers-Pehrson
# Copyright (C) 2000 Cosmin Truta
# Copyright (C) 2000 Marc O. Gloor (AIX support added, from makefile.gcc)
# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc.
#
@ -16,8 +16,8 @@ ZLIBLIB = ../zlib
CC = gcc
LD = $(CC)
AR_RC = ar rcs
MKDIR_P = mkdir -p
RANLIB = ranlib
MKDIR_P = mkdir -p
RM_F = rm -f
LN_SF = ln -f -s
@ -43,13 +43,13 @@ DL=$(DESTDIR)$(LIBPATH)
WARNMORE =
CPPFLAGS = -I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS = -W -Wall -O2 # $(WARNMORE) -g
LDFLAGS = -L. -L$(ZLIBLIB) -lpng16 -lz -lm
CFLAGS = -O2 -Wall -Wextra -Wundef # $(WARNMORE) -g
LDFLAGS = -L. -L$(ZLIBLIB) -lpng16 -lz -lm # -g
# Variables
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# File lists
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# Targets
.c.o:

View file

@ -33,9 +33,9 @@ MKDIR= makedir
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
all: libpng.lib pngtest

View file

@ -33,11 +33,11 @@ DESTDIR=
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
OBJS = $(LBR)(png.o) $(LBR)(pngset.o) $(LBR)(pngget.o) $(LBR)(pngrutil.o)\
$(LBR)(pngtrans.o) $(LBR)(pngwutil.o)\
$(LBR)(pngread.o) $(LBR)(pngerror.o) $(LBR)(pngwrite.o)\
$(LBR)(pngrtran.o) $(LBR)(pngwtran.o)\
$(LBR)(pngmem.o) $(LBR)(pngrio.o) $(LBR)(pngwio.o) $(LBR)(pngpread.o)
OBJS = $(LBR)(png.o) $(LBR)(pngerror.o) $(LBR)(pngget.o) $(LBR)(pngmem.o) \
$(LBR)(pngpread.o) $(LBR)(pngread.o) $(LBR)(pngrio.o) \
$(LBR)(pngrtran.o) $(LBR)(pngrutil.o) $(LBR)(pngset.o) \
$(LBR)(pngtrans.o) $(LBR)(pngwio.o) $(LBR)(pngwrite.o) \
$(LBR)(pngwtran.o) $(LBR)(pngwutil.o)
all: $(LBR) pngtest.ttp

View file

@ -50,13 +50,13 @@ CFLAGS=-O2 -d -k- -w $(TARGET_CPU) $(CDEBUG)
# -M generate map file
LDFLAGS=-L$(ZLIB_DIR) -M $(LDEBUG)
# Pre-built configuration
## Pre-built configuration
# See scripts\pnglibconf.mak for more options
!ifndef PNGLIBCONF_H_PREBUILT
PNGLIBCONF_H_PREBUILT = scripts\pnglibconf.h.prebuilt
!endif
## Variables
## File lists
OBJS = \
png.obj \
pngerror.obj \
@ -121,22 +121,22 @@ test: pngtest.exe
pnglibconf.h: $(PNGLIBCONF_H_PREBUILT)
$(CP) $(PNGLIBCONF_H_PREBUILT) $@
png.obj: png.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.obj: png.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.obj: pngerror.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.obj: pngget.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.obj: pngmem.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.obj: pngget.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.obj: pngmem.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.obj: pngpread.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.obj: pngread.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.obj: pngrio.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.obj: pngread.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.obj: pngrio.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.obj: pngrtran.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.obj: pngrutil.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.obj: pngset.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.obj: pngset.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.obj: pngtrans.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.obj: pngwio.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.obj: pngwio.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.obj: pngwrite.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.obj: pngwtran.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.obj: pngwutil.c png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.obj: pngtest.c png.h pngconf.h pnglibconf.h
pngtest.obj: pngtest.c png.h pngconf.h pnglibconf.h
$(LIBNAME): $(OBJS)
-del $(LIBNAME)

View file

@ -1,5 +1,6 @@
# makefile for libpng on BeOS x86 ELF with gcc
# modified from makefile.linux by Sander Stoks
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 2002, 2006, 2008, 2010-2014 Glenn Randers-Pehrson
# Copyright (C) 1999 Greg Roelofs
# Copyright (C) 1996, 1997 Andreas Dilger
@ -21,9 +22,9 @@ OLDSO=libpng.so
# Utilities:
CC=gcc
AR_RC=ar rc
RANLIB=ranlib
MKDIR_P=mkdir -p
LN_SF=ln -sf
RANLIB=ranlib
CP=cp
RM_F=/bin/rm -f
@ -37,14 +38,14 @@ ALIGN=
WARNMORE=-Wwrite-strings -Wpointer-arith -Wshadow \
-Wmissing-declarations -Wtraditional -Wcast-align \
-Wstrict-prototypes -Wmissing-prototypes #-Wconversion
-Wstrict-prototypes -Wmissing-prototypes # -Wconversion
# On BeOS, -O1 is actually better than -O3. This is a known bug but it's
# still here in R4.5
CPPFLAGS=-I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS=-W -Wall -O1 -funroll-loops $(ALIGN) # $(WARNMORE) -g
CFLAGS=-O1 -funroll-loops $(ALIGN) -Wall -Wextra -Wundef # $(WARNMORE) -g
# LDFLAGS=-L. -Wl,-rpath,. -L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) -lpng -lz
LDFLAGS=-L. -Wl,-soname=$(LIBSOMAJ) -L$(ZLIBLIB) -lz
LDFLAGS=-L. -Wl,-soname=$(LIBSOMAJ) -L$(ZLIBLIB) -lz # -g
# where make install puts libpng.a, libpng16.so*, and png.h
prefix=/usr/local
@ -73,9 +74,9 @@ DM=$(DESTDIR)$(MANPATH)
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
OBJSDLL = $(OBJS)
@ -203,20 +204,20 @@ clean:
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o pngerror.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o pngrtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o pngrutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o pngtrans.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o pngwrite.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o pngwtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o pngwutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,6 +1,6 @@
# makefile for libpng using clang (generic, static library)
# Copyright (C) 2000, 2014, 2019-2022 Cosmin Truta
# Copyright (C) 2008, 2014 Glenn Randers-Pehrson
# Copyright (C) 2000, 2014, 2019 Cosmin Truta
# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc.
#
# This code is released under the libpng license.
@ -19,12 +19,16 @@ RANLIB = ranlib
CP = cp
RM_F = rm -f
# Compiler and linker flags
NOHWOPT = -DPNG_ARM_NEON_OPT=0 -DPNG_MIPS_MSA_OPT=0 \
-DPNG_POWERPC_VSX_OPT=0 -DPNG_INTEL_SSE_OPT=0
WARNMORE = -Wwrite-strings -Wpointer-arith -Wshadow \
-Wmissing-declarations -Wtraditional -Wcast-align \
-Wstrict-prototypes -Wmissing-prototypes # -Wconversion
CPPFLAGS = -I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS = -W -Wall -O2 # $(WARNMORE) -g
LDFLAGS = -L$(ZLIBLIB)
DEFS = $(NOHWOPT)
CPPFLAGS = -I$(ZLIBINC) $(DEFS) # -DPNG_DEBUG=5
CFLAGS = -O2 -Wall -Wextra -Wundef # $(WARNMORE) -g
LDFLAGS = -L$(ZLIBLIB) # -g
LIBS = -lz -lm
# File extensions
@ -34,10 +38,10 @@ EXEEXT =
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
# Variables
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# File lists
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# Targets
all: static

View file

@ -1,87 +0,0 @@
# makefile for libpng using clang + address sanitizer (generic, static library)
# Copyright (C) 2008, 2014 Glenn Randers-Pehrson
# Copyright (C) 2000, 2014, 2019 Cosmin Truta
# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc.
#
# This code is released under the libpng license.
# For conditions of distribution and use, see the disclaimer
# and license in png.h
# Location of the zlib library and include files
ZLIBINC = ../zlib
ZLIBLIB = ../zlib
# Compiler, linker, lib and other tools
CC = clang
LD = $(CC)
AR_RC = ar rcs
RANLIB = ranlib
CP = cp
RM_F = rm -f
WARNMORE = -Wwrite-strings -Wpointer-arith -Wshadow \
-Wmissing-declarations -Wtraditional -Wcast-align \
-Wstrict-prototypes -Wmissing-prototypes # -Wconversion
CPPFLAGS = -I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS = -W -Wall -O0 -g -fsanitize=address
LDFLAGS = -L$(ZLIBLIB) -g -fsanitize=address
LIBS = -lz -lm
# File extensions
EXEEXT =
# Pre-built configuration
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
# Variables
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# Targets
all: static
pnglibconf.h: $(PNGLIBCONF_H_PREBUILT)
$(CP) $(PNGLIBCONF_H_PREBUILT) $@
.c.o:
$(CC) -c $(CPPFLAGS) $(CFLAGS) -o $@ $<
static: libpng.a pngtest$(EXEEXT)
shared:
@echo This is a generic makefile that cannot create shared libraries.
@echo Please use a configuration that is specific to your platform.
@false
libpng.a: $(OBJS)
$(AR_RC) $@ $(OBJS)
$(RANLIB) $@
test: pngtest$(EXEEXT)
./pngtest$(EXEEXT)
pngtest$(EXEEXT): pngtest.o libpng.a
$(LD) $(LDFLAGS) -o $@ pngtest.o libpng.a $(LIBS)
clean:
$(RM_F) *.o libpng.a pngtest$(EXEEXT) pngout.png pnglibconf.h
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,4 +1,5 @@
# makefile for libpng on Darwin / Mac OS X
# makefile for libpng on Darwin / macOS
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 2002, 2004, 2006, 2008, 2010-2014 Glenn Randers-Pehrson
# Copyright (C) 2001 Christoph Pfisterer
# derived from makefile.linux:
@ -11,6 +12,7 @@
# where "make install" puts libpng.a, libpng16.dylib, png.h, pngconf.h,
# and pnglibconf.h
prefix=/usr/local
exec_prefix=$(prefix)
@ -21,6 +23,7 @@ ZLIBINC=/usr/include
# Library name:
LIBNAME = libpng16
PNGMAJ = 16
RELEASE = 38
# Shared library names:
LIBSO=$(LIBNAME).dylib
@ -31,15 +34,17 @@ OLDSO=libpng.dylib
# Utilities:
CC=cc
AR_RC=ar rc
RANLIB=ranlib
MKDIR_P=mkdir -p
LN_SF=ln -sf
RANLIB=ranlib
CP=cp
RM_F=/bin/rm -f
RM_F=rm -f
CPPFLAGS=-I$(ZLIBINC)
# CFLAGS=-W -Wall -O3 -funroll-loops
CFLAGS=-W -Wall -O -funroll-loops
NOHWOPT=-DPNG_ARM_NEON_OPT=0 -DPNG_MIPS_MSA_OPT=0 \
-DPNG_POWERPC_VSX_OPT=0 -DPNG_INTEL_SSE_OPT=0
DEFS=$(NOHWOPT)
CPPFLAGS=-I$(ZLIBINC) $(DEFS)
CFLAGS=-O3 -funroll-loops -Wall -Wextra -Wundef
LDFLAGS=-L. -L$(ZLIBLIB) -lpng16 -lz
INCPATH=$(prefix)/include
@ -66,9 +71,10 @@ DM=$(DESTDIR)$(MANPATH)
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
# File lists
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
OBJSDLL = $(OBJS:.o=.pic.o)
@ -200,26 +206,22 @@ clean:
$(RM_F) *.o libpng.a pngtest pngout.png libpng-config \
libpng.pc $(LIBNAME).*dylib pngtesti pnglibconf.h
DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO
writelock:
chmod a-w *.[ch35] $(DOCS) scripts/*
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o pngerror.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o pngrtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o pngrutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o pngtrans.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o pngwrite.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o pngwtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o pngwutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -17,11 +17,11 @@ LIBSOREL=$(LIBSOMAJ).$(RELEASE)
OLDSO=libpng.so
# Utilities:
AR_RC=ar rc
CC=cc
AR_RC=ar rc
RANLIB=ranlib
MKDIR_P=mkdir
LN_SF=ln -f -s
RANLIB=ranlib
CP=cp
RM_F=/bin/rm -f
@ -62,9 +62,9 @@ LDFLAGS=-L$(ZLIBLIB) -rpath $(ZLIBLIB) libpng.a -lz -lm
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
.c.o:
$(CC) -c $(CPPFLAGS) $(CFLAGS) -o $@ $<
@ -75,7 +75,7 @@ pnglibconf.h: $(PNGLIBCONF_H_PREBUILT)
$(CP) $(PNGLIBCONF_H_PREBUILT) $@
libpng.a: $(OBJS)
$(AR_RC) $@ $(OBJS)
$(AR_RC) $@ $(OBJS)
$(RANLIB) $@
libpng.pc:
@ -191,20 +191,20 @@ clean:
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,4 +1,5 @@
# DJGPP (DOS gcc) makefile for libpng
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 2002, 2006, 2009-2014 Glenn Randers-Pehrson
# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc.
#
@ -17,8 +18,6 @@ CPPFLAGS=-I../zlib -DPNG_NO_SNPRINTF
CFLAGS=-O
LDFLAGS=-L. -L../zlib/ -lpng -lz -lm
RANLIB=ranlib
CP=cp
RM_F=rm -f
@ -26,9 +25,9 @@ RM_F=rm -f
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o pngwtran.o \
pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
.c.o:
$(CC) -c $(CPPFLAGS) $(CFLAGS) -o $@ $<
@ -39,8 +38,8 @@ pnglibconf.h: $(PNGLIBCONF_H_PREBUILT)
$(CP) $(PNGLIBCONF_H_PREBUILT) $@
libpng.a: $(OBJS)
ar rc $@ $(OBJS)
$(RANLIB) $@
ar rc $@ $(OBJS)
ranlib $@
pngtest: pngtest.o libpng.a
$(CC) -o pngtest $(CFLAGS) pngtest.o $(LDFLAGS)
@ -53,14 +52,14 @@ clean:
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
@ -69,4 +68,4 @@ pngwrite.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebu
pngwtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,6 +1,7 @@
# makefile for libpng using gcc + address sanitizer (generic, static library)
# makefile for libpng using emscripten
# Copyright (C) 2000, 2014, 2019-2022 Cosmin Truta
# Copyright (C) 2021 Kirk Roerig
# Copyright (C) 2008, 2014 Glenn Randers-Pehrson
# Copyright (C) 2000, 2014, 2019 Cosmin Truta
# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc.
#
# This code is released under the libpng license.
@ -12,32 +13,27 @@ ZLIBINC = ../zlib
ZLIBLIB = ../zlib
# Compiler, linker, lib and other tools
CC = gcc
CC = emcc
LD = $(CC)
AR_RC = ar rcs
RANLIB = ranlib
AR_RC = emar rcs
RANLIB = emranlib
CP = cp
RM_F = rm -f
WARNMORE = -Wwrite-strings -Wpointer-arith -Wshadow \
-Wmissing-declarations -Wtraditional -Wcast-align \
-Wstrict-prototypes -Wmissing-prototypes # -Wconversion
CPPFLAGS = -I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS = -W -Wall -O0 -g -fsanitize=address
LDFLAGS = -L$(ZLIBLIB) -g -fsanitize=address
CFLAGS = -O2 -Wall -Wextra -Wundef
LDFLAGS = -L$(ZLIBLIB)
PNGTEST_LDFLAGS = --preload-file=pngtest.png
LIBS = -lz -lm
# File extensions
EXEEXT =
# Pre-built configuration
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
# Variables
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# File lists
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# Targets
all: static
@ -48,25 +44,25 @@ pnglibconf.h: $(PNGLIBCONF_H_PREBUILT)
.c.o:
$(CC) -c $(CPPFLAGS) $(CFLAGS) -o $@ $<
static: libpng.a pngtest$(EXEEXT)
static: libpng.a pngtest
shared:
@echo This is a generic makefile that cannot create shared libraries.
@echo Please use a configuration that is specific to your platform.
@echo This makefile cannot create shared libraries.
@false
libpng.a: $(OBJS)
$(AR_RC) $@ $(OBJS)
$(RANLIB) $@
test: pngtest$(EXEEXT)
./pngtest$(EXEEXT)
test: pngtest
node ./pngtest
pngtest$(EXEEXT): pngtest.o libpng.a
$(LD) $(LDFLAGS) -o $@ pngtest.o libpng.a $(LIBS)
pngtest: pngtest.o libpng.a
$(LD) $(LDFLAGS) $(PNGTEST_LDFLAGS) -o $@ pngtest.o libpng.a $(LIBS)
clean:
$(RM_F) *.o libpng.a pngtest$(EXEEXT) pngout.png pnglibconf.h
$(RM_F) *.o libpng.a pngtest pngout.png pnglibconf.h
$(RM_F) pngtest.data pngtest.wasm
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h

View file

@ -1,4 +1,5 @@
# makefile for libpng under FreeBSD
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 2014 Glenn Randers-Pehrson and Andrey A. Chernov
# Copyright (C) 2002, 2007, 2009 Glenn Randers-Pehrson and Andrey A. Chernov
#
@ -37,15 +38,15 @@ LDADD+= -lm -lz
DPADD+= ${LIBM} ${LIBZ}
CPPFLAGS+= -I. -I${ZLIBINC}
CFLAGS+= -W -Wall
CFLAGS+= -Wall -Wextra -Wundef
# Pre-built configuration
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT= scripts/pnglibconf.h.prebuilt
SRCS= png.c pngset.c pngget.c pngrutil.c pngtrans.c pngwutil.c \
pngread.c pngrio.c pngwio.c pngwrite.c pngrtran.c \
pngwtran.c pngmem.c pngerror.c pngpread.c
SRCS= png.c pngerror.c pngget.c pngmem.c pngpread.c \
pngread.c pngrio.c pngrtran.c pngrutil.c pngset.c \
pngtrans.c pngwio.c pngwrite.c pngwtran.c pngwutil.c
.c.o:
$(CC) -c $(CPPFLAGS) $(CFLAGS) -o $@ $<
@ -62,8 +63,4 @@ test: pngtest
pnglibconf.h: $(PNGLIBCONF_H_PREBUILT)
cp $(PNGLIBCONF_H_PREBUILT) $@
DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO
writelock:
chmod a-w *.[ch35] $(DOCS) scripts/*
.include <bsd.lib.mk>

View file

@ -1,6 +1,6 @@
# makefile for libpng using gcc (generic, static library)
# Copyright (C) 2000, 2014, 2019-2022 Cosmin Truta
# Copyright (C) 2008, 2014 Glenn Randers-Pehrson
# Copyright (C) 2000, 2014, 2019 Cosmin Truta
# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc.
#
# This code is released under the libpng license.
@ -19,12 +19,16 @@ RANLIB = ranlib
CP = cp
RM_F = rm -f
# Compiler and linker flags
NOHWOPT = -DPNG_ARM_NEON_OPT=0 -DPNG_MIPS_MSA_OPT=0 \
-DPNG_POWERPC_VSX_OPT=0 -DPNG_INTEL_SSE_OPT=0
WARNMORE = -Wwrite-strings -Wpointer-arith -Wshadow \
-Wmissing-declarations -Wtraditional -Wcast-align \
-Wstrict-prototypes -Wmissing-prototypes # -Wconversion
CPPFLAGS = -I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS = -W -Wall -O2 # $(WARNMORE) -g
LDFLAGS = -L$(ZLIBLIB)
DEFS = $(NOHWOPT)
CPPFLAGS = -I$(ZLIBINC) $(DEFS) # -DPNG_DEBUG=5
CFLAGS = -O2 -Wall -Wextra -Wundef # $(WARNMORE) -g
LDFLAGS = -L$(ZLIBLIB) # -g
LIBS = -lz -lm
# File extensions
@ -34,10 +38,10 @@ EXEEXT =
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
# Variables
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# File lists
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
# Targets
all: static

View file

@ -1,4 +1,5 @@
# makefile for libpng, HPUX (10.20 and 11.00) using the ANSI/C product.
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 1999-2002, 2006, 2009, 2010-2014 Glenn Randers-Pehrson
# Copyright (C) 1995 Guy Eric Schalnat, Group 42
# Contributed by Jim Rice and updated by Chris Schleicher, Hewlett Packard
@ -29,11 +30,11 @@ LIBSOREL=$(LIBSOMAJ).$(RELEASE)
OLDSO=libpng.sl
# Utilities:
AR_RC=ar rc
CC=cc
AR_RC=ar rc
RANLIB=ranlib
MKDIR_P=mkdir -p
LN_SF=ln -sf
RANLIB=ranlib
CP=cp
RM_F=/bin/rm -f
@ -72,9 +73,9 @@ DM=$(DESTDIR)$(MANPATH)
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
OBJSDLL = $(OBJS:.o=.pic.o)
@ -206,26 +207,22 @@ clean:
libpng-config $(LIBSO) $(LIBSOMAJ)* \
libpng.pc pnglibconf.h
DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO
writelock:
chmod a-w *.[ch35] $(DOCS) scripts/*
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,4 +1,5 @@
# makefile for libpng on HP-UX using GCC with the HP ANSI/C linker.
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 2002, 2006-2008, 2010-2014 Glenn Randers-Pehrson
# Copyright (C) 2001, Laurent faillie
# Copyright (C) 1998, 1999 Greg Roelofs
@ -22,9 +23,9 @@ OLDSO=libpng.sl
CC=gcc
LD=ld
AR_RC=ar rc
RANLIB=ranlib
MKDIR_P=mkdir -p
LN_SF=ln -sf
RANLIB=ranlib
CP=cp
RM_F=/bin/rm -f
@ -44,20 +45,14 @@ ZLIBINC=/opt/zlib/include
# LDSHARED=ld -b
# SHAREDLIB=libz.sl
ALIGN=
# for i386:
#ALIGN=-malign-loops=2 -malign-functions=2
WARNMORE=-Wwrite-strings -Wpointer-arith -Wshadow \
-Wmissing-declarations -Wtraditional -Wcast-align \
-Wstrict-prototypes -Wmissing-prototypes #-Wconversion
# for pgcc version 2.95.1, -O3 is buggy; don't use it.
-Wstrict-prototypes -Wmissing-prototypes # -Wconversion
CPPFLAGS=-I$(ZLIBINC) # -DPNG_DEBUG=5
CFLAGS=-W -Wall -O3 -funroll-loops $(ALIGN) # $(WARNMORE) -g
#LDFLAGS=-L. -Wl,-rpath,. -L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) -lpng16 -lz -lm
LDFLAGS=-L. -L$(ZLIBLIB) -lpng16 -lz -lm
CFLAGS=-O3 -funroll-loops -Wall -Wextra -Wundef # $(WARNMORE) -g
#LDFLAGS=-L. -Wl,-rpath,. -L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) -lpng16 -lz -lm # -g
LDFLAGS=-L. -L$(ZLIBLIB) -lpng16 -lz -lm # -g
INCPATH=$(prefix)/include
LIBPATH=$(exec_prefix)/lib
@ -79,9 +74,9 @@ DI=$(DESTDIR)$(INCPATH)
DL=$(DESTDIR)$(LIBPATH)
DM=$(DESTDIR)$(MANPATH)
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
OBJSDLL = $(OBJS:.o=.pic.o)
@ -209,26 +204,22 @@ clean:
libpng-config $(LIBSO) $(LIBSOMAJ)* \
libpng.pc pnglibconf.h
DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO
writelock:
chmod a-w *.[ch35] $(DOCS) scripts/*
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o png.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o pngerror.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o pngget.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o pngmem.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o pngread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o pngrio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o pngrtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o pngrutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o pngset.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o pngtrans.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o pngwio.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o pngwrite.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o pngwtran.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o pngwutil.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o pngpread.pic.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,4 +1,5 @@
# makefile for libpng, HPUX (10.20 and 11.00) using the ANSI/C product.
# Copyright (C) 2020-2022 Cosmin Truta
# Copyright (C) 1999-2002, 2006, 2010-2014 Glenn Randers-Pehrson
# Copyright (C) 1995 Guy Eric Schalnat, Group 42
# Contributed by Jim Rice and updated by Chris Schleicher, Hewlett Packard
@ -30,11 +31,11 @@ LIBSOREL=$(LIBSOMAJ).$(RELEASE)
OLDSO=libpng.sl
# Utilities:
AR_RC=ar rc
CC=cc
AR_RC=ar rc
RANLIB=ranlib
MKDIR_P=mkdir -p
LN_SF=ln -sf
RANLIB=ranlib
RM_F=/bin/rm -f
# where make install puts libpng.a, libpng16.sl, and png.h
@ -70,9 +71,9 @@ DM=$(DESTDIR)$(MANPATH)
# See scripts/pnglibconf.mak for more options
PNGLIBCONF_H_PREBUILT = scripts/pnglibconf.h.prebuilt
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
OBJS = png.o pngerror.o pngget.o pngmem.o pngpread.o \
pngread.o pngrio.o pngrtran.o pngrutil.o pngset.o \
pngtrans.o pngwio.o pngwrite.o pngwtran.o pngwutil.o
OBJSDLL = $(OBJS:.o=.pic.o)
@ -204,26 +205,22 @@ clean:
libpng-config $(LIBSO) $(LIBSOMAJ)* \
libpng.pc pnglibconf.h
DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO
writelock:
chmod a-w *.[ch35] $(DOCS) scripts/*
# DO NOT DELETE THIS LINE -- make depend depends on it.
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
png.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngget.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngmem.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngrutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngset.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtrans.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwio.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwrite.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwtran.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngwutil.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngpread.o: png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngtest.o: png.h pngconf.h pnglibconf.h
pngtest.o: png.h pngconf.h pnglibconf.h

View file

@ -1,7 +1,7 @@
# Makefile for libpng (static)
# IBM C version 3.x for Win32 and OS/2
# Copyright (C) 2006, 2014 Glenn Randers-Pehrson
# Copyright (C) 2000 Cosmin Truta
# Copyright (C) 2000, 2020 Cosmin Truta
#
# This code is released under the libpng license.
# For conditions of distribution and use, see the disclaimer
@ -37,10 +37,10 @@ O=.obj
A=.lib
E=.exe
# Variables
# File lists
OBJS = png$(O) pngerror$(O) pngget$(O) pngmem$(O) pngpread$(O) \
pngread$(O) pngrio$(O) pngrtran$(O) pngrutil$(O) pngset$(O) \
pngtrans$(O) pngwio$(O) pngwrite$(O) pngwtran$(O) pngwutil$(O)
pngread$(O) pngrio$(O) pngrtran$(O) pngrutil$(O) pngset$(O) \
pngtrans$(O) pngwio$(O) pngwrite$(O) pngwtran$(O) pngwutil$(O)
LIBS = libpng$(A) $(ZLIBLIB)/zlib$(A)
@ -65,11 +65,11 @@ pngtest$(E): pngtest$(O) libpng$(A)
$(LD) $(LDFLAGS) pngtest$(O) $(LIBS)
clean:
$(RM) *$(O)
$(RM) libpng$(A)
$(RM) pnglibconf.h
$(RM) pngtest$(E)
$(RM) pngout.png
-$(RM) *$(O)
-$(RM) libpng$(A)
-$(RM) pnglibconf.h
-$(RM) pngtest$(E)
-$(RM) pngout.png
png$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h
pngerror$(O): png.h pngconf.h pnglibconf.h pngpriv.h pngstruct.h pnginfo.h pngdebug.h

Some files were not shown because too many files have changed in this diff Show more