diff options
author | Glenn Randers-Pehrson <glennrp at users.sourceforge.net> | 2013-05-12 12:01:18 -0500 |
---|---|---|
committer | Glenn Randers-Pehrson <glennrp at users.sourceforge.net> | 2013-05-12 18:34:58 -0500 |
commit | bc92887b2d4852ea0631ad5daa78b32c406b7743 (patch) | |
tree | 31c11465dac2f7d0e9d4414fb985381f6f5e9a50 /scripts | |
parent | ae8174d9a35605148e9b5ddcc02e4608d8739a65 (diff) | |
download | libpng-bc92887b2d4852ea0631ad5daa78b32c406b7743.tar.gz |
[libpng15] Imported from libpng-1.5.16beta06.tarv1.5.16beta06
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/README.txt | 12 | ||||
-rwxr-xr-x | scripts/checksym.awk | 20 | ||||
-rw-r--r-- | scripts/dfn.awk | 192 | ||||
-rwxr-xr-x | scripts/libpng-config-head.in | 2 | ||||
-rw-r--r-- | scripts/libpng.pc.in | 2 | ||||
-rw-r--r-- | scripts/makefile.cegcc | 2 | ||||
-rw-r--r-- | scripts/makefile.freebsd | 13 | ||||
-rw-r--r-- | scripts/makefile.linux | 2 | ||||
-rw-r--r-- | scripts/makefile.msys | 2 | ||||
-rw-r--r-- | scripts/makefile.ne12bsd | 2 | ||||
-rw-r--r-- | scripts/makefile.netbsd | 2 | ||||
-rw-r--r-- | scripts/makefile.openbsd | 2 | ||||
-rwxr-xr-x | scripts/options.awk | 360 | ||||
-rw-r--r-- | scripts/pnglibconf.dfa | 31 | ||||
-rw-r--r-- | scripts/pnglibconf.h.prebuilt | 325 | ||||
-rw-r--r-- | scripts/symbols.def | 3 | ||||
-rw-r--r-- | scripts/symbols.dfn | 3 |
17 files changed, 583 insertions, 392 deletions
diff --git a/scripts/README.txt b/scripts/README.txt index 914f6ad0c..7476a733c 100644 --- a/scripts/README.txt +++ b/scripts/README.txt @@ -1,9 +1,9 @@ -Makefiles for libpng version 1.5.15beta06 - February 22, 2013 +Makefiles for libpng version 1.5.16beta06 - May 12, 2013 pnglibconf.h.prebuilt => Stores configuration settings makefile.linux => Linux/ELF makefile - (gcc, creates libpng15.so.15.1.5.15beta06) + (gcc, creates libpng15.so.15.1.5.16beta06) makefile.gcc => Generic makefile (gcc, creates static libpng.a) makefile.knr => Archaic UNIX Makefile that converts files with ansi2knr (Requires ansi2knr.c from @@ -21,7 +21,7 @@ pnglibconf.h.prebuilt => Stores configuration settings makefile.dec => DEC Alpha UNIX makefile makefile.dj2 => DJGPP 2 makefile makefile.elf => Linux/ELF makefile symbol versioning, - (gcc, creates libpng15.so.15.1.5.15beta06) + (gcc, creates libpng15.so.15.1.5.16beta06) makefile.freebsd => FreeBSD makefile makefile.gcc => Generic gcc makefile makefile.hpgcc => HPUX makefile using gcc @@ -36,12 +36,12 @@ pnglibconf.h.prebuilt => Stores configuration settings makefile.os2 => OS/2 Makefile (gcc and emx, requires libpng.def) makefile.sco => For SCO OSr5 ELF and Unixware 7 with Native cc makefile.sggcc => Silicon Graphics (gcc, - creates libpng15.so.15.1.5.15beta06) + creates libpng15.so.15.1.5.16beta06) makefile.sgi => Silicon Graphics IRIX makefile (cc, creates static lib) makefile.solaris => Solaris 2.X makefile (gcc, - creates libpng15.so.15.1.5.15beta06) + creates libpng15.so.15.1.5.16beta06) makefile.so9 => Solaris 9 makefile (gcc, - creates libpng15.so.15.1.5.15beta06) + creates libpng15.so.15.1.5.16beta06) makefile.std => Generic UNIX makefile (cc, creates static libpng.a) makefile.sunos => Sun makefile makefile.32sunu => Sun Ultra 32-bit makefile diff --git a/scripts/checksym.awk b/scripts/checksym.awk index ba4c99b56..fe3af55e0 100755 --- a/scripts/checksym.awk +++ b/scripts/checksym.awk @@ -5,8 +5,9 @@ # awk -f checksym.awk official-def list-to-check # # Output is a file in the current directory called 'symbols.new', -# stdout holds error messages. Error code indicates success or -# failure. +# the value of the awk variable "of" (which can be changed on the +# command line if required.) stdout holds error messages. Error +# code indicates success or failure. # # NOTE: this is a pure, old fashioned, awk script. It will # work with any awk @@ -21,6 +22,7 @@ BEGIN{ mastero = 0 # highest ordinal in master file symbolo = 0 # highest ordinal in png.h missing = "error"# log an error on missing symbols + of="symbols.new" # default to a fixed name } # Read existing definitions from the master file (the first @@ -111,6 +113,16 @@ END{ err = 1 } unexported=0 + # Add a standard header to symbols.new: + print ";Version INSERT-VERSION-HERE" >of + print ";--------------------------------------------------------------" >of + print "; LIBPNG symbol list as a Win32 DEF file" >of + print "; Contains all the symbols that can be exported from libpng" >of + print ";--------------------------------------------------------------" >of + print "LIBRARY" >of + print "" >of + print "EXPORTS" >of + for (o=1; o<=lasto; ++o) { if (symbol[o] == "" && removed[o] == "") { if (unexported == 0) unexported = o @@ -151,11 +163,11 @@ END{ # Finally generate symbols.new if (symbol[o] != "") - print " " symbol[o], "@" o > "symbols.new" + print " " symbol[o], "@" o > of } if (err != 0) { - print "*** A new list is in symbols.new ***" + print "*** A new list is in", of, "***" exit 1 } } diff --git a/scripts/dfn.awk b/scripts/dfn.awk index 8a5dab6f9..89b92d5d9 100644 --- a/scripts/dfn.awk +++ b/scripts/dfn.awk @@ -31,11 +31,11 @@ NR==1 && out == "/dev/null" { # Output can be sorted; two lines are recognized $1 == "PNG_DFN_START_SORT"{ - sort=$2 + sort=0+$2 next } -$1 == "PNG_DFN_END_SORT"{ +$1 ~ /^PNG_DFN_END_SORT/{ # Do a very simple, slow, sort; notice that blank lines won't be # output by this for (entry in array) { @@ -61,75 +61,143 @@ $1 == "PNG_DFN_END_SORT"{ } /^[^"]*PNG_DFN *".*"[^"]*$/{ - # A definition line, apparently correctly formated, extract the - # definition then replace any doubled "" that remain with a single - # double quote. Notice that the original doubled double quotes - # may have been split by tokenization - orig=$0 - - if (gsub(/^[^"]*PNG_DFN *"/,"") != 1 || gsub(/"[^"]*$/, "") != 1) { - print "line", NR, "processing failed:" + # A definition line, apparently correctly formated, extract the + # definition then replace any doubled "" that remain with a single + # double quote. Notice that the original doubled double quotes + # may have been split by tokenization + # + # Sometimes GCC splits the PNG_DFN lines, we know this has happened + # if the quotes aren't closed and must read another line. In this + # case it is essential to reject lines that start '#' because those + # are introduced #line directives. + orig=$0 + line=$0 + lineno=FNR + if (lineno == "") lineno=NR + + if (sub(/^[^"]*PNG_DFN *"/,"",line) != 1) { + print "line", lineno ": processing failed:" print orig - print $0 err=1 - } else { + next + } else { ++out_count - } - - # Now examine quotes within the value: - # - # @" - delete this and any following spaces - # "@ - delete this and any original spaces - # @' - replace this by a double quote - # - # This allows macro substitution by the C compiler thus: - # - # #define first_name John - # #define last_name Smith - # - # PNG_DFN"#define name @'@" first_name "@ @" last_name "@@'" - # - # Might get C preprocessed to: - # - # PNG_DFN "#define foo @'@" John "@ @" Smith "@@'" - # - # Which this script reduces to: - # - # #define name "John Smith" - # - while (sub(/@" */, "")) { - if (!sub(/ *"@/, "")) { - print "unbalanced @\" ... \"@ pair" - err=1 - break - } - } - - # Put any needed double quotes in - gsub(/@'/,"\"") - - # Remove any trailing spaces (not really required, but for - # editorial consistency - sub(/ *$/, "") - - if (sort) - array[$(sort)] = $0 - - else - print $0 >out - next + } + + # Now examine quotes within the value: + # + # @" - delete this and any following spaces + # "@ - delete this and any preceding spaces + # @' - replace this by a double quote + # + # This allows macro substitution by the C compiler thus: + # + # #define first_name John + # #define last_name Smith + # + # PNG_DFN"#define name @'@" first_name "@ @" last_name "@@'" + # + # Might get C preprocessed to: + # + # PNG_DFN "#define foo @'@" John "@ @" Smith "@@'" + # + # Which this script reduces to: + # + # #define name "John Smith" + # + while (1) { + # While there is an @" remove it and the next "@ + if (line ~ /@"/) { + if (line ~ /@".*"@/) { + # Do this special case first to avoid swallowing extra spaces + # before or after the @ stuff: + if (!sub(/@" *"@/, "", line)) { + # Ok, do it in pieces - there has to be a non-space between the + # two. NOTE: really weird things happen if a leading @" is + # lost - the code will error out below (I believe). + if (!sub(/@" */, "", line) || !sub(/ *"@/, "", line)) { + print "line", lineno, ": internal error:", orig + exit 1 + } + } + } + + # 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 + # from cc -E, skip it: + if (nextline !~ /^#/) { + line = line " " nextline + break + } + } else { + # This is end-of-input - probably a missig "@ on the first line: + print "line", lineno ": unbalanced @\" ... \"@ pair" + err=1 + next + } + } + + # Keep going until all the @" have gone + continue + } + + # Attempt to remove a trailing " (not preceded by '@') - if this can + # be done stop now, if not assume a split line again + if (sub(/"[^"]*$/, "", line)) + break + + # Read another line + while (1) { + if (getline nextline) { + if (nextline !~ /^#/) { + line = line " " nextline + # Go back to stripping @" "@ pairs + break + } + } else { + print "line", lineno ": unterminated PNG_DFN string" + err=1 + next + } + } + } + + # Put any needed double quotes in (at the end, because these would otherwise + # interfere with the processing above.) + gsub(/@'/,"\"", line) + + # Remove any trailing spaces (not really required, but for + # editorial consistency + sub(/ *$/, "", line) + + # Remove trailing CR + sub(/
$/, "", line) + + if (sort) { + if (split(line, parts) < sort) { + print "line", lineno ": missing sort field:", line + err=1 + } else + array[parts[sort]] = line + } + + else + print line >out + next } /PNG_DFN/{ - print "line", NR, "incorrectly formated PNG_DFN line:" - print $0 - err = 1 + print "line", NR, "incorrectly formated PNG_DFN line:" + print $0 + err = 1 } END{ - if (out_count > 0 || err > 0) + if (out_count > 0 || err > 0) exit err - print "no definition lines found" - exit 1 + print "no definition lines found" + exit 1 } diff --git a/scripts/libpng-config-head.in b/scripts/libpng-config-head.in index 34a07e201..8335c2eb8 100755 --- a/scripts/libpng-config-head.in +++ b/scripts/libpng-config-head.in @@ -11,7 +11,7 @@ # Modeled after libxml-config. -version=1.5.15beta06 +version=1.5.16beta06 prefix="" libdir="" libs="" diff --git a/scripts/libpng.pc.in b/scripts/libpng.pc.in index 4260ca838..d5fa420f5 100644 --- a/scripts/libpng.pc.in +++ b/scripts/libpng.pc.in @@ -5,6 +5,6 @@ includedir=@includedir@/libpng15 Name: libpng Description: Loads and saves PNG files -Version: 1.5.15beta06 +Version: 1.5.16beta06 Libs: -L${libdir} -lpng15 Cflags: -I${includedir} diff --git a/scripts/makefile.cegcc b/scripts/makefile.cegcc index f36fcbc12..2c71e758e 100644 --- a/scripts/makefile.cegcc +++ b/scripts/makefile.cegcc @@ -23,7 +23,7 @@ VERMAJ = 1 VERMIN = 5 -VERMIC = 15 +VERMIC = 16 VER = $(VERMAJ).$(VERMIN).$(VERMIC) NAME = libpng PACKAGE = $(NAME)-$(VER) diff --git a/scripts/makefile.freebsd b/scripts/makefile.freebsd index 38cd92121..0eb1eeece 100644 --- a/scripts/makefile.freebsd +++ b/scripts/makefile.freebsd @@ -26,19 +26,24 @@ SYMLINKS= libpng/png.h ${INCSDIR}/../png.h \ libpng/pngconf.h ${INCSDIR}/../pngconf.h \ libpng/pnglibconf.h ${INCSDIR}/../pnglibconf.h -LDADD+= -lm -lz -#LDADD+= -lm -lz -lssp_nonshared # for OSVERSION >= 800000 ? +# where make install finds libz.a and zlib.h +ZLIBLIB= /usr/lib +ZLIBINC= /usr/include + +LDADD+= -lm -lz +#LDADD+= -lm -lz -lssp_nonshared # for OSVERSION < 800000 ? DPADD+= ${LIBM} ${LIBZ} -CFLAGS+= -I. +CFLAGS+= -I. -I${ZLIBINC} 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 pngtest: pngtest.o libpng.a - ${CC} ${CFLAGS} -L. -static -o pngtest pngtest.o -lpng -lz -lm + ${CC} ${CFLAGS} -L. -static -o pngtest pngtest.o -L${ZLIBLIB} \ + -lpng ${LDADD} CLEANFILES= pngtest pngtest.o pngout.png diff --git a/scripts/makefile.linux b/scripts/makefile.linux index 56fbab86e..b21644857 100644 --- a/scripts/makefile.linux +++ b/scripts/makefile.linux @@ -10,7 +10,7 @@ # Library name: LIBNAME = libpng15 PNGMAJ = 15 -RELEASE = 15 +RELEASE = 16 # Shared library names: LIBSO=$(LIBNAME).so diff --git a/scripts/makefile.msys b/scripts/makefile.msys index eeb88d46f..960555fc8 100644 --- a/scripts/makefile.msys +++ b/scripts/makefile.msys @@ -18,7 +18,7 @@ exec_prefix=$(prefix) # Library name: LIBNAME = libpng15 PNGMAJ = 15 -RELEASE = 15 +RELEASE = 16 # Shared library names: LIBSO=$(LIBNAME).dll diff --git a/scripts/makefile.ne12bsd b/scripts/makefile.ne12bsd index 70bc04be0..4f5a4fe8d 100644 --- a/scripts/makefile.ne12bsd +++ b/scripts/makefile.ne12bsd @@ -17,7 +17,7 @@ INCSDIR=${LOCALBASE}/include/libpng15 LIB= png15 SHLIB_MAJOR= 0 -SHLIB_MINOR= 1.5.15beta06 +SHLIB_MINOR= 1.5.16beta06 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 diff --git a/scripts/makefile.netbsd b/scripts/makefile.netbsd index d91d8f30d..f3c6cbffd 100644 --- a/scripts/makefile.netbsd +++ b/scripts/makefile.netbsd @@ -17,7 +17,7 @@ INCSDIR=${LOCALBASE}/include LIB= png SHLIB_MAJOR= 15 -SHLIB_MINOR= 1.5.15beta06 +SHLIB_MINOR= 1.5.16beta06 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 diff --git a/scripts/makefile.openbsd b/scripts/makefile.openbsd index aa8ca9605..44ee2b4bf 100644 --- a/scripts/makefile.openbsd +++ b/scripts/makefile.openbsd @@ -11,7 +11,7 @@ LIBDIR= ${PREFIX}/lib MANDIR= ${PREFIX}/man/cat SHLIB_MAJOR= 15 -SHLIB_MINOR= 1.5.15beta06 +SHLIB_MINOR= 1.5.16beta06 LIB= png SRCS= png.c pngerror.c pngget.c pngmem.c pngpread.c \ diff --git a/scripts/options.awk b/scripts/options.awk index 4b8a419b3..c3a850173 100755 --- a/scripts/options.awk +++ b/scripts/options.awk @@ -53,7 +53,7 @@ BEGIN{ comment=start "/*" # Comment start cend="*/" end # Comment end def=start "#define PNG_" # Arbitrary define - sup="_SUPPORTED 1" end # end supported option + sup="_SUPPORTED" end # end supported option und=comment "#undef PNG_" # Unsupported option une="_SUPPORTED" cend # end unsupported option error=start "ERROR:" # error message, terminate with 'end' @@ -64,11 +64,15 @@ BEGIN{ logunsupported=0 # write unsupported options too # Precreate arrays + # for each option: option[""] = "" # list of all options: default enabled/disabled done[""] = 1 # marks option as having been output requires[""] = "" # requires by option iffs[""] = "" # if by option enabledby[""] = "" # options that enable it by option + sets[""] = "" # settings set by each option + setval[""] = "" # value to set (indexed: 'option sets[option]') + # for each setting: setting[""] = "" # requires by setting defaults[""] = "" # used for a defaulted value doneset[""] = 1 # marks setting as having been output @@ -200,7 +204,7 @@ $1 == "com"{ if (NF > 1) { # sub(/^[ ]*com[ ]*/, "") $1 = "" - print comment, $0, cend >out + print comment $0, cend >out } else print start end >out next @@ -237,7 +241,9 @@ $1 == "file" && NF >= 2{ next } -# option NAME ( (requires|enables|if) NAME* | on | off | disabled )* +# option NAME ( (requires|enables|if) NAME* | on | off | disabled | +# sets SETTING VALUE+ )* +# # Declares an option 'NAME' and describes its default setting (disabled) # and its relationship to other options. The option is disabled # unless *all* the options listed after 'requires' are set and at @@ -252,95 +258,152 @@ $1 == "file" && NF >= 2{ # be later) entry may turn an option on or off explicitly. $1 == "option" && NF >= 2{ - onoff = option[$2] # records current (and the default is "", enabled) + opt = $2 + sub(/,$/,"",opt) + onoff = option[opt] # records current (and the default is "", enabled) key = "" - for (i=3; i<=NF; ++i) { - if ($(i) == "on" || $(i) == "off" || $(i) == "disabled") { - key = "" - if (onoff != $(i)) { - # on or off can zap disabled or enabled: - if (onoff == "" || (onoff == "disabled" || onoff == "enabled") && ($(i) == "on" || $(i) == "off")) { - # It's easy to mis-spell the option when turning it - # on or off, so warn about it here: - if (onoff == "" && ($(i) == "on" || $(i) == "off")) { - print $2 ": ERROR: turning unrecognized option", $(i) - # For the moment error out - it is safer - err = 1 # prevent END{} running - exit 1 + istart = 3 + do { + if (istart == 1) { # continuation line + val = getline + + if (val != 1) { # error reading it + if (val == 0) + print "option", opt ": ERROR: missing contination line" + else + print "option", opt ": ERROR: error reading continuation line" + + # This is a hard error + err = 1 # prevent END{} running + exit 1 + } + } + + for (i=istart; i<=NF; ++i) { + val=$(i) + sub(/,$/,"",val) + if (val == "on" || val == "off" || val == "disabled") { + key = "" + if (onoff != val) { + # on or off can zap disabled or enabled: + if (onoff == "" || (onoff == "disabled" || onoff == "enabled") && + (val == "on" || val == "off")) { + # It's easy to mis-spell the option when turning it + # on or off, so warn about it here: + if (onoff == "" && (val == "on" || val == "off")) { + print "option", opt ": ERROR: turning unrecognized option", val + # For the moment error out - it is safer + err = 1 # prevent END{} running + exit 1 + } + onoff = val + } else { + # Print a message, otherwise the error + # below is incomprehensible + print "option", opt ": currently", onoff ": attempt to turn", val + break } - onoff = $(i) - } else { - # Print a message, otherwise the error - # below is incomprehensible - print $2 ": currently", onoff ": attempt to turn", $(i) - break } - } - } else if ($(i) == "requires" || $(i) == "if" || $(i) == "enables") { - key = $(i) - } else if (key == "requires") { - requires[$2] = requires[$2] " " $(i) - } else if (key == "if") { - iffs[$2] = iffs[$2] " " $(i) - } else if (key == "enables") { - enabledby[$(i)] = enabledby[$(i)] " " $2 - } else - break # bad line format - } + } else if (val == "requires" || val == "if" || val == "enables" || val =="sets") { + key = val + } else if (key == "requires") { + requires[opt] = requires[opt] " " val + } else if (key == "if") { + iffs[opt] = iffs[opt] " " val + } else if (key == "enables") { + enabledby[val] = enabledby[val] " " opt + } else if (key == "sets") { + sets[opt] = sets[opt] " " val + key = "setval" + set = val + } else if (key == "setval") { + setval[opt " " set] = setval[opt " " set] " " val + } else + break # bad line format + } + + istart = 1 + } while (i > NF && $0 ~ /,$/) if (i > NF) { # Set the option, defaulting to 'enabled' if (onoff == "") onoff = "enabled" - option[$2] = onoff + option[opt] = onoff next } # Else fall through to the error handler } -# chunk NAME [requires OPT] [on|off|disabled] +# chunk NAME [requires OPT] [enables LIST] [on|off|disabled] # Expands to the 'option' settings appropriate to the reading and # writing of an ancilliary PNG chunk 'NAME': # # option READ_NAME requires READ_ANCILLARY_CHUNKS [READ_OPT] -# option READ_NAME enables NAME +# option READ_NAME enables NAME LIST # [option READ_NAME off] # option WRITE_NAME requires WRITE_ANCILLARY_CHUNKS [WRITE_OPT] -# option WRITE_NAME enables NAME +# option WRITE_NAME enables NAME LIST # [option WRITE_NAME off] pre != 0 && $1 == "chunk" && NF >= 2{ # 'chunk' is handled on the first pass by writing appropriate # 'option' lines into the intermediate file. + opt = $2 + sub(/,$/,"",opt) onoff = "" reqread = "" reqwrite = "" - i = 3 # indicates format error - if (NF > 2) { + enables = "" + req = 0 + istart = 3 + do { + if (istart == 1) { # continuation line + val = getline + + if (val != 1) { # error reading it + if (val == 0) + print "chunk", opt ": ERROR: missing contination line" + else + print "chunk", opt ": ERROR: error reading continuation line" + + # This is a hard error + err = 1 # prevent END{} running + exit 1 + } + } + # read the keywords/additional OPTS - req = 0 - for (i=3; i<=NF; ++i) { - if ($(i) == "on" || $(i) == "off" || $(i) == "disabled") { - if (onoff != $(i)) { + for (i=istart; i<=NF; ++i) { + val = $(i) + sub(/,$/,"",val) + if (val == "on" || val == "off" || val == "disabled") { + if (onoff != val) { if (onoff == "") - onoff = $(i) + onoff = val else break # on/off conflict } - } else if ($(i) == "requires") + req = 0 + } else if (val == "requires") req = 1 - else if (req != 1) + else if (val == "enables") + req = 2 + else if (req == 1){ + reqread = reqread " READ_" val + reqwrite = reqwrite " WRITE_" val + } else if (req == 2) + enables = enables " " val + else break # bad line: handled below - else { - reqread = reqread " READ_" $(i) - reqwrite = reqwrite " WRITE_" $(i) - } } - } + + istart = 1 + } while (i > NF && $0 ~ /,$/) if (i > NF) { # Output new 'option' lines to the intermediate file (out) - print "option READ_" $2, "requires READ_ANCILLARY_CHUNKS" reqread, "enables", $2, onoff >out - print "option WRITE_" $2, "requires WRITE_ANCILLARY_CHUNKS" reqwrite, "enables", $2, onoff >out + print "option READ_" opt, "requires READ_ANCILLARY_CHUNKS" reqread, "enables", opt enables , onoff >out + print "option WRITE_" opt, "requires WRITE_ANCILLARY_CHUNKS" reqwrite, "enables", opt enables, onoff >out next } # Else hit the error handler below - bad line format! @@ -471,83 +534,7 @@ END{ exit 0 } - # Do the 'setting' values first, the algorithm the standard - # tree walk (O(1)) done in an O(2) while/for loop; interations - # settings x depth, outputing the deepest required macros - # first. - print "" >out - print "/* SETTINGS */" >out - print comment, "settings", cend >out - # Sort (in dfn.awk) on field 2, the setting name - print "PNG_DFN_START_SORT 2" >out - finished = 0 - while (!finished) { - finished = 1 - movement = 0 # done nothing - for (i in setting) if (!doneset[i]) { - nreqs = split(setting[i], r) - if (nreqs > 0) { - for (j=1; j<=nreqs; ++j) if (!doneset[r[j]]) { - break - } - if (j<=nreqs) { - finished = 0 - continue # try a different setting - } - } - - # All the requirements have been processed, output - # this setting. - if (deb) print "setting", i - deflt = defaults[i] - # A leading @ means leave it unquoted so the preprocessor - # can substitute the build time value - if (deflt ~ /^ @/) - deflt = " " subs substr(deflt, 3) sube - # Remove any spurious trailing spaces - sub(/ *$/,"",deflt) - print "" >out - print "/* setting: ", i >out - print " * requires:" setting[i] >out - print " * default: ", defaults[i] defltinfo, "*/" >out - if (defaults[i] == "") { # no default, only check if defined - print "#ifdef PNG_" i >out - } - for (j=1; j<=nreqs; ++j) { - print "# ifndef PNG_" r[j] >out - print error, i, "requires", r[j] end >out - print "# endif" >out - } - if (defaults[i] != "") { # default handling - print "#ifdef PNG_" i >out - } - # PNG_<i> is defined, so substitute the value: - print def i, subs "PNG_" i sube end >out - if (defaults[i] != "") { - print "#else /*default*/" >out - # And add the default definition for the benefit - # of later settings an options test: - print "# define PNG_" i deflt >out - print def i deflt end >out - } - print "#endif" >out - - doneset[i] = 1 - ++movement - } - - if (!finished && !movement) { - print "setting: loop or missing setting in 'requires', cannot process:" - for (i in setting) if (!doneset[i]) { - print " setting", i, "requires" setting[i] - } - exit 1 - } - } - print "PNG_DFN_END_SORT" >out - print comment, "end of settings", cend >out - - # Now do the options - somewhat more complex. The dependency + # Do the options first (allowing options to set settings). The dependency # tree is thus: # # name > name @@ -639,7 +626,7 @@ END{ } if (err) exit 1 - # Sort options too + # Sort options: print "PNG_DFN_START_SORT 2" >out # option[i] is now the complete list of all the tokens we may @@ -679,8 +666,9 @@ END{ print "" >out print "/* option:", i, option[i] >out print " * requires: " requires[i] >out - print " * if: " iffs[i] >out - print " * enabled-by:" enabledby[i], "*/" >out + print " * if: " iffs[i] >out + print " * enabled-by:" enabledby[i] >out + print " * sets: " sets[i], "*/" >out print "#undef PNG_on" >out print "#define PNG_on 1" >out @@ -763,6 +751,21 @@ END{ print error, i, "is on: enabled by:" iffs[i] enabledby[i] ", requires" requires[i] end >out } else if (i !~ /^ok_/) { print def i sup >out + # Supported option, set required settings + nreqs = split(sets[i], r) + for (j=1; j<=nreqs; ++j) { + print "# ifdef PNG_set_" r[j] >out + # Some other option has already set a value: + print error, i, "sets", r[j] ": duplicate setting" end >out + print error, " previous value: " end "PNG_set_" r[j] >out + print "# else" >out + # Else set the default: note that this won't accept arbitrary + # values, the setval string must be acceptable to all the C + # compilers we use. That means it must be VERY simple; a number, + # a name or a string. + print "# define PNG_set_" r[j], setval[i " " r[j]] >out + print "# endif" >out + } } print "# endif /* definition */" >out print "#endif /*requires, if*/" >out @@ -796,6 +799,93 @@ END{ print "PNG_DFN_END_SORT" >out print comment, "end of options", cend >out + # Do the 'setting' values second, the algorithm the standard + # tree walk (O(1)) done in an O(2) while/for loop; interations + # settings x depth, outputing the deepest required macros + # first. + print "" >out + print "/* SETTINGS */" >out + print comment, "settings", cend >out + # Sort (in dfn.awk) on field 2, the setting name + print "PNG_DFN_START_SORT 2" >out + finished = 0 + while (!finished) { + finished = 1 + movement = 0 # done nothing + for (i in setting) if (!doneset[i]) { + nreqs = split(setting[i], r) + if (nreqs > 0) { + # By default assume the requires values are options, but if there + # is no option with that name check for a setting + for (j=1; j<=nreqs; ++j) if (option[r[j]] == "" && !doneset[r[j]]) { + break + } + if (j<=nreqs) { + finished = 0 + continue # try a different setting + } + } + + # All the requirements have been processed, output + # this setting. + if (deb) print "setting", i + deflt = defaults[i] + # Remove any spurious trailing spaces + sub(/ *$/,"",deflt) + # A leading @ means leave it unquoted so the preprocessor + # can substitute the build time value + if (deflt ~ /^ @/) + deflt = " " subs substr(deflt, 3) sube + print "" >out + print "/* setting: ", i >out + print " * requires:" setting[i] >out + print " * default: ", defaults[i] deflt, "*/" >out + for (j=1; j<=nreqs; ++j) { + if (option[r[j]] != "") + print "#ifndef PNG_" r[j] "_SUPPORTED" >out + else + print "#ifndef PNG_" r[j] >out + print error, i, "requires", r[j] end >out + print "# endif" >out + } + # The precedence is: + # + # 1) External definition; trumps: + # 2) Option 'sets' value; trumps: + # 3) Setting 'default' + # + print "#ifdef PNG_" i >out + # PNG_<i> is defined, so substitute the value: + print def i, subs "PNG_" i sube end >out + print "#else /* use default */" >out + print "# ifdef PNG_set_" i >out + # Value from an option 'sets' argument + print def i, subs "PNG_set_" i sube end >out + # This is so that subsequent tests on the setting work: + print "# define PNG_" i, "1" >out + if (defaults[i] != "") { + print "# else /*default*/" >out + print def i deflt end >out + print "# define PNG_" i, "1" >out + } + print "# endif /* defaults */" >out + print "#endif /* setting", i, "*/" >out + + doneset[i] = 1 + ++movement + } + + if (!finished && !movement) { + print "setting: loop or missing setting in 'requires', cannot process:" + for (i in setting) if (!doneset[i]) { + print " setting", i, "requires" setting[i] + } + exit 1 + } + } + print "PNG_DFN_END_SORT" >out + print comment, "end of settings", cend >out + # Regular end - everything looks ok if (protect != "") { print start "#endif", "/*", protect, "*/" end >out diff --git a/scripts/pnglibconf.dfa b/scripts/pnglibconf.dfa index 62764e03b..dd6331f65 100644 --- a/scripts/pnglibconf.dfa +++ b/scripts/pnglibconf.dfa @@ -27,7 +27,7 @@ file pnglibconf.h scripts/pnglibconf.dfa PNGLCONF_H # The syntax is detailed in scripts/options.awk, this is a summary # only: # -# setting <name> [default] +# setting <name> [requires ...] [default] # #define PNG_<name> <value> /* value comes from current setting */ # option <name> [requires ...] [if ...] [enables ...] [disabled] # #define PNG_<name>_SUPPORTED if the requirements are met and @@ -191,12 +191,23 @@ option WRITE enables WRITE_INT_FUNCTIONS setting FILTER_OPTIMIZATIONS -# This option turns on runtime checks for ARM NEON support, it is irrelevant -# on other platforms and it is irrelevant unless NEON code is turned on. Checks -# are on by default - -option ARM_NEON_CHECK - +# Implementation specific control of the optimizations, enabled by those +# hardware or software options that need it (typically when run-time choices +# must be made by the user) +option SET_OPTION disabled + +# These options are specific to the ARM NEON hardware optimizations: +# +# ARM_NEON: the optimization itself +# ARM_NEON_API: allow the optimization to be switched on with png_set_hardware +# ARM_NEON_CHECK: compile a run-time check to see if Neon extensions are +# supported, this is poorly supported and deprectated - use the +# png_set_hardware API. +option ARM_NEON disabled, + sets FILTER_OPTIMIZATIONS png_init_filter_functions_neon +option ARM_NEON_API disabled enables SET_OPTION ARM_NEON +option ARM_NEON_CHECK disabled enables ARM_NEON + # Generic options - affect both read and write. option WARNINGS @@ -369,6 +380,12 @@ option INCH_CONVERSIONS option BUILD_GRAYSCALE_PALETTE +# This changes the default for the ARM NEON optimizations according to +# __ARM_NEON__ +@#ifdef __ARM_NEON__ +@# define PNG_ARM_NEON_SUPPORTED +@#endif + # IN DEVELOPMENT # These are currently experimental features; define them if you want diff --git a/scripts/pnglibconf.h.prebuilt b/scripts/pnglibconf.h.prebuilt index 800143fa7..9f562e769 100644 --- a/scripts/pnglibconf.h.prebuilt +++ b/scripts/pnglibconf.h.prebuilt @@ -1,25 +1,176 @@ - -/* libpng STANDARD API DEFINITION */ - +/* 1.5.16beta06 STANDARD API DEFINITION */ /* pnglibconf.h - library build configuration */ -/* Libpng 1.5.15beta06 - February 22, 2013 */ +/* libpng version 1.5.16beta06 - May 12, 2013 */ -/* Copyright (c) 1998-2012 Glenn Randers-Pehrson */ +/* Copyright (c) 1998-2013 Glenn Randers-Pehrson */ /* This code is released under the libpng license. */ /* For conditions of distribution and use, see the disclaimer */ /* and license in png.h */ /* pnglibconf.h */ +/* Machine generated file: DO NOT EDIT */ /* Derived from: scripts/pnglibconf.dfa */ -/* If you edit this file by hand you must obey the rules expressed in */ -/* pnglibconf.dfa with respect to the dependencies between the following */ -/* symbols. It is much better to generate a new file using */ -/* scripts/libpngconf.mak */ - #ifndef PNGLCONF_H #define PNGLCONF_H +/* options */ +#define PNG_16BIT_SUPPORTED +#define PNG_ALIGNED_MEMORY_SUPPORTED +/*#undef PNG_ARM_NEON_API_SUPPORTED*/ +/*#undef PNG_ARM_NEON_CHECK_SUPPORTED*/ +/*#undef PNG_ARM_NEON_SUPPORTED*/ +#define PNG_BENIGN_ERRORS_SUPPORTED +#define PNG_BUILD_GRAYSCALE_PALETTE_SUPPORTED +#define PNG_CHECK_FOR_INVALID_INDEX_SUPPORTED +#define PNG_CHECK_cHRM_SUPPORTED +#define PNG_CONSOLE_IO_SUPPORTED +#define PNG_CONVERT_tIME_SUPPORTED +#define PNG_EASY_ACCESS_SUPPORTED +/*#undef PNG_ERROR_NUMBERS_SUPPORTED*/ +#define PNG_ERROR_TEXT_SUPPORTED +#define PNG_FIXED_POINT_SUPPORTED +#define PNG_FLOATING_ARITHMETIC_SUPPORTED +#define PNG_FLOATING_POINT_SUPPORTED +#define PNG_GET_PALETTE_MAX_SUPPORTED +#define PNG_HANDLE_AS_UNKNOWN_SUPPORTED +#define PNG_INCH_CONVERSIONS_SUPPORTED +#define PNG_INFO_IMAGE_SUPPORTED +#define PNG_IO_STATE_SUPPORTED +#define PNG_MNG_FEATURES_SUPPORTED +#define PNG_POINTER_INDEXING_SUPPORTED +#define PNG_PROGRESSIVE_READ_SUPPORTED +#define PNG_READ_16BIT_SUPPORTED +#define PNG_READ_ALPHA_MODE_SUPPORTED +#define PNG_READ_ANCILLARY_CHUNKS_SUPPORTED +#define PNG_READ_BACKGROUND_SUPPORTED +#define PNG_READ_BGR_SUPPORTED +#define PNG_READ_CHECK_FOR_INVALID_INDEX_SUPPORTED +#define PNG_READ_COMPOSITE_NODIV_SUPPORTED +#define PNG_READ_COMPRESSED_TEXT_SUPPORTED +#define PNG_READ_EXPAND_16_SUPPORTED +#define PNG_READ_EXPAND_SUPPORTED +#define PNG_READ_FILLER_SUPPORTED +#define PNG_READ_GAMMA_SUPPORTED +#define PNG_READ_GET_PALETTE_MAX_SUPPORTED +#define PNG_READ_GRAY_TO_RGB_SUPPORTED +#define PNG_READ_INTERLACING_SUPPORTED +#define PNG_READ_INT_FUNCTIONS_SUPPORTED +#define PNG_READ_INVERT_ALPHA_SUPPORTED +#define PNG_READ_INVERT_SUPPORTED +#define PNG_READ_OPT_PLTE_SUPPORTED +#define PNG_READ_PACKSWAP_SUPPORTED +#define PNG_READ_PACK_SUPPORTED +#define PNG_READ_QUANTIZE_SUPPORTED +#define PNG_READ_RGB_TO_GRAY_SUPPORTED +#define PNG_READ_SCALE_16_TO_8_SUPPORTED +#define PNG_READ_SHIFT_SUPPORTED +#define PNG_READ_STRIP_16_TO_8_SUPPORTED +#define PNG_READ_STRIP_ALPHA_SUPPORTED +#define PNG_READ_SUPPORTED +#define PNG_READ_SWAP_ALPHA_SUPPORTED +#define PNG_READ_SWAP_SUPPORTED +#define PNG_READ_TEXT_SUPPORTED +#define PNG_READ_TRANSFORMS_SUPPORTED +#define PNG_READ_UNKNOWN_CHUNKS_SUPPORTED +#define PNG_READ_USER_CHUNKS_SUPPORTED +#define PNG_READ_USER_TRANSFORM_SUPPORTED +#define PNG_READ_bKGD_SUPPORTED +#define PNG_READ_cHRM_SUPPORTED +#define PNG_READ_gAMA_SUPPORTED +#define PNG_READ_hIST_SUPPORTED +#define PNG_READ_iCCP_SUPPORTED +#define PNG_READ_iTXt_SUPPORTED +#define PNG_READ_oFFs_SUPPORTED +#define PNG_READ_pCAL_SUPPORTED +#define PNG_READ_pHYs_SUPPORTED +#define PNG_READ_sBIT_SUPPORTED +#define PNG_READ_sCAL_SUPPORTED +#define PNG_READ_sPLT_SUPPORTED +#define PNG_READ_sRGB_SUPPORTED +#define PNG_READ_tEXt_SUPPORTED +#define PNG_READ_tIME_SUPPORTED +#define PNG_READ_tRNS_SUPPORTED +#define PNG_READ_zTXt_SUPPORTED +/*#undef PNG_SAFE_LIMITS_SUPPORTED*/ +#define PNG_SAVE_INT_32_SUPPORTED +#define PNG_SEQUENTIAL_READ_SUPPORTED +#define PNG_SETJMP_SUPPORTED +#define PNG_SET_CHUNK_CACHE_LIMIT_SUPPORTED +#define PNG_SET_CHUNK_MALLOC_LIMIT_SUPPORTED +/*#undef PNG_SET_OPTION_SUPPORTED*/ +#define PNG_SET_USER_LIMITS_SUPPORTED +#define PNG_STDIO_SUPPORTED +#define PNG_TEXT_SUPPORTED +#define PNG_TIME_RFC1123_SUPPORTED +#define PNG_UNKNOWN_CHUNKS_SUPPORTED +#define PNG_USER_CHUNKS_SUPPORTED +#define PNG_USER_LIMITS_SUPPORTED +#define PNG_USER_MEM_SUPPORTED +#define PNG_USER_TRANSFORM_INFO_SUPPORTED +#define PNG_USER_TRANSFORM_PTR_SUPPORTED +#define PNG_WARNINGS_SUPPORTED +#define PNG_WRITE_16BIT_SUPPORTED +#define PNG_WRITE_ANCILLARY_CHUNKS_SUPPORTED +#define PNG_WRITE_BGR_SUPPORTED +#define PNG_WRITE_CHECK_FOR_INVALID_INDEX_SUPPORTED +#define PNG_WRITE_COMPRESSED_TEXT_SUPPORTED +#define PNG_WRITE_CUSTOMIZE_ZTXT_COMPRESSION_SUPPORTED +#define PNG_WRITE_FILLER_SUPPORTED +#define PNG_WRITE_FILTER_SUPPORTED +#define PNG_WRITE_FLUSH_SUPPORTED +#define PNG_WRITE_GET_PALETTE_MAX_SUPPORTED +#define PNG_WRITE_INTERLACING_SUPPORTED +#define PNG_WRITE_INT_FUNCTIONS_SUPPORTED +#define PNG_WRITE_INVERT_ALPHA_SUPPORTED +#define PNG_WRITE_INVERT_SUPPORTED +#define PNG_WRITE_OPTIMIZE_CMF_SUPPORTED +#define PNG_WRITE_PACKSWAP_SUPPORTED +#define PNG_WRITE_PACK_SUPPORTED +#define PNG_WRITE_SHIFT_SUPPORTED +#define PNG_WRITE_SUPPORTED +#define PNG_WRITE_SWAP_ALPHA_SUPPORTED +#define PNG_WRITE_SWAP_SUPPORTED +#define PNG_WRITE_TEXT_SUPPORTED +#define PNG_WRITE_TRANSFORMS_SUPPORTED +#define PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED +#define PNG_WRITE_USER_TRANSFORM_SUPPORTED +#define PNG_WRITE_WEIGHTED_FILTER_SUPPORTED +#define PNG_WRITE_bKGD_SUPPORTED +#define PNG_WRITE_cHRM_SUPPORTED +#define PNG_WRITE_gAMA_SUPPORTED +#define PNG_WRITE_hIST_SUPPORTED +#define PNG_WRITE_iCCP_SUPPORTED +#define PNG_WRITE_iTXt_SUPPORTED +#define PNG_WRITE_oFFs_SUPPORTED +#define PNG_WRITE_pCAL_SUPPORTED +#define PNG_WRITE_pHYs_SUPPORTED +#define PNG_WRITE_sBIT_SUPPORTED +#define PNG_WRITE_sCAL_SUPPORTED +#define PNG_WRITE_sPLT_SUPPORTED +#define PNG_WRITE_sRGB_SUPPORTED +#define PNG_WRITE_tEXt_SUPPORTED +#define PNG_WRITE_tIME_SUPPORTED +#define PNG_WRITE_tRNS_SUPPORTED +#define PNG_WRITE_zTXt_SUPPORTED +#define PNG_bKGD_SUPPORTED +#define PNG_cHRM_SUPPORTED +#define PNG_gAMA_SUPPORTED +#define PNG_hIST_SUPPORTED +#define PNG_iCCP_SUPPORTED +#define PNG_iTXt_SUPPORTED +#define PNG_oFFs_SUPPORTED +#define PNG_pCAL_SUPPORTED +#define PNG_pHYs_SUPPORTED +#define PNG_sBIT_SUPPORTED +#define PNG_sCAL_SUPPORTED +#define PNG_sPLT_SUPPORTED +#define PNG_sRGB_SUPPORTED +#define PNG_tEXt_SUPPORTED +#define PNG_tIME_SUPPORTED +#define PNG_tRNS_SUPPORTED +#define PNG_zTXt_SUPPORTED +/* end of options */ /* settings */ #define PNG_API_RULE 0 #define PNG_CALLOC_SUPPORTED @@ -34,158 +185,4 @@ #define PNG_ZBUF_SIZE 8192 #define PNG_sCAL_PRECISION 5 /* end of settings */ -/* options */ -#define PNG_16BIT_SUPPORTED 1 -#define PNG_ALIGNED_MEMORY_SUPPORTED -#define PNG_ARM_NEON_CHECK_SUPPORTED -#define PNG_BENIGN_ERRORS_SUPPORTED 1 -#define PNG_BUILD_GRAYSCALE_PALETTE_SUPPORTED 1 -#define PNG_CHECK_FOR_INVALID_INDEX_SUPPORTED 1 -#define PNG_CHECK_cHRM_SUPPORTED 1 -#define PNG_CONSOLE_IO_SUPPORTED 1 -#define PNG_CONVERT_tIME_SUPPORTED 1 -#define PNG_EASY_ACCESS_SUPPORTED 1 -/*#undef PNG_ERROR_NUMBERS_SUPPORTED*/ -#define PNG_ERROR_TEXT_SUPPORTED 1 -#define PNG_FIXED_POINT_SUPPORTED 1 -#define PNG_FLOATING_ARITHMETIC_SUPPORTED 1 -#define PNG_FLOATING_POINT_SUPPORTED 1 -#define PNG_GET_PALETTE_MAX_SUPPORTED 1 -#define PNG_HANDLE_AS_UNKNOWN_SUPPORTED 1 -#define PNG_INCH_CONVERSIONS_SUPPORTED 1 -#define PNG_INFO_IMAGE_SUPPORTED 1 -#define PNG_IO_STATE_SUPPORTED 1 -#define PNG_MNG_FEATURES_SUPPORTED 1 -#define PNG_POINTER_INDEXING_SUPPORTED 1 -#define PNG_PROGRESSIVE_READ_SUPPORTED 1 -#define PNG_READ_16BIT_SUPPORTED 1 -#define PNG_READ_ALPHA_MODE_SUPPORTED 1 -#define PNG_READ_ANCILLARY_CHUNKS_SUPPORTED 1 -#define PNG_READ_BACKGROUND_SUPPORTED 1 -#define PNG_READ_BGR_SUPPORTED 1 -#define PNG_READ_CHECK_FOR_INVALID_INDEX_SUPPORTED 1 -#define PNG_READ_COMPOSITE_NODIV_SUPPORTED 1 -#define PNG_READ_COMPRESSED_TEXT_SUPPORTED 1 -#define PNG_READ_EXPAND_16_SUPPORTED 1 -#define PNG_READ_EXPAND_SUPPORTED 1 -#define PNG_READ_FILLER_SUPPORTED 1 -#define PNG_READ_GAMMA_SUPPORTED 1 -#define PNG_READ_GET_PALETTE_MAX_SUPPORTED 1 -#define PNG_READ_GRAY_TO_RGB_SUPPORTED 1 -#define PNG_READ_INTERLACING_SUPPORTED 1 -#define PNG_READ_INT_FUNCTIONS_SUPPORTED 1 -#define PNG_READ_INVERT_ALPHA_SUPPORTED 1 -#define PNG_READ_INVERT_SUPPORTED 1 -#define PNG_READ_OPT_PLTE_SUPPORTED 1 -#define PNG_READ_PACKSWAP_SUPPORTED 1 -#define PNG_READ_PACK_SUPPORTED 1 -#define PNG_READ_QUANTIZE_SUPPORTED 1 -#define PNG_READ_RGB_TO_GRAY_SUPPORTED 1 -#define PNG_READ_SCALE_16_TO_8_SUPPORTED 1 -#define PNG_READ_SHIFT_SUPPORTED 1 -#define PNG_READ_STRIP_16_TO_8_SUPPORTED 1 -#define PNG_READ_STRIP_ALPHA_SUPPORTED 1 -#define PNG_READ_SUPPORTED 1 -#define PNG_READ_SWAP_ALPHA_SUPPORTED 1 -#define PNG_READ_SWAP_SUPPORTED 1 -#define PNG_READ_TEXT_SUPPORTED 1 -#define PNG_READ_TRANSFORMS_SUPPORTED 1 -#define PNG_READ_UNKNOWN_CHUNKS_SUPPORTED 1 -#define PNG_READ_USER_CHUNKS_SUPPORTED 1 -#define PNG_READ_USER_TRANSFORM_SUPPORTED 1 -#define PNG_READ_bKGD_SUPPORTED 1 -#define PNG_READ_cHRM_SUPPORTED 1 -#define PNG_READ_gAMA_SUPPORTED 1 -#define PNG_READ_hIST_SUPPORTED 1 -#define PNG_READ_iCCP_SUPPORTED 1 -#define PNG_READ_iTXt_SUPPORTED 1 -#define PNG_READ_oFFs_SUPPORTED 1 -#define PNG_READ_pCAL_SUPPORTED 1 -#define PNG_READ_pHYs_SUPPORTED 1 -#define PNG_READ_sBIT_SUPPORTED 1 -#define PNG_READ_sCAL_SUPPORTED 1 -#define PNG_READ_sPLT_SUPPORTED 1 -#define PNG_READ_sRGB_SUPPORTED 1 -#define PNG_READ_tEXt_SUPPORTED 1 -#define PNG_READ_tIME_SUPPORTED 1 -#define PNG_READ_tRNS_SUPPORTED 1 -#define PNG_READ_zTXt_SUPPORTED 1 -/*#undef PNG_SAFE_LIMITS_SUPPORTED*/ -#define PNG_SAVE_INT_32_SUPPORTED 1 -#define PNG_SEQUENTIAL_READ_SUPPORTED 1 -#define PNG_SETJMP_SUPPORTED 1 -#define PNG_SET_CHUNK_CACHE_LIMIT_SUPPORTED 1 -#define PNG_SET_CHUNK_MALLOC_LIMIT_SUPPORTED 1 -#define PNG_SET_USER_LIMITS_SUPPORTED 1 -#define PNG_STDIO_SUPPORTED 1 -#define PNG_TEXT_SUPPORTED 1 -#define PNG_TIME_RFC1123_SUPPORTED 1 -#define PNG_UNKNOWN_CHUNKS_SUPPORTED 1 -#define PNG_USER_CHUNKS_SUPPORTED 1 -#define PNG_USER_LIMITS_SUPPORTED 1 -#define PNG_USER_MEM_SUPPORTED 1 -#define PNG_USER_TRANSFORM_INFO_SUPPORTED 1 -#define PNG_USER_TRANSFORM_PTR_SUPPORTED 1 -#define PNG_WARNINGS_SUPPORTED 1 -#define PNG_WRITE_16BIT_SUPPORTED 1 -#define PNG_WRITE_ANCILLARY_CHUNKS_SUPPORTED 1 -#define PNG_WRITE_BGR_SUPPORTED 1 -#define PNG_WRITE_CHECK_FOR_INVALID_INDEX_SUPPORTED 1 -#define PNG_WRITE_COMPRESSED_TEXT_SUPPORTED 1 -#define PNG_WRITE_CUSTOMIZE_ZTXT_COMPRESSION_SUPPORTED 1 -#define PNG_WRITE_FILLER_SUPPORTED 1 -#define PNG_WRITE_FILTER_SUPPORTED 1 -#define PNG_WRITE_FLUSH_SUPPORTED 1 -#define PNG_WRITE_GET_PALETTE_MAX_SUPPORTED 1 -#define PNG_WRITE_INTERLACING_SUPPORTED 1 -#define PNG_WRITE_INT_FUNCTIONS_SUPPORTED 1 -#define PNG_WRITE_INVERT_ALPHA_SUPPORTED 1 -#define PNG_WRITE_INVERT_SUPPORTED 1 -#define PNG_WRITE_OPTIMIZE_CMF_SUPPORTED 1 -#define PNG_WRITE_PACKSWAP_SUPPORTED 1 -#define PNG_WRITE_PACK_SUPPORTED 1 -#define PNG_WRITE_SHIFT_SUPPORTED 1 -#define PNG_WRITE_SUPPORTED 1 -#define PNG_WRITE_SWAP_ALPHA_SUPPORTED 1 -#define PNG_WRITE_SWAP_SUPPORTED 1 -#define PNG_WRITE_TEXT_SUPPORTED 1 -#define PNG_WRITE_TRANSFORMS_SUPPORTED 1 -#define PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED 1 -#define PNG_WRITE_USER_TRANSFORM_SUPPORTED 1 -#define PNG_WRITE_WEIGHTED_FILTER_SUPPORTED 1 -#define PNG_WRITE_bKGD_SUPPORTED 1 -#define PNG_WRITE_cHRM_SUPPORTED 1 -#define PNG_WRITE_gAMA_SUPPORTED 1 -#define PNG_WRITE_hIST_SUPPORTED 1 -#define PNG_WRITE_iCCP_SUPPORTED 1 -#define PNG_WRITE_iTXt_SUPPORTED 1 -#define PNG_WRITE_oFFs_SUPPORTED 1 -#define PNG_WRITE_pCAL_SUPPORTED 1 -#define PNG_WRITE_pHYs_SUPPORTED 1 -#define PNG_WRITE_sBIT_SUPPORTED 1 -#define PNG_WRITE_sCAL_SUPPORTED 1 -#define PNG_WRITE_sPLT_SUPPORTED 1 -#define PNG_WRITE_sRGB_SUPPORTED 1 -#define PNG_WRITE_tEXt_SUPPORTED 1 -#define PNG_WRITE_tIME_SUPPORTED 1 -#define PNG_WRITE_tRNS_SUPPORTED 1 -#define PNG_WRITE_zTXt_SUPPORTED 1 -#define PNG_bKGD_SUPPORTED 1 -#define PNG_cHRM_SUPPORTED 1 -#define PNG_gAMA_SUPPORTED 1 -#define PNG_hIST_SUPPORTED 1 -#define PNG_iCCP_SUPPORTED 1 -#define PNG_iTXt_SUPPORTED 1 -#define PNG_oFFs_SUPPORTED 1 -#define PNG_pCAL_SUPPORTED 1 -#define PNG_pHYs_SUPPORTED 1 -#define PNG_sBIT_SUPPORTED 1 -#define PNG_sCAL_SUPPORTED 1 -#define PNG_sPLT_SUPPORTED 1 -#define PNG_sRGB_SUPPORTED 1 -#define PNG_tEXt_SUPPORTED 1 -#define PNG_tIME_SUPPORTED 1 -#define PNG_tRNS_SUPPORTED 1 -#define PNG_zTXt_SUPPORTED 1 -/* end of options */ #endif /* PNGLCONF_H */ diff --git a/scripts/symbols.def b/scripts/symbols.def index 7e52956a2..fe9d9ca2c 100644 --- a/scripts/symbols.def +++ b/scripts/symbols.def @@ -1,3 +1,4 @@ +;Version 1.5.16beta06 ;-------------------------------------------------------------- ; LIBPNG symbol list as a Win32 DEF file ; Contains all the symbols that can be exported from libpng @@ -5,7 +6,6 @@ LIBRARY EXPORTS -;Version 1.5.15beta06 png_access_version_number @1 png_set_sig_bytes @2 png_sig_cmp @3 @@ -241,3 +241,4 @@ EXPORTS png_set_cHRM_XYZ_fixed @233 png_set_check_for_invalid_index @234 png_get_palette_max @235 + png_set_option @236 diff --git a/scripts/symbols.dfn b/scripts/symbols.dfn index ca45b7432..0341268f2 100644 --- a/scripts/symbols.dfn +++ b/scripts/symbols.dfn @@ -35,13 +35,14 @@ * defaulted to 'off' in scripts/pnglibconf.dfa * * Maintenance: if scripts/pnglibconf.dfa options are changed - * from, or to, 'off' this needs updating! + * from, or to, 'disabled' this needs updating! */ #define PNG_BENIGN_ERRORS_SUPPORTED #define PNG_ERROR_NUMBERS_SUPPORTED #define PNG_READ_BIG_ENDIAN_SUPPORTED /* should do nothing! */ #define PNG_INCH_CONVERSIONS_SUPPORTED #define PNG_READ_16_TO_8_ACCURATE_SCALE_SUPPORTED +#define PNG_SET_OPTION_SUPPORTED #undef PNG_H #include "../png.h" |