From a6b4df7efa05876f673d9baff5ccc7932641e60c Mon Sep 17 00:00:00 2001 From: Ozkan Sezer Date: Fri, 18 Sep 2020 20:39:03 +0300 Subject: [PATCH] external libs: update libjpeg to latest 9d release. --- Android.mk | 2 +- CMakeLists.txt | 2 +- VisualC/external/include/jerror.h | 4 +- VisualC/external/include/jpeglib.h | 11 +- VisualC/external/lib/x64/libjpeg-9.dll | Bin 204800 -> 206336 bytes VisualC/external/lib/x86/libjpeg-9.dll | Bin 208896 -> 209408 bytes external/jpeg-9c/CMakeLists.txt | 24 - external/jpeg-9c/jcomapi.c | 106 --- external/jpeg-9c/jmorecfg.h | 453 ------------ external/jpeg-9c/rdgif.c | 38 - external/jpeg-9c/testimgp.jpg | Bin 5645 -> 0 bytes external/{jpeg-9c.patch => jpeg-9d.patch} | 16 +- external/{jpeg-9c => jpeg-9d}/Android.mk | 0 external/{jpeg-9c => jpeg-9d}/Makefile.am | 22 +- external/{jpeg-9c => jpeg-9d}/Makefile.in | 450 ++++++++---- external/{jpeg-9c => jpeg-9d}/README | 19 +- external/{jpeg-9c => jpeg-9d}/aclocal.m4 | 193 +++-- external/{jpeg-9c => jpeg-9d}/ar-lib | 4 +- external/{jpeg-9c => jpeg-9d}/cderror.h | 0 external/{jpeg-9c => jpeg-9d}/cdjpeg.c | 0 external/{jpeg-9c => jpeg-9d}/cdjpeg.h | 4 +- external/{jpeg-9c => jpeg-9d}/change.log | 49 ++ external/{jpeg-9c => jpeg-9d}/cjpeg.1 | 17 +- external/{jpeg-9c => jpeg-9d}/cjpeg.c | 0 external/{jpeg-9c => jpeg-9d}/ckconfig.c | 0 external/{jpeg-9c => jpeg-9d}/coderules.txt | 0 external/{jpeg-9c => jpeg-9d}/compile | 8 +- external/{jpeg-9c => jpeg-9d}/config.guess | 559 +++++++------- external/{jpeg-9c => jpeg-9d}/config.sub | 249 +++---- external/{jpeg-9c => jpeg-9d}/configure | 221 +++--- external/{jpeg-9c => jpeg-9d}/configure.ac | 9 +- external/{jpeg-9c => jpeg-9d}/depcomp | 8 +- external/{jpeg-9c => jpeg-9d}/djpeg.1 | 33 +- external/{jpeg-9c => jpeg-9d}/djpeg.c | 25 +- external/{jpeg-9c => jpeg-9d}/example.c | 0 external/{jpeg-9c => jpeg-9d}/filelist.txt | 6 +- external/{jpeg-9c => jpeg-9d}/install-sh | 45 +- external/{jpeg-9c => jpeg-9d}/install.txt | 58 +- external/{jpeg-9c => jpeg-9d}/jaricom.c | 0 external/{jpeg-9c => jpeg-9d}/jcapimin.c | 0 external/{jpeg-9c => jpeg-9d}/jcapistd.c | 0 external/{jpeg-9c => jpeg-9d}/jcarith.c | 17 +- external/{jpeg-9c => jpeg-9d}/jccoefct.c | 0 external/{jpeg-9c => jpeg-9d}/jccolor.c | 97 ++- external/{jpeg-9c => jpeg-9d}/jcdctmgr.c | 0 external/{jpeg-9c => jpeg-9d}/jchuff.c | 151 ++-- external/{jpeg-9c => jpeg-9d}/jcinit.c | 0 external/{jpeg-9c => jpeg-9d}/jcmainct.c | 0 external/{jpeg-9c => jpeg-9d}/jcmarker.c | 8 +- external/{jpeg-9c => jpeg-9d}/jcmaster.c | 33 +- external/jpeg-9d/jcomapi.c | 244 +++++++ external/{jpeg-9c => jpeg-9d}/jconfig.bcc | 0 external/{jpeg-9c => jpeg-9d}/jconfig.cfg | 0 external/{jpeg-9c => jpeg-9d}/jconfig.dj | 0 external/{jpeg-9c => jpeg-9d}/jconfig.h | 0 external/{jpeg-9c => jpeg-9d}/jconfig.mac | 0 external/{jpeg-9c => jpeg-9d}/jconfig.manx | 0 external/{jpeg-9c => jpeg-9d}/jconfig.mc6 | 0 external/{jpeg-9c => jpeg-9d}/jconfig.sas | 0 external/{jpeg-9c => jpeg-9d}/jconfig.st | 0 external/{jpeg-9c => jpeg-9d}/jconfig.txt | 0 external/{jpeg-9c => jpeg-9d}/jconfig.vc | 0 external/{jpeg-9c => jpeg-9d}/jconfig.vms | 0 external/{jpeg-9c => jpeg-9d}/jconfig.wat | 0 external/{jpeg-9c => jpeg-9d}/jcparam.c | 113 +-- external/{jpeg-9c => jpeg-9d}/jcprepct.c | 0 external/{jpeg-9c => jpeg-9d}/jcsample.c | 0 external/{jpeg-9c => jpeg-9d}/jctrans.c | 0 external/{jpeg-9c => jpeg-9d}/jdapimin.c | 0 external/{jpeg-9c => jpeg-9d}/jdapistd.c | 0 external/{jpeg-9c => jpeg-9d}/jdarith.c | 28 +- external/{jpeg-9c => jpeg-9d}/jdatadst.c | 23 +- external/{jpeg-9c => jpeg-9d}/jdatasrc.c | 31 +- external/{jpeg-9c => jpeg-9d}/jdcoefct.c | 0 external/{jpeg-9c => jpeg-9d}/jdcolor.c | 130 ++-- external/{jpeg-9c => jpeg-9d}/jdct.h | 9 +- external/{jpeg-9c => jpeg-9d}/jddctmgr.c | 0 external/{jpeg-9c => jpeg-9d}/jdhuff.c | 106 +-- external/{jpeg-9c => jpeg-9d}/jdinput.c | 0 external/{jpeg-9c => jpeg-9d}/jdmainct.c | 0 external/{jpeg-9c => jpeg-9d}/jdmarker.c | 20 +- external/{jpeg-9c => jpeg-9d}/jdmaster.c | 47 +- external/{jpeg-9c => jpeg-9d}/jdmerge.c | 65 +- external/{jpeg-9c => jpeg-9d}/jdpostct.c | 0 external/{jpeg-9c => jpeg-9d}/jdsample.c | 0 external/{jpeg-9c => jpeg-9d}/jdtrans.c | 0 external/{jpeg-9c => jpeg-9d}/jerror.c | 0 external/{jpeg-9c => jpeg-9d}/jerror.h | 4 +- external/{jpeg-9c => jpeg-9d}/jfdctflt.c | 0 external/{jpeg-9c => jpeg-9d}/jfdctfst.c | 0 external/{jpeg-9c => jpeg-9d}/jfdctint.c | 116 +-- external/{jpeg-9c => jpeg-9d}/jidctflt.c | 0 external/{jpeg-9c => jpeg-9d}/jidctfst.S | 0 external/{jpeg-9c => jpeg-9d}/jidctfst.c | 0 external/{jpeg-9c => jpeg-9d}/jidctint.c | 12 +- external/{jpeg-9c => jpeg-9d}/jinclude.h | 0 external/{jpeg-9c => jpeg-9d}/jmem-android.c | 0 external/{jpeg-9c => jpeg-9d}/jmemansi.c | 0 external/{jpeg-9c => jpeg-9d}/jmemdos.c | 0 external/{jpeg-9c => jpeg-9d}/jmemdosa.asm | 0 external/{jpeg-9c => jpeg-9d}/jmemmac.c | 0 external/{jpeg-9c => jpeg-9d}/jmemmgr.c | 60 +- external/{jpeg-9c => jpeg-9d}/jmemname.c | 0 external/{jpeg-9c => jpeg-9d}/jmemnobs.c | 8 +- external/{jpeg-9c => jpeg-9d}/jmemsys.h | 0 .../jmorecfg.h~ => jpeg-9d/jmorecfg.h} | 0 external/{jpeg-9c => jpeg-9d}/jpegint.h | 9 +- external/{jpeg-9c => jpeg-9d}/jpeglib.h | 11 +- external/{jpeg-9c => jpeg-9d}/jpegtran.1 | 30 +- external/{jpeg-9c => jpeg-9d}/jpegtran.c | 91 ++- external/{jpeg-9c => jpeg-9d}/jquant1.c | 0 external/{jpeg-9c => jpeg-9d}/jquant2.c | 0 external/{jpeg-9c => jpeg-9d}/jutils.c | 6 +- external/{jpeg-9c => jpeg-9d}/jversion.h | 6 +- external/{jpeg-9c => jpeg-9d}/libjpeg.map | 0 external/{jpeg-9c => jpeg-9d}/libjpeg.pc.in | 2 +- external/{jpeg-9c => jpeg-9d}/libjpeg.txt | 51 +- external/{jpeg-9c => jpeg-9d}/ltmain.sh | 0 external/{jpeg-9c => jpeg-9d}/makcjpeg.st | 0 external/{jpeg-9c => jpeg-9d}/makdjpeg.st | 0 external/{jpeg-9c => jpeg-9d}/makeadsw.vc6 | 0 .../makeasln.v15 => jpeg-9d/makeasln.v16} | 20 +- external/{jpeg-9c => jpeg-9d}/makecdep.vc6 | 0 external/{jpeg-9c => jpeg-9d}/makecdsp.vc6 | 4 +- .../makecfil.v15 => jpeg-9d/makecfil.v16} | 0 external/{jpeg-9c => jpeg-9d}/makecmak.vc6 | 0 .../makecvcx.v15 => jpeg-9d/makecvcx.v16} | 49 +- external/{jpeg-9c => jpeg-9d}/makeddep.vc6 | 0 external/{jpeg-9c => jpeg-9d}/makeddsp.vc6 | 4 +- .../makedfil.v15 => jpeg-9d/makedfil.v16} | 0 external/{jpeg-9c => jpeg-9d}/makedmak.vc6 | 0 .../makedvcx.v15 => jpeg-9d/makedvcx.v16} | 49 +- external/{jpeg-9c => jpeg-9d}/makefile.ansi | 18 +- external/{jpeg-9c => jpeg-9d}/makefile.b32 | 18 +- external/{jpeg-9c => jpeg-9d}/makefile.bcc | 19 +- external/{jpeg-9c => jpeg-9d}/makefile.dj | 18 +- external/{jpeg-9c => jpeg-9d}/makefile.manx | 18 +- external/{jpeg-9c => jpeg-9d}/makefile.mc6 | 18 +- external/{jpeg-9c => jpeg-9d}/makefile.mms | 14 +- external/{jpeg-9c => jpeg-9d}/makefile.sas | 18 +- external/{jpeg-9c => jpeg-9d}/makefile.unix | 18 +- external/{jpeg-9c => jpeg-9d}/makefile.vc | 150 +++- external/{jpeg-9c => jpeg-9d}/makefile.vms | 0 external/{jpeg-9c => jpeg-9d}/makefile.vs | 150 +++- external/{jpeg-9c => jpeg-9d}/makefile.wat | 19 +- external/{jpeg-9c => jpeg-9d}/makejdep.vc6 | 0 external/{jpeg-9c => jpeg-9d}/makejdsp.vc6 | 2 +- external/{jpeg-9c => jpeg-9d}/makejdsw.vc6 | 0 .../makejfil.v15 => jpeg-9d/makejfil.v16} | 0 external/{jpeg-9c => jpeg-9d}/makejmak.vc6 | 0 .../makejsln.v15 => jpeg-9d/makejsln.v16} | 12 +- .../makejvcx.v15 => jpeg-9d/makejvcx.v16} | 45 +- external/{jpeg-9c => jpeg-9d}/makeproj.mac | 0 external/{jpeg-9c => jpeg-9d}/makerdep.vc6 | 0 external/{jpeg-9c => jpeg-9d}/makerdsp.vc6 | 4 +- .../makerfil.v15 => jpeg-9d/makerfil.v16} | 0 external/{jpeg-9c => jpeg-9d}/makermak.vc6 | 0 .../makervcx.v15 => jpeg-9d/makervcx.v16} | 46 +- external/{jpeg-9c => jpeg-9d}/maketdep.vc6 | 0 external/{jpeg-9c => jpeg-9d}/maketdsp.vc6 | 4 +- .../maketfil.v15 => jpeg-9d/maketfil.v16} | 0 external/{jpeg-9c => jpeg-9d}/maketmak.vc6 | 0 .../maketvcx.v15 => jpeg-9d/maketvcx.v16} | 49 +- external/{jpeg-9c => jpeg-9d}/makewdep.vc6 | 0 external/{jpeg-9c => jpeg-9d}/makewdsp.vc6 | 4 +- .../makewfil.v15 => jpeg-9d/makewfil.v16} | 0 external/{jpeg-9c => jpeg-9d}/makewmak.vc6 | 0 .../makewvcx.v15 => jpeg-9d/makewvcx.v16} | 46 +- external/{jpeg-9c => jpeg-9d}/makljpeg.st | 0 external/{jpeg-9c => jpeg-9d}/maktjpeg.st | 0 external/{jpeg-9c => jpeg-9d}/makvms.opt | 0 external/{jpeg-9c => jpeg-9d}/missing | 14 +- external/{jpeg-9c => jpeg-9d}/rdbmp.c | 97 +-- external/{jpeg-9c => jpeg-9d}/rdcolmap.c | 0 external/jpeg-9d/rdgif.c | 677 +++++++++++++++++ external/{jpeg-9c => jpeg-9d}/rdjpgcom.1 | 0 external/{jpeg-9c => jpeg-9d}/rdjpgcom.c | 0 external/{jpeg-9c => jpeg-9d}/rdppm.c | 27 +- external/{jpeg-9c => jpeg-9d}/rdrle.c | 67 +- external/{jpeg-9c => jpeg-9d}/rdswitch.c | 7 +- external/{jpeg-9c => jpeg-9d}/rdtarga.c | 34 +- external/{jpeg-9c => jpeg-9d}/structure.txt | 0 external/{jpeg-9c => jpeg-9d}/testimg.bmp | Bin external/jpeg-9d/testimg.gif | Bin 0 -> 21718 bytes external/{jpeg-9c => jpeg-9d}/testimg.jpg | Bin external/{jpeg-9c => jpeg-9d}/testimg.ppm | 0 external/jpeg-9d/testimgp.jpg | Bin 0 -> 5645 bytes external/{jpeg-9c => jpeg-9d}/testorig.jpg | Bin external/{jpeg-9c => jpeg-9d}/testprog.jpg | Bin external/{jpeg-9c => jpeg-9d}/transupp.c | 682 +++++++++++++++++- external/{jpeg-9c => jpeg-9d}/transupp.h | 31 +- external/{jpeg-9c => jpeg-9d}/usage.txt | 57 +- external/{jpeg-9c => jpeg-9d}/wizard.txt | 0 external/{jpeg-9c => jpeg-9d}/wrbmp.c | 48 +- external/{jpeg-9c => jpeg-9d}/wrgif.c | 334 ++++++--- external/{jpeg-9c => jpeg-9d}/wrjpgcom.1 | 0 external/{jpeg-9c => jpeg-9d}/wrjpgcom.c | 0 external/{jpeg-9c => jpeg-9d}/wrppm.c | 18 +- external/{jpeg-9c => jpeg-9d}/wrrle.c | 54 +- external/{jpeg-9c => jpeg-9d}/wrtarga.c | 36 +- 200 files changed, 4469 insertions(+), 2693 deletions(-) delete mode 100644 external/jpeg-9c/CMakeLists.txt delete mode 100644 external/jpeg-9c/jcomapi.c delete mode 100644 external/jpeg-9c/jmorecfg.h delete mode 100644 external/jpeg-9c/rdgif.c delete mode 100644 external/jpeg-9c/testimgp.jpg rename external/{jpeg-9c.patch => jpeg-9d.patch} (99%) rename external/{jpeg-9c => jpeg-9d}/Android.mk (100%) rename external/{jpeg-9c => jpeg-9d}/Makefile.am (85%) rename external/{jpeg-9c => jpeg-9d}/Makefile.in (78%) rename external/{jpeg-9c => jpeg-9d}/README (96%) rename external/{jpeg-9c => jpeg-9d}/aclocal.m4 (98%) rename external/{jpeg-9c => jpeg-9d}/ar-lib (97%) rename external/{jpeg-9c => jpeg-9d}/cderror.h (100%) rename external/{jpeg-9c => jpeg-9d}/cdjpeg.c (100%) rename external/{jpeg-9c => jpeg-9d}/cdjpeg.h (98%) rename external/{jpeg-9c => jpeg-9d}/change.log (91%) rename external/{jpeg-9c => jpeg-9d}/cjpeg.1 (97%) rename external/{jpeg-9c => jpeg-9d}/cjpeg.c (100%) rename external/{jpeg-9c => jpeg-9d}/ckconfig.c (100%) rename external/{jpeg-9c => jpeg-9d}/coderules.txt (100%) rename external/{jpeg-9c => jpeg-9d}/compile (97%) rename external/{jpeg-9c => jpeg-9d}/config.guess (72%) rename external/{jpeg-9c => jpeg-9d}/config.sub (85%) rename external/{jpeg-9c => jpeg-9d}/configure (99%) rename external/{jpeg-9c => jpeg-9d}/configure.ac (98%) rename external/{jpeg-9c => jpeg-9d}/depcomp (99%) rename external/{jpeg-9c => jpeg-9d}/djpeg.1 (90%) rename external/{jpeg-9c => jpeg-9d}/djpeg.c (96%) rename external/{jpeg-9c => jpeg-9d}/example.c (100%) rename external/{jpeg-9c => jpeg-9d}/filelist.txt (98%) rename external/{jpeg-9c => jpeg-9d}/install-sh (90%) rename external/{jpeg-9c => jpeg-9d}/install.txt (96%) rename external/{jpeg-9c => jpeg-9d}/jaricom.c (100%) rename external/{jpeg-9c => jpeg-9d}/jcapimin.c (100%) rename external/{jpeg-9c => jpeg-9d}/jcapistd.c (100%) rename external/{jpeg-9c => jpeg-9d}/jcarith.c (98%) rename external/{jpeg-9c => jpeg-9d}/jccoefct.c (100%) rename external/{jpeg-9c => jpeg-9d}/jccolor.c (91%) rename external/{jpeg-9c => jpeg-9d}/jcdctmgr.c (100%) rename external/{jpeg-9c => jpeg-9d}/jchuff.c (93%) rename external/{jpeg-9c => jpeg-9d}/jcinit.c (100%) rename external/{jpeg-9c => jpeg-9d}/jcmainct.c (100%) rename external/{jpeg-9c => jpeg-9d}/jcmarker.c (99%) rename external/{jpeg-9c => jpeg-9d}/jcmaster.c (96%) create mode 100644 external/jpeg-9d/jcomapi.c rename external/{jpeg-9c => jpeg-9d}/jconfig.bcc (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.cfg (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.dj (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.h (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.mac (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.manx (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.mc6 (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.sas (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.st (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.txt (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.vc (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.vms (100%) rename external/{jpeg-9c => jpeg-9d}/jconfig.wat (100%) rename external/{jpeg-9c => jpeg-9d}/jcparam.c (81%) rename external/{jpeg-9c => jpeg-9d}/jcprepct.c (100%) rename external/{jpeg-9c => jpeg-9d}/jcsample.c (100%) rename external/{jpeg-9c => jpeg-9d}/jctrans.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdapimin.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdapistd.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdarith.c (97%) rename external/{jpeg-9c => jpeg-9d}/jdatadst.c (92%) rename external/{jpeg-9c => jpeg-9d}/jdatasrc.c (91%) rename external/{jpeg-9c => jpeg-9d}/jdcoefct.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdcolor.c (87%) rename external/{jpeg-9c => jpeg-9d}/jdct.h (98%) rename external/{jpeg-9c => jpeg-9d}/jddctmgr.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdhuff.c (94%) rename external/{jpeg-9c => jpeg-9d}/jdinput.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdmainct.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdmarker.c (99%) rename external/{jpeg-9c => jpeg-9d}/jdmaster.c (95%) rename external/{jpeg-9c => jpeg-9d}/jdmerge.c (88%) rename external/{jpeg-9c => jpeg-9d}/jdpostct.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdsample.c (100%) rename external/{jpeg-9c => jpeg-9d}/jdtrans.c (100%) rename external/{jpeg-9c => jpeg-9d}/jerror.c (100%) rename external/{jpeg-9c => jpeg-9d}/jerror.h (99%) rename external/{jpeg-9c => jpeg-9d}/jfdctflt.c (100%) rename external/{jpeg-9c => jpeg-9d}/jfdctfst.c (100%) rename external/{jpeg-9c => jpeg-9d}/jfdctint.c (98%) rename external/{jpeg-9c => jpeg-9d}/jidctflt.c (100%) rename external/{jpeg-9c => jpeg-9d}/jidctfst.S (100%) rename external/{jpeg-9c => jpeg-9d}/jidctfst.c (100%) rename external/{jpeg-9c => jpeg-9d}/jidctint.c (99%) rename external/{jpeg-9c => jpeg-9d}/jinclude.h (100%) rename external/{jpeg-9c => jpeg-9d}/jmem-android.c (100%) rename external/{jpeg-9c => jpeg-9d}/jmemansi.c (100%) rename external/{jpeg-9c => jpeg-9d}/jmemdos.c (100%) rename external/{jpeg-9c => jpeg-9d}/jmemdosa.asm (100%) rename external/{jpeg-9c => jpeg-9d}/jmemmac.c (100%) rename external/{jpeg-9c => jpeg-9d}/jmemmgr.c (96%) rename external/{jpeg-9c => jpeg-9d}/jmemname.c (100%) rename external/{jpeg-9c => jpeg-9d}/jmemnobs.c (90%) rename external/{jpeg-9c => jpeg-9d}/jmemsys.h (100%) rename external/{jpeg-9c/jmorecfg.h~ => jpeg-9d/jmorecfg.h} (100%) rename external/{jpeg-9c => jpeg-9d}/jpegint.h (98%) rename external/{jpeg-9c => jpeg-9d}/jpeglib.h (99%) rename external/{jpeg-9c => jpeg-9d}/jpegtran.1 (88%) rename external/{jpeg-9c => jpeg-9d}/jpegtran.c (86%) rename external/{jpeg-9c => jpeg-9d}/jquant1.c (100%) rename external/{jpeg-9c => jpeg-9d}/jquant2.c (100%) rename external/{jpeg-9c => jpeg-9d}/jutils.c (97%) rename external/{jpeg-9c => jpeg-9d}/jversion.h (59%) rename external/{jpeg-9c => jpeg-9d}/libjpeg.map (100%) rename external/{jpeg-9c => jpeg-9d}/libjpeg.pc.in (75%) rename external/{jpeg-9c => jpeg-9d}/libjpeg.txt (98%) rename external/{jpeg-9c => jpeg-9d}/ltmain.sh (100%) rename external/{jpeg-9c => jpeg-9d}/makcjpeg.st (100%) rename external/{jpeg-9c => jpeg-9d}/makdjpeg.st (100%) rename external/{jpeg-9c => jpeg-9d}/makeadsw.vc6 (100%) rename external/{jpeg-9c/makeasln.v15 => jpeg-9d/makeasln.v16} (62%) rename external/{jpeg-9c => jpeg-9d}/makecdep.vc6 (100%) rename external/{jpeg-9c => jpeg-9d}/makecdsp.vc6 (97%) rename external/{jpeg-9c/makecfil.v15 => jpeg-9d/makecfil.v16} (100%) rename external/{jpeg-9c => jpeg-9d}/makecmak.vc6 (100%) rename external/{jpeg-9c/makecvcx.v15 => jpeg-9d/makecvcx.v16} (54%) rename external/{jpeg-9c => jpeg-9d}/makeddep.vc6 (100%) rename external/{jpeg-9c => jpeg-9d}/makeddsp.vc6 (97%) rename external/{jpeg-9c/makedfil.v15 => jpeg-9d/makedfil.v16} (100%) rename external/{jpeg-9c => jpeg-9d}/makedmak.vc6 (100%) rename external/{jpeg-9c/makedvcx.v15 => jpeg-9d/makedvcx.v16} (54%) rename external/{jpeg-9c => jpeg-9d}/makefile.ansi (95%) rename external/{jpeg-9c => jpeg-9d}/makefile.b32 (95%) rename external/{jpeg-9c => jpeg-9d}/makefile.bcc (95%) rename external/{jpeg-9c => jpeg-9d}/makefile.dj (95%) rename external/{jpeg-9c => jpeg-9d}/makefile.manx (95%) rename external/{jpeg-9c => jpeg-9d}/makefile.mc6 (95%) rename external/{jpeg-9c => jpeg-9d}/makefile.mms (96%) rename external/{jpeg-9c => jpeg-9d}/makefile.sas (95%) rename external/{jpeg-9c => jpeg-9d}/makefile.unix (95%) rename external/{jpeg-9c => jpeg-9d}/makefile.vc (71%) rename external/{jpeg-9c => jpeg-9d}/makefile.vms (100%) rename external/{jpeg-9c => jpeg-9d}/makefile.vs (71%) rename external/{jpeg-9c => jpeg-9d}/makefile.wat (95%) rename external/{jpeg-9c => jpeg-9d}/makejdep.vc6 (100%) rename external/{jpeg-9c => jpeg-9d}/makejdsp.vc6 (99%) rename external/{jpeg-9c => jpeg-9d}/makejdsw.vc6 (100%) rename external/{jpeg-9c/makejfil.v15 => jpeg-9d/makejfil.v16} (100%) rename external/{jpeg-9c => jpeg-9d}/makejmak.vc6 (100%) rename external/{jpeg-9c/makejsln.v15 => jpeg-9d/makejsln.v16} (56%) rename external/{jpeg-9c/makejvcx.v15 => jpeg-9d/makejvcx.v16} (67%) rename external/{jpeg-9c => jpeg-9d}/makeproj.mac (100%) rename external/{jpeg-9c => jpeg-9d}/makerdep.vc6 (100%) rename external/{jpeg-9c => jpeg-9d}/makerdsp.vc6 (96%) rename external/{jpeg-9c/makerfil.v15 => jpeg-9d/makerfil.v16} (100%) rename external/{jpeg-9c => jpeg-9d}/makermak.vc6 (100%) rename external/{jpeg-9c/makervcx.v15 => jpeg-9d/makervcx.v16} (55%) rename external/{jpeg-9c => jpeg-9d}/maketdep.vc6 (100%) rename external/{jpeg-9c => jpeg-9d}/maketdsp.vc6 (97%) rename external/{jpeg-9c/maketfil.v15 => jpeg-9d/maketfil.v16} (100%) rename external/{jpeg-9c => jpeg-9d}/maketmak.vc6 (100%) rename external/{jpeg-9c/maketvcx.v15 => jpeg-9d/maketvcx.v16} (53%) rename external/{jpeg-9c => jpeg-9d}/makewdep.vc6 (100%) rename external/{jpeg-9c => jpeg-9d}/makewdsp.vc6 (96%) rename external/{jpeg-9c/makewfil.v15 => jpeg-9d/makewfil.v16} (100%) rename external/{jpeg-9c => jpeg-9d}/makewmak.vc6 (100%) rename external/{jpeg-9c/makewvcx.v15 => jpeg-9d/makewvcx.v16} (55%) rename external/{jpeg-9c => jpeg-9d}/makljpeg.st (100%) rename external/{jpeg-9c => jpeg-9d}/maktjpeg.st (100%) rename external/{jpeg-9c => jpeg-9d}/makvms.opt (100%) rename external/{jpeg-9c => jpeg-9d}/missing (95%) rename external/{jpeg-9c => jpeg-9d}/rdbmp.c (84%) rename external/{jpeg-9c => jpeg-9d}/rdcolmap.c (100%) create mode 100644 external/jpeg-9d/rdgif.c rename external/{jpeg-9c => jpeg-9d}/rdjpgcom.1 (100%) rename external/{jpeg-9c => jpeg-9d}/rdjpgcom.c (100%) rename external/{jpeg-9c => jpeg-9d}/rdppm.c (97%) rename external/{jpeg-9c => jpeg-9d}/rdrle.c (86%) rename external/{jpeg-9c => jpeg-9d}/rdswitch.c (98%) rename external/{jpeg-9c => jpeg-9d}/rdtarga.c (94%) rename external/{jpeg-9c => jpeg-9d}/structure.txt (100%) rename external/{jpeg-9c => jpeg-9d}/testimg.bmp (100%) create mode 100644 external/jpeg-9d/testimg.gif rename external/{jpeg-9c => jpeg-9d}/testimg.jpg (100%) rename external/{jpeg-9c => jpeg-9d}/testimg.ppm (100%) create mode 100644 external/jpeg-9d/testimgp.jpg rename external/{jpeg-9c => jpeg-9d}/testorig.jpg (100%) rename external/{jpeg-9c => jpeg-9d}/testprog.jpg (100%) rename external/{jpeg-9c => jpeg-9d}/transupp.c (73%) rename external/{jpeg-9c => jpeg-9d}/transupp.h (90%) rename external/{jpeg-9c => jpeg-9d}/usage.txt (94%) rename external/{jpeg-9c => jpeg-9d}/wizard.txt (100%) rename external/{jpeg-9c => jpeg-9d}/wrbmp.c (92%) rename external/{jpeg-9c => jpeg-9d}/wrgif.c (57%) rename external/{jpeg-9c => jpeg-9d}/wrjpgcom.1 (100%) rename external/{jpeg-9c => jpeg-9d}/wrjpgcom.c (100%) rename external/{jpeg-9c => jpeg-9d}/wrppm.c (94%) rename external/{jpeg-9c => jpeg-9d}/wrrle.c (86%) rename external/{jpeg-9c => jpeg-9d}/wrtarga.c (89%) diff --git a/Android.mk b/Android.mk index 3f02e7c0..840b8700 100644 --- a/Android.mk +++ b/Android.mk @@ -4,7 +4,7 @@ SDL_IMAGE_LOCAL_PATH := $(call my-dir) # Enable this if you want to support loading JPEG images # The library path should be a relative path to this directory. SUPPORT_JPG ?= true -JPG_LIBRARY_PATH := external/jpeg-9c +JPG_LIBRARY_PATH := external/jpeg-9d # Enable this if you want to support loading PNG images # The library path should be a relative path to this directory. diff --git a/CMakeLists.txt b/CMakeLists.txt index df03fb97..bc74a563 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -24,7 +24,7 @@ target_compile_definitions(SDL2_image PRIVATE if (SUPPORT_JPG) target_compile_definitions(SDL2_image PRIVATE -DLOAD_JPG) - add_subdirectory(external/jpeg-9c) + add_subdirectory(external/jpeg-9d) target_link_libraries(SDL2_image PRIVATE jpeg) endif() diff --git a/VisualC/external/include/jerror.h b/VisualC/external/include/jerror.h index a4b661f7..db608b9c 100644 --- a/VisualC/external/include/jerror.h +++ b/VisualC/external/include/jerror.h @@ -2,7 +2,7 @@ * jerror.h * * Copyright (C) 1994-1997, Thomas G. Lane. - * Modified 1997-2012 by Guido Vollbeding. + * Modified 1997-2018 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -84,7 +84,7 @@ JMESSAGE(JERR_EOI_EXPECTED, "Didn't expect more than one scan") JMESSAGE(JERR_FILE_READ, "Input file read error") JMESSAGE(JERR_FILE_WRITE, "Output file write error --- out of disk space?") JMESSAGE(JERR_FRACT_SAMPLE_NOTIMPL, "Fractional sampling not implemented yet") -JMESSAGE(JERR_HUFF_CLEN_OVERFLOW, "Huffman code size table overflow") +JMESSAGE(JERR_HUFF_CLEN_OUTOFBOUNDS, "Huffman code size table out of bounds") JMESSAGE(JERR_HUFF_MISSING_CODE, "Missing Huffman code table entry") JMESSAGE(JERR_IMAGE_TOO_BIG, "Maximum supported image dimension is %u pixels") JMESSAGE(JERR_INPUT_EMPTY, "Empty input file") diff --git a/VisualC/external/include/jpeglib.h b/VisualC/external/include/jpeglib.h index 4bd98531..591a2cb6 100644 --- a/VisualC/external/include/jpeglib.h +++ b/VisualC/external/include/jpeglib.h @@ -2,7 +2,7 @@ * jpeglib.h * * Copyright (C) 1991-1998, Thomas G. Lane. - * Modified 2002-2017 by Guido Vollbeding. + * Modified 2002-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -39,7 +39,7 @@ extern "C" { #define JPEG_LIB_VERSION 90 /* Compatibility version 9.0 */ #define JPEG_LIB_VERSION_MAJOR 9 -#define JPEG_LIB_VERSION_MINOR 3 +#define JPEG_LIB_VERSION_MINOR 4 /* Various constants determining the sizes of things. @@ -909,6 +909,7 @@ typedef JMETHOD(boolean, jpeg_marker_parser_method, (j_decompress_ptr cinfo)); #define jpeg_suppress_tables jSuppressTables #define jpeg_alloc_quant_table jAlcQTable #define jpeg_alloc_huff_table jAlcHTable +#define jpeg_std_huff_table jStdHTable #define jpeg_start_compress jStrtCompress #define jpeg_write_scanlines jWrtScanlines #define jpeg_finish_compress jFinCompress @@ -977,10 +978,10 @@ EXTERN(void) jpeg_stdio_src JPP((j_decompress_ptr cinfo, FILE * infile)); /* Data source and destination managers: memory buffers. */ EXTERN(void) jpeg_mem_dest JPP((j_compress_ptr cinfo, unsigned char ** outbuffer, - unsigned long * outsize)); + size_t * outsize)); EXTERN(void) jpeg_mem_src JPP((j_decompress_ptr cinfo, const unsigned char * inbuffer, - unsigned long insize)); + size_t insize)); /* Default parameter setup for compression */ EXTERN(void) jpeg_set_defaults JPP((j_compress_ptr cinfo)); @@ -1005,6 +1006,8 @@ EXTERN(void) jpeg_suppress_tables JPP((j_compress_ptr cinfo, boolean suppress)); EXTERN(JQUANT_TBL *) jpeg_alloc_quant_table JPP((j_common_ptr cinfo)); EXTERN(JHUFF_TBL *) jpeg_alloc_huff_table JPP((j_common_ptr cinfo)); +EXTERN(JHUFF_TBL *) jpeg_std_huff_table JPP((j_common_ptr cinfo, + boolean isDC, int tblno)); /* Main entry points for compression */ EXTERN(void) jpeg_start_compress JPP((j_compress_ptr cinfo, diff --git a/VisualC/external/lib/x64/libjpeg-9.dll b/VisualC/external/lib/x64/libjpeg-9.dll index 4959df111fb91c501fa72b87059d65b512fca3d1..51d4165a59d0ef666b7e7fc42944eb837b28a8ea 100644 GIT binary patch delta 24656 zcmd6Pdw5LO_xIU*a-)e8B*Zm?!NfJuxP%}hGn`=%6{Mv^qbaSb)Mg(i?3`T-wTogz~MRN>NqScBVnon+9dx&pzi&q?h;izR&ai@qInktbJX3?X}n5 zd+oi~Nq%W${*lO{!q(j`&zQ#P|7y8j9q*zvmODZ@ZsIeq_M^?5&z$K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&=VHwc(sm8bo`@^uj)9yp;m96j#ujV zO&#yi@hKhO&@tags~4x^c@90WRmUD3w`i<$sAECL^K`sg$JIKHjnq4$;~X7t*6}eN zheT=Rl62gejX(Q`rhv~%jYJHE+) z*dOlr0{;gHLVn;6%H!YB8;*vyyS_124L%!sFYHfS{x50%yy5>L&tE3|KbNu8HO?v= z9`a8H{Dl4|>_i=9-fbFLoOG5RG&t7Hzw3*C_O6fN{{lGv8;#!ArsKcT>w641{ySo? zW5DrW81uTu(f0o*=s$t@++AM= z;Jw9nePcmm0K%W3&N~12U&agL{~P$<4dW$r?%&Ed8iR}eOYZuf1y}b&&wokt=XdxI zdHyoZ{twEa>`b-M2LES;|H2?e9sgd$uzAH@-+I7HI=lwVz#lIzxkxt!hRvV;RMzad z&!{zvvoF&LfpBps$FEUigUs02gv4$`rq1csGd>}yIN&-hiEuR0{}k`!-Ujv9_ZDh0 zh{K=FUEkBd#r86A$F@*z9v~iYRi@n5k0_UM1AmtH0hrAx9G4DPN&E(mE7`|!8EFW| z5UyIp7TSPtYwsN*{nw6!K3Z{1Ga$IG_MT*5ZrSbflM@;J9NW(a?63+YEb-<)cnK@~)PG z)^CK{T8{if2wx>!#^;2K{fcnMY8-?sIE{v@!PP~=rGARchLkJ#6P)9#pLzH!W!@)* zD``ME{2di8Vh_sVnMY1NNCQ_i@%VEhS8pO6Pv(vh%EjWn7k39t{ek+Rwe4N%sl&i+y;3&Y~yr|9vjU}LgKV_7<5N*ss-S&vHZ)e(q zF8;`eW9=+tf>(&qB|$Op$2x@7jF1Gu()@mA&(UQ e6ovGn7(;wWnEz-n4@ZRJHf;?D$h&O~0sjlA6Ew#F diff --git a/VisualC/external/lib/x86/libjpeg-9.dll b/VisualC/external/lib/x86/libjpeg-9.dll index ec30067327b28cd81d33265c11933773c519dfa2..c8f5c80dbd318082c88831edcdaad7a558accf1b 100644 GIT binary patch delta 22844 zcmd6PdstM}`u|>gMlL$KQBgq=QBgrrXSm-Pfk9JIykHk4(Uh8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K22$hnZzP;=a3fImX}hXtaQM}{#??gCAUI|5BzjJrk)$*@u(k8AE| zCTOQ=7ip<5Rw`tSHeUOtcBOVm@H@dm_y^$y;pMu-sBuxd%u#!yzM{1$Vx`*NiFp)5 zmo2nr`-4}9DB`-t^@{5s7Z5ihE<7$KE-`K#)Gfvxpc!IH8-sb%otM<3lEfaL`Ou$e$s-LjyubgvN(13C#*!7y4P~(a`Im=7!J* zq0OO+FyFBLs99{-oUqKWyf7im5mpsO!j<8}!pDWr4}UMbDEw4-V|b4U{|HUQvk}in z%!|m5ct2u$L}kS95nj4px&gW&I=ya|ZlP|iZiDV4-6y);x`R50?u70e-DTZ1-A}qd zbiMQ;dc8hQKVJWweuaLOey6_9tp7>>tNwRA8|f7pfS&nmljuw?^)cyczjh zrKAm*SSh#lIPsLsjWy znP@mKX07n%c_qneYNbDHlo*EK(Be$zbCu-f+8F4|t& z;o3y4m^)17KaB~N2YUr8f>psj!M?$M!Ayue#4AJ*q6+Z|@eT0{QNxx3LV`jxA)z6< zkZ9OdA_k@LA;}?AL#Bt!3{gX~0TDsaZfJxqB09nlkr**1LVP?-Hd$4#YtY@&HDR=U zp!-wD=*!ZE%kl{hPH&Hp%~MurPH0YRsx>v5T1}nCDbCZ#l7_qwTd-@lYjmem == NULL) - return; - - /* Releasing pools in reverse order might help avoid fragmentation - * with some (brain-damaged) malloc libraries. - */ - for (pool = JPOOL_NUMPOOLS-1; pool > JPOOL_PERMANENT; pool--) { - (*cinfo->mem->free_pool) (cinfo, pool); - } - - /* Reset overall state for possible reuse of object */ - if (cinfo->is_decompressor) { - cinfo->global_state = DSTATE_START; - /* Try to keep application from accessing now-deleted marker list. - * A bit kludgy to do it here, but this is the most central place. - */ - ((j_decompress_ptr) cinfo)->marker_list = NULL; - } else { - cinfo->global_state = CSTATE_START; - } -} - - -/* - * Destruction of a JPEG object. - * - * Everything gets deallocated except the master jpeg_compress_struct itself - * and the error manager struct. Both of these are supplied by the application - * and must be freed, if necessary, by the application. (Often they are on - * the stack and so don't need to be freed anyway.) - * Closing a data source or destination, if necessary, is the application's - * responsibility. - */ - -GLOBAL(void) -jpeg_destroy (j_common_ptr cinfo) -{ - /* We need only tell the memory manager to release everything. */ - /* NB: mem pointer is NULL if memory mgr failed to initialize. */ - if (cinfo->mem != NULL) - (*cinfo->mem->self_destruct) (cinfo); - cinfo->mem = NULL; /* be safe if jpeg_destroy is called twice */ - cinfo->global_state = 0; /* mark it destroyed */ -} - - -/* - * Convenience routines for allocating quantization and Huffman tables. - * (Would jutils.c be a more reasonable place to put these?) - */ - -GLOBAL(JQUANT_TBL *) -jpeg_alloc_quant_table (j_common_ptr cinfo) -{ - JQUANT_TBL *tbl; - - tbl = (JQUANT_TBL *) - (*cinfo->mem->alloc_small) (cinfo, JPOOL_PERMANENT, SIZEOF(JQUANT_TBL)); - tbl->sent_table = FALSE; /* make sure this is false in any new table */ - return tbl; -} - - -GLOBAL(JHUFF_TBL *) -jpeg_alloc_huff_table (j_common_ptr cinfo) -{ - JHUFF_TBL *tbl; - - tbl = (JHUFF_TBL *) - (*cinfo->mem->alloc_small) (cinfo, JPOOL_PERMANENT, SIZEOF(JHUFF_TBL)); - tbl->sent_table = FALSE; /* make sure this is false in any new table */ - return tbl; -} diff --git a/external/jpeg-9c/jmorecfg.h b/external/jpeg-9c/jmorecfg.h deleted file mode 100644 index 856188f3..00000000 --- a/external/jpeg-9c/jmorecfg.h +++ /dev/null @@ -1,453 +0,0 @@ -/* - * jmorecfg.h - * - * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 1997-2013 by Guido Vollbeding. - * This file is part of the Independent JPEG Group's software. - * For conditions of distribution and use, see the accompanying README file. - * - * This file contains additional configuration options that customize the - * JPEG software for special applications or support machine-dependent - * optimizations. Most users will not need to touch this file. - */ - - -/* - * Define BITS_IN_JSAMPLE as either - * 8 for 8-bit sample values (the usual setting) - * 9 for 9-bit sample values - * 10 for 10-bit sample values - * 11 for 11-bit sample values - * 12 for 12-bit sample values - * Only 8, 9, 10, 11, and 12 bits sample data precision are supported for - * full-feature DCT processing. Further depths up to 16-bit may be added - * later for the lossless modes of operation. - * Run-time selection and conversion of data precision will be added later - * and are currently not supported, sorry. - * Exception: The transcoding part (jpegtran) supports all settings in a - * single instance, since it operates on the level of DCT coefficients and - * not sample values. The DCT coefficients are of the same type (16 bits) - * in all cases (see below). - */ - -#define BITS_IN_JSAMPLE 8 /* use 8, 9, 10, 11, or 12 */ - - -/* - * Maximum number of components (color channels) allowed in JPEG image. - * To meet the letter of the JPEG spec, set this to 255. However, darn - * few applications need more than 4 channels (maybe 5 for CMYK + alpha - * mask). We recommend 10 as a reasonable compromise; use 4 if you are - * really short on memory. (Each allowed component costs a hundred or so - * bytes of storage, whether actually used in an image or not.) - */ - -#define MAX_COMPONENTS 10 /* maximum number of image components */ - - -/* - * Basic data types. - * You may need to change these if you have a machine with unusual data - * type sizes; for example, "char" not 8 bits, "short" not 16 bits, - * or "long" not 32 bits. We don't care whether "int" is 16 or 32 bits, - * but it had better be at least 16. - */ - -/* Representation of a single sample (pixel element value). - * We frequently allocate large arrays of these, so it's important to keep - * them small. But if you have memory to burn and access to char or short - * arrays is very slow on your hardware, you might want to change these. - */ - -#if BITS_IN_JSAMPLE == 8 -/* JSAMPLE should be the smallest type that will hold the values 0..255. - * You can use a signed char by having GETJSAMPLE mask it with 0xFF. - */ - -#ifdef HAVE_UNSIGNED_CHAR - -typedef unsigned char JSAMPLE; -#define GETJSAMPLE(value) ((int) (value)) - -#else /* not HAVE_UNSIGNED_CHAR */ - -typedef char JSAMPLE; -#ifdef CHAR_IS_UNSIGNED -#define GETJSAMPLE(value) ((int) (value)) -#else -#define GETJSAMPLE(value) ((int) (value) & 0xFF) -#endif /* CHAR_IS_UNSIGNED */ - -#endif /* HAVE_UNSIGNED_CHAR */ - -#define MAXJSAMPLE 255 -#define CENTERJSAMPLE 128 - -#endif /* BITS_IN_JSAMPLE == 8 */ - - -#if BITS_IN_JSAMPLE == 9 -/* JSAMPLE should be the smallest type that will hold the values 0..511. - * On nearly all machines "short" will do nicely. - */ - -typedef short JSAMPLE; -#define GETJSAMPLE(value) ((int) (value)) - -#define MAXJSAMPLE 511 -#define CENTERJSAMPLE 256 - -#endif /* BITS_IN_JSAMPLE == 9 */ - - -#if BITS_IN_JSAMPLE == 10 -/* JSAMPLE should be the smallest type that will hold the values 0..1023. - * On nearly all machines "short" will do nicely. - */ - -typedef short JSAMPLE; -#define GETJSAMPLE(value) ((int) (value)) - -#define MAXJSAMPLE 1023 -#define CENTERJSAMPLE 512 - -#endif /* BITS_IN_JSAMPLE == 10 */ - - -#if BITS_IN_JSAMPLE == 11 -/* JSAMPLE should be the smallest type that will hold the values 0..2047. - * On nearly all machines "short" will do nicely. - */ - -typedef short JSAMPLE; -#define GETJSAMPLE(value) ((int) (value)) - -#define MAXJSAMPLE 2047 -#define CENTERJSAMPLE 1024 - -#endif /* BITS_IN_JSAMPLE == 11 */ - - -#if BITS_IN_JSAMPLE == 12 -/* JSAMPLE should be the smallest type that will hold the values 0..4095. - * On nearly all machines "short" will do nicely. - */ - -typedef short JSAMPLE; -#define GETJSAMPLE(value) ((int) (value)) - -#define MAXJSAMPLE 4095 -#define CENTERJSAMPLE 2048 - -#endif /* BITS_IN_JSAMPLE == 12 */ - - -/* Representation of a DCT frequency coefficient. - * This should be a signed value of at least 16 bits; "short" is usually OK. - * Again, we allocate large arrays of these, but you can change to int - * if you have memory to burn and "short" is really slow. - */ - -typedef short JCOEF; - - -/* Compressed datastreams are represented as arrays of JOCTET. - * These must be EXACTLY 8 bits wide, at least once they are written to - * external storage. Note that when using the stdio data source/destination - * managers, this is also the data type passed to fread/fwrite. - */ - -#ifdef HAVE_UNSIGNED_CHAR - -typedef unsigned char JOCTET; -#define GETJOCTET(value) (value) - -#else /* not HAVE_UNSIGNED_CHAR */ - -typedef char JOCTET; -#ifdef CHAR_IS_UNSIGNED -#define GETJOCTET(value) (value) -#else -#define GETJOCTET(value) ((value) & 0xFF) -#endif /* CHAR_IS_UNSIGNED */ - -#endif /* HAVE_UNSIGNED_CHAR */ - - -/* These typedefs are used for various table entries and so forth. - * They must be at least as wide as specified; but making them too big - * won't cost a huge amount of memory, so we don't provide special - * extraction code like we did for JSAMPLE. (In other words, these - * typedefs live at a different point on the speed/space tradeoff curve.) - */ - -/* UINT8 must hold at least the values 0..255. */ - -#ifdef HAVE_UNSIGNED_CHAR -typedef unsigned char UINT8; -#else /* not HAVE_UNSIGNED_CHAR */ -#ifdef CHAR_IS_UNSIGNED -typedef char UINT8; -#else /* not CHAR_IS_UNSIGNED */ -typedef short UINT8; -#endif /* CHAR_IS_UNSIGNED */ -#endif /* HAVE_UNSIGNED_CHAR */ - -/* UINT16 must hold at least the values 0..65535. */ - -#ifdef HAVE_UNSIGNED_SHORT -typedef unsigned short UINT16; -#else /* not HAVE_UNSIGNED_SHORT */ -typedef unsigned int UINT16; -#endif /* HAVE_UNSIGNED_SHORT */ - -/* INT16 must hold at least the values -32768..32767. */ - -#ifndef XMD_H /* X11/xmd.h correctly defines INT16 */ -typedef short INT16; -#endif - -/* INT32 must hold at least signed 32-bit values. */ - -#ifndef XMD_H /* X11/xmd.h correctly defines INT32 */ -#ifndef _BASETSD_H_ /* Microsoft defines it in basetsd.h */ -#ifndef _BASETSD_H /* MinGW is slightly different */ -#ifndef QGLOBAL_H /* Qt defines it in qglobal.h */ -typedef long INT32; -#endif -#endif -#endif -#endif - -/* Datatype used for image dimensions. The JPEG standard only supports - * images up to 64K*64K due to 16-bit fields in SOF markers. Therefore - * "unsigned int" is sufficient on all machines. However, if you need to - * handle larger images and you don't mind deviating from the spec, you - * can change this datatype. - */ - -typedef unsigned int JDIMENSION; - -#define JPEG_MAX_DIMENSION 65500L /* a tad under 64K to prevent overflows */ - - -/* These macros are used in all function definitions and extern declarations. - * You could modify them if you need to change function linkage conventions; - * in particular, you'll need to do that to make the library a Windows DLL. - * Another application is to make all functions global for use with debuggers - * or code profilers that require it. - */ - -/* a function called through method pointers: */ -#define METHODDEF(type) static type -/* a function used only in its module: */ -#define LOCAL(type) static type -#if defined(_WIN32) && defined(DLL_EXPORT) -/* a function referenced thru EXTERNs: */ -#define GLOBAL(type) __declspec(dllexport) type -/* a reference to a GLOBAL function: */ -#define EXTERN(type) extern __declspec(dllexport) type -#else -/* a function referenced thru EXTERNs: */ -#define GLOBAL(type) type -/* a reference to a GLOBAL function: */ -#define EXTERN(type) extern type -#endif - - -/* This macro is used to declare a "method", that is, a function pointer. - * We want to supply prototype parameters if the compiler can cope. - * Note that the arglist parameter must be parenthesized! - * Again, you can customize this if you need special linkage keywords. - */ - -#ifdef HAVE_PROTOTYPES -#define JMETHOD(type,methodname,arglist) type (*methodname) arglist -#else -#define JMETHOD(type,methodname,arglist) type (*methodname) () -#endif - - -/* The noreturn type identifier is used to declare functions - * which cannot return. - * Compilers can thus create more optimized code and perform - * better checks for warnings and errors. - * Static analyzer tools can make improved inferences about - * execution paths and are prevented from giving false alerts. - * - * Unfortunately, the proposed specifications of corresponding - * extensions in the Dec 2011 ISO C standard revision (C11), - * GCC, MSVC, etc. are not viable. - * Thus we introduce a user defined type to declare noreturn - * functions at least for clarity. A proper compiler would - * have a suitable noreturn type to match in place of void. - */ - -#ifndef HAVE_NORETURN_T -typedef void noreturn_t; -#endif - - -/* Here is the pseudo-keyword for declaring pointers that must be "far" - * on 80x86 machines. Most of the specialized coding for 80x86 is handled - * by just saying "FAR *" where such a pointer is needed. In a few places - * explicit coding is needed; see uses of the NEED_FAR_POINTERS symbol. - */ - -#ifndef FAR -#ifdef NEED_FAR_POINTERS -#define FAR far -#else -#define FAR -#endif -#endif - - -/* - * On a few systems, type boolean and/or its values FALSE, TRUE may appear - * in standard header files. Or you may have conflicts with application- - * specific header files that you want to include together with these files. - * Defining HAVE_BOOLEAN before including jpeglib.h should make it work. - */ - -#ifndef HAVE_BOOLEAN -#if defined FALSE || defined TRUE || defined QGLOBAL_H -/* Qt3 defines FALSE and TRUE as "const" variables in qglobal.h */ -typedef int boolean; -#ifndef FALSE /* in case these macros already exist */ -#define FALSE 0 /* values of boolean */ -#endif -#ifndef TRUE -#define TRUE 1 -#endif -#else -typedef enum { FALSE = 0, TRUE = 1 } boolean; -#endif -#endif - - -/* - * The remaining options affect code selection within the JPEG library, - * but they don't need to be visible to most applications using the library. - * To minimize application namespace pollution, the symbols won't be - * defined unless JPEG_INTERNALS or JPEG_INTERNAL_OPTIONS has been defined. - */ - -#ifdef JPEG_INTERNALS -#define JPEG_INTERNAL_OPTIONS -#endif - -#ifdef JPEG_INTERNAL_OPTIONS - - -/* - * These defines indicate whether to include various optional functions. - * Undefining some of these symbols will produce a smaller but less capable - * library. Note that you can leave certain source files out of the - * compilation/linking process if you've #undef'd the corresponding symbols. - * (You may HAVE to do that if your compiler doesn't like null source files.) - */ - -/* Capability options common to encoder and decoder: */ - -#define DCT_ISLOW_SUPPORTED /* slow but accurate integer algorithm */ -#define DCT_IFAST_SUPPORTED /* faster, less accurate integer method */ -#define DCT_FLOAT_SUPPORTED /* floating-point: accurate, fast on fast HW */ - -/* Encoder capability options: */ - -#define C_ARITH_CODING_SUPPORTED /* Arithmetic coding back end? */ -#define C_MULTISCAN_FILES_SUPPORTED /* Multiple-scan JPEG files? */ -#define C_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires MULTISCAN)*/ -#define DCT_SCALING_SUPPORTED /* Input rescaling via DCT? (Requires DCT_ISLOW)*/ -#define ENTROPY_OPT_SUPPORTED /* Optimization of entropy coding parms? */ -/* Note: if you selected more than 8-bit data precision, it is dangerous to - * turn off ENTROPY_OPT_SUPPORTED. The standard Huffman tables are only - * good for 8-bit precision, so arithmetic coding is recommended for higher - * precision. The Huffman encoder normally uses entropy optimization to - * compute usable tables for higher precision. Otherwise, you'll have to - * supply different default Huffman tables. - * The exact same statements apply for progressive JPEG: the default tables - * don't work for progressive mode. (This may get fixed, however.) - */ -#define INPUT_SMOOTHING_SUPPORTED /* Input image smoothing option? */ - -/* Decoder capability options: */ - -#define D_ARITH_CODING_SUPPORTED /* Arithmetic coding back end? */ -#define D_MULTISCAN_FILES_SUPPORTED /* Multiple-scan JPEG files? */ -#define D_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires MULTISCAN)*/ -#define IDCT_SCALING_SUPPORTED /* Output rescaling via IDCT? (Requires DCT_ISLOW)*/ -#define SAVE_MARKERS_SUPPORTED /* jpeg_save_markers() needed? */ -#define BLOCK_SMOOTHING_SUPPORTED /* Block smoothing? (Progressive only) */ -#undef UPSAMPLE_SCALING_SUPPORTED /* Output rescaling at upsample stage? */ -#define UPSAMPLE_MERGING_SUPPORTED /* Fast path for sloppy upsampling? */ -#define QUANT_1PASS_SUPPORTED /* 1-pass color quantization? */ -#define QUANT_2PASS_SUPPORTED /* 2-pass color quantization? */ - -/* more capability options later, no doubt */ - - -/* - * Ordering of RGB data in scanlines passed to or from the application. - * If your application wants to deal with data in the order B,G,R, just - * change these macros. You can also deal with formats such as R,G,B,X - * (one extra byte per pixel) by changing RGB_PIXELSIZE. Note that changing - * the offsets will also change the order in which colormap data is organized. - * RESTRICTIONS: - * 1. The sample applications cjpeg,djpeg do NOT support modified RGB formats. - * 2. The color quantizer modules will not behave desirably if RGB_PIXELSIZE - * is not 3 (they don't understand about dummy color components!). So you - * can't use color quantization if you change that value. - */ - -#define RGB_RED 0 /* Offset of Red in an RGB scanline element */ -#define RGB_GREEN 1 /* Offset of Green */ -#define RGB_BLUE 2 /* Offset of Blue */ -#define RGB_PIXELSIZE 3 /* JSAMPLEs per RGB scanline element */ - - -/* Definitions for speed-related optimizations. */ - - -/* If your compiler supports inline functions, define INLINE - * as the inline keyword; otherwise define it as empty. - */ - -#ifndef INLINE -#ifdef __GNUC__ /* for instance, GNU C knows about inline */ -#define INLINE __inline__ -#endif -#ifndef INLINE -#define INLINE /* default is to define it as empty */ -#endif -#endif - - -/* On some machines (notably 68000 series) "int" is 32 bits, but multiplying - * two 16-bit shorts is faster than multiplying two ints. Define MULTIPLIER - * as short on such a machine. MULTIPLIER must be at least 16 bits wide. - */ - -#ifndef MULTIPLIER -#define MULTIPLIER int /* type for fastest integer multiply */ -#endif - - -/* FAST_FLOAT should be either float or double, whichever is done faster - * by your compiler. (Note that this type is only used in the floating point - * DCT routines, so it only matters if you've defined DCT_FLOAT_SUPPORTED.) - * Typically, float is faster in ANSI C compilers, while double is faster in - * pre-ANSI compilers (because they insist on converting to double anyway). - * The code below therefore chooses float if we have ANSI-style prototypes. - */ - -#ifndef FAST_FLOAT -#ifdef HAVE_PROTOTYPES -#define FAST_FLOAT float -#else -#define FAST_FLOAT double -#endif -#endif - -#endif /* JPEG_INTERNAL_OPTIONS */ diff --git a/external/jpeg-9c/rdgif.c b/external/jpeg-9c/rdgif.c deleted file mode 100644 index b27c1675..00000000 --- a/external/jpeg-9c/rdgif.c +++ /dev/null @@ -1,38 +0,0 @@ -/* - * rdgif.c - * - * Copyright (C) 1991-1997, Thomas G. Lane. - * This file is part of the Independent JPEG Group's software. - * For conditions of distribution and use, see the accompanying README file. - * - * This file contains routines to read input images in GIF format. - * - ***************************************************************************** - * NOTE: to avoid entanglements with Unisys' patent on LZW compression, * - * the ability to read GIF files has been removed from the IJG distribution. * - * Sorry about that. * - ***************************************************************************** - * - * We are required to state that - * "The Graphics Interchange Format(c) is the Copyright property of - * CompuServe Incorporated. GIF(sm) is a Service Mark property of - * CompuServe Incorporated." - */ - -#include "cdjpeg.h" /* Common decls for cjpeg/djpeg applications */ - -#ifdef GIF_SUPPORTED - -/* - * The module selection routine for GIF format input. - */ - -GLOBAL(cjpeg_source_ptr) -jinit_read_gif (j_compress_ptr cinfo) -{ - fprintf(stderr, "GIF input is unsupported for legal reasons. Sorry.\n"); - exit(EXIT_FAILURE); - return NULL; /* keep compiler happy */ -} - -#endif /* GIF_SUPPORTED */ diff --git a/external/jpeg-9c/testimgp.jpg b/external/jpeg-9c/testimgp.jpg deleted file mode 100644 index ca6acad1936a5d2223ed82f913e61ff15ec448c8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d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I!&b>GMUm#}QGx_Itxc3m+j88$ z@OD>34*SISMNS(D!){|lZW0kqHD{MpqYG{>yYoJX!T;s+IL?%nVYgr3WejZ0HLrVA zvWq#_wq=b>`+a9he_dZ8?RkE@0l|7Hy6WbqOeVy#)?k`JBOX!k=FO;Utje&=*gDxS z)1xnp35Pu9{bkvf^x3Qi=e-#P@jSK zbGtGm@tCM_qu+U?mYLOm=pk$kYWh4DS@!KB`XjU2M!i0u;{!aM_AIP)FRDSpFnUnm zA1`ytF1{64P9Xezi_hkUc}!G3Ll|pK)I+^08R*E{9>$ua@}z3F-3qXo9MU?3C@D78 zB`+ag2~i?3pj?s{+sB5hl&NBJ-8wugzY#>~n?XiQG}KNxUCcAVUy&aXp##FsN8L2B z0pAgj|CX6)v`XMy{X1}>I|nSdP}o4blHJV0|F#(sY7D7Oe*ItuF(@xw&9~{)&9S0l z49w7x67+*vf8p~Tw5>pgulQ>&4jJHP#|CDM`0DTd;+%oh8N}W46`PxtjPee76~J9DA9UwyblfpauCtd`VG6>MZS>B`7X*YpNHR4OX-;qF!- zj=efy>O)l)k#RwN7Kt>+gnS*k1uuLj*T!(=nV(5!sSk_ly0crL8_R%Daa6SCYu)^u zUqxl`IHNNe9W^=|%?=ig@QQ7kx!*Ja;=3n##rTw47aoZlIrEhE zfOsDUla}df*ntft1Gtuye%+{+69vQ+Ju=F0d=j-;gZaY|)Z=ssh(actso;A|y;%lM zjH6Dt&qi*)F{WUlbf@3Y#839NYoM1o^JT!E+TMA3ggxLcQOOv3!!J7I2}O#PL?xOv zu=@9B0lw#9L9RQ}tap9zs+6;h)?uoq$~u0xwW?^QgoNJv*LBWY#{rfT0W{6EO49qr zZnG^z}sz1pX-r(?BWjMKI_t3Rhy-xk}eCA^fTg<2f}>~Eb$6S UV9?7uwJ&e$(diH-;xA|a1JT3r4gdfE diff --git a/external/jpeg-9c.patch b/external/jpeg-9d.patch similarity index 99% rename from external/jpeg-9c.patch rename to external/jpeg-9d.patch index c04e8def..d1ede5b9 100644 --- a/external/jpeg-9c.patch +++ b/external/jpeg-9d.patch @@ -1,6 +1,6 @@ -diff -u /dev/null jpeg-9c/Android.mk +diff -u /dev/null jpeg-9d/Android.mk --- /dev/null -+++ jpeg-9c/Android.mk ++++ jpeg-9d/Android.mk @@ -0,0 +1,37 @@ +LOCAL_PATH:= $(call my-dir) +include $(CLEAR_VARS) @@ -39,9 +39,9 @@ diff -u /dev/null jpeg-9c/Android.mk +LOCAL_MODULE:= jpeg + +include $(BUILD_STATIC_LIBRARY) -diff -u /dev/null jpeg-9c/jconfig.h +diff -u /dev/null jpeg-9d/jconfig.h --- /dev/null -+++ jpeg-9c/jconfig.h ++++ jpeg-9d/jconfig.h @@ -0,0 +1,156 @@ +/* android jconfig.h */ +/* @@ -199,9 +199,9 @@ diff -u /dev/null jpeg-9c/jconfig.h + + +#endif /* JPEG_CJPEG_DJPEG */ -diff -u /dev/null jpeg-9c/jidctfst.S +diff -u /dev/null jpeg-9d/jidctfst.S --- /dev/null -+++ jpeg-9c/jidctfst.S ++++ jpeg-9d/jidctfst.S @@ -0,0 +1,476 @@ +/* + * Copyright (C) 2008 The Android Open Source Project @@ -679,9 +679,9 @@ diff -u /dev/null jpeg-9c/jidctfst.S + b HLoopTail + + .endfunc -diff -u /dev/null jpeg-9c/jmem-android.c +diff -u /dev/null jpeg-9d/jmem-android.c --- /dev/null -+++ jpeg-9c/jmem-android.c ++++ jpeg-9d/jmem-android.c @@ -0,0 +1,187 @@ +/* + * Copyright (C) 2007-2008 The Android Open Source Project diff --git a/external/jpeg-9c/Android.mk b/external/jpeg-9d/Android.mk similarity index 100% rename from external/jpeg-9c/Android.mk rename to external/jpeg-9d/Android.mk diff --git a/external/jpeg-9c/Makefile.am b/external/jpeg-9d/Makefile.am similarity index 85% rename from external/jpeg-9c/Makefile.am rename to external/jpeg-9d/Makefile.am index be582603..c477a445 100644 --- a/external/jpeg-9c/Makefile.am +++ b/external/jpeg-9d/Makefile.am @@ -39,9 +39,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt @@ -58,8 +58,8 @@ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in # Test support files -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg # libtool libraries to build lib_LTLIBRARIES = libjpeg.la @@ -108,8 +108,8 @@ pkgconfigdir = $(libdir)/pkgconfig nodist_pkgconfig_DATA = libjpeg.pc # Files to be cleaned -CLEANFILES = testout.ppm testout.bmp testout.jpg testoutp.ppm testoutp.jpg \ - testoutt.jpg +CLEANFILES = testout.ppm testout.gif testout.bmp testout.jpg testoutp.ppm \ + testoutp.jpg testoutt.jpg # Install jconfig.h install-data-local: @@ -124,13 +124,15 @@ uninstall-local: test: check-local check-local: rm -f testout* - ./djpeg -dct int -ppm -outfile testout.ppm $(srcdir)/testorig.jpg - ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp $(srcdir)/testorig.jpg - ./cjpeg -dct int -outfile testout.jpg $(srcdir)/testimg.ppm + ./djpeg -dct int -ppm -outfile testout.ppm $(srcdir)/testorig.jpg + ./djpeg -dct int -gif -outfile testout.gif $(srcdir)/testorig.jpg + ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp $(srcdir)/testorig.jpg + ./cjpeg -dct int -outfile testout.jpg $(srcdir)/testimg.ppm ./djpeg -dct int -ppm -outfile testoutp.ppm $(srcdir)/testprog.jpg ./cjpeg -dct int -progressive -opt -outfile testoutp.jpg $(srcdir)/testimg.ppm ./jpegtran -outfile testoutt.jpg $(srcdir)/testprog.jpg cmp $(srcdir)/testimg.ppm testout.ppm + cmp $(srcdir)/testimg.gif testout.gif cmp $(srcdir)/testimg.bmp testout.bmp cmp $(srcdir)/testimg.jpg testout.jpg cmp $(srcdir)/testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/Makefile.in b/external/jpeg-9d/Makefile.in similarity index 78% rename from external/jpeg-9c/Makefile.in rename to external/jpeg-9d/Makefile.in index fef89e0b..ab8e384b 100644 --- a/external/jpeg-9c/Makefile.in +++ b/external/jpeg-9d/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.15.1 from Makefile.am. +# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2017 Free Software Foundation, Inc. +# Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -114,6 +114,10 @@ mkinstalldirs = $(install_sh) -d CONFIG_HEADER = jconfig.h CONFIG_CLEAN_FILES = libjpeg.pc CONFIG_CLEAN_VPATH_FILES = +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libdir)" \ + "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(pkgconfigdir)" \ + "$(DESTDIR)$(includedir)" +PROGRAMS = $(bin_PROGRAMS) am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -141,9 +145,6 @@ am__uninstall_files_from_dir = { \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } -am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" \ - "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(pkgconfigdir)" \ - "$(DESTDIR)$(includedir)" LTLIBRARIES = $(lib_LTLIBRARIES) libjpeg_la_LIBADD = am__objects_1 = jaricom.lo jcapimin.lo jcapistd.lo jcarith.lo \ @@ -165,7 +166,6 @@ am__v_lt_1 = libjpeg_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(libjpeg_la_LDFLAGS) $(LDFLAGS) -o $@ -PROGRAMS = $(bin_PROGRAMS) am_cjpeg_OBJECTS = cjpeg.$(OBJEXT) rdppm.$(OBJEXT) rdgif.$(OBJEXT) \ rdtarga.$(OBJEXT) rdrle.$(OBJEXT) rdbmp.$(OBJEXT) \ rdswitch.$(OBJEXT) cdjpeg.$(OBJEXT) @@ -200,7 +200,40 @@ am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles +am__maybe_remake_depfiles = depfiles +am__depfiles_remade = ./$(DEPDIR)/@MEMORYMGR@.Plo \ + ./$(DEPDIR)/cdjpeg.Po ./$(DEPDIR)/cjpeg.Po \ + ./$(DEPDIR)/djpeg.Po ./$(DEPDIR)/jaricom.Plo \ + ./$(DEPDIR)/jcapimin.Plo ./$(DEPDIR)/jcapistd.Plo \ + ./$(DEPDIR)/jcarith.Plo ./$(DEPDIR)/jccoefct.Plo \ + ./$(DEPDIR)/jccolor.Plo ./$(DEPDIR)/jcdctmgr.Plo \ + ./$(DEPDIR)/jchuff.Plo ./$(DEPDIR)/jcinit.Plo \ + ./$(DEPDIR)/jcmainct.Plo ./$(DEPDIR)/jcmarker.Plo \ + ./$(DEPDIR)/jcmaster.Plo ./$(DEPDIR)/jcomapi.Plo \ + ./$(DEPDIR)/jcparam.Plo ./$(DEPDIR)/jcprepct.Plo \ + ./$(DEPDIR)/jcsample.Plo ./$(DEPDIR)/jctrans.Plo \ + ./$(DEPDIR)/jdapimin.Plo ./$(DEPDIR)/jdapistd.Plo \ + ./$(DEPDIR)/jdarith.Plo ./$(DEPDIR)/jdatadst.Plo \ + ./$(DEPDIR)/jdatasrc.Plo ./$(DEPDIR)/jdcoefct.Plo \ + ./$(DEPDIR)/jdcolor.Plo ./$(DEPDIR)/jddctmgr.Plo \ + ./$(DEPDIR)/jdhuff.Plo ./$(DEPDIR)/jdinput.Plo \ + ./$(DEPDIR)/jdmainct.Plo ./$(DEPDIR)/jdmarker.Plo \ + ./$(DEPDIR)/jdmaster.Plo ./$(DEPDIR)/jdmerge.Plo \ + ./$(DEPDIR)/jdpostct.Plo ./$(DEPDIR)/jdsample.Plo \ + ./$(DEPDIR)/jdtrans.Plo ./$(DEPDIR)/jerror.Plo \ + ./$(DEPDIR)/jfdctflt.Plo ./$(DEPDIR)/jfdctfst.Plo \ + ./$(DEPDIR)/jfdctint.Plo ./$(DEPDIR)/jidctflt.Plo \ + ./$(DEPDIR)/jidctfst.Plo ./$(DEPDIR)/jidctint.Plo \ + ./$(DEPDIR)/jmemmgr.Plo ./$(DEPDIR)/jpegtran.Po \ + ./$(DEPDIR)/jquant1.Plo ./$(DEPDIR)/jquant2.Plo \ + ./$(DEPDIR)/jutils.Plo ./$(DEPDIR)/rdbmp.Po \ + ./$(DEPDIR)/rdcolmap.Po ./$(DEPDIR)/rdgif.Po \ + ./$(DEPDIR)/rdjpgcom.Po ./$(DEPDIR)/rdppm.Po \ + ./$(DEPDIR)/rdrle.Po ./$(DEPDIR)/rdswitch.Po \ + ./$(DEPDIR)/rdtarga.Po ./$(DEPDIR)/transupp.Po \ + ./$(DEPDIR)/wrbmp.Po ./$(DEPDIR)/wrgif.Po \ + ./$(DEPDIR)/wrjpgcom.Po ./$(DEPDIR)/wrppm.Po \ + ./$(DEPDIR)/wrrle.Po ./$(DEPDIR)/wrtarga.Po am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) @@ -287,6 +320,8 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ JPEG_LIB_VERSION = @JPEG_LIB_VERSION@ +JPEG_LIB_VERSION_MAJOR = @JPEG_LIB_VERSION_MAJOR@ +JPEG_LIB_VERSION_MINOR = @JPEG_LIB_VERSION_MINOR@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ @@ -415,9 +450,9 @@ MKFILES = configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt @@ -437,8 +472,8 @@ CONFIGUREFILES = config.guess config.sub install-sh ltmain.sh depcomp \ OTHERFILES = jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in # Test support files -TESTFILES = testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES = testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg # libtool libraries to build @@ -484,8 +519,8 @@ pkgconfigdir = $(libdir)/pkgconfig nodist_pkgconfig_DATA = libjpeg.pc # Files to be cleaned -CLEANFILES = testout.ppm testout.bmp testout.jpg testoutp.ppm testoutp.jpg \ - testoutt.jpg +CLEANFILES = testout.ppm testout.gif testout.bmp testout.jpg testoutp.ppm \ + testoutp.jpg testoutt.jpg all: jconfig.h $(MAKE) $(AM_MAKEFLAGS) all-am @@ -513,8 +548,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) @@ -542,44 +577,6 @@ distclean-hdr: -rm -f jconfig.h stamp-h1 libjpeg.pc: $(top_builddir)/config.status $(srcdir)/libjpeg.pc.in cd $(top_builddir) && $(SHELL) ./config.status $@ - -install-libLTLIBRARIES: $(lib_LTLIBRARIES) - @$(NORMAL_INSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ - } - -uninstall-libLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ - done - -clean-libLTLIBRARIES: - -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) - @list='$(lib_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -libjpeg.la: $(libjpeg_la_OBJECTS) $(libjpeg_la_DEPENDENCIES) $(EXTRA_libjpeg_la_DEPENDENCIES) - $(AM_V_CCLD)$(libjpeg_la_LINK) -rpath $(libdir) $(libjpeg_la_OBJECTS) $(libjpeg_la_LIBADD) $(LIBS) install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ @@ -630,6 +627,44 @@ clean-binPROGRAMS: echo " rm -f" $$list; \ rm -f $$list +install-libLTLIBRARIES: $(lib_LTLIBRARIES) + @$(NORMAL_INSTALL) + @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ + list2=; for p in $$list; do \ + if test -f $$p; then \ + list2="$$list2 $$p"; \ + else :; fi; \ + done; \ + test -z "$$list2" || { \ + echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ + } + +uninstall-libLTLIBRARIES: + @$(NORMAL_UNINSTALL) + @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ + for p in $$list; do \ + $(am__strip_dir) \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ + done + +clean-libLTLIBRARIES: + -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) + @list='$(lib_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libjpeg.la: $(libjpeg_la_OBJECTS) $(libjpeg_la_DEPENDENCIES) $(EXTRA_libjpeg_la_DEPENDENCIES) + $(AM_V_CCLD)$(libjpeg_la_LINK) -rpath $(libdir) $(libjpeg_la_OBJECTS) $(libjpeg_la_LIBADD) $(LIBS) + cjpeg$(EXEEXT): $(cjpeg_OBJECTS) $(cjpeg_DEPENDENCIES) $(EXTRA_cjpeg_DEPENDENCIES) @rm -f cjpeg$(EXEEXT) $(AM_V_CCLD)$(LINK) $(cjpeg_OBJECTS) $(cjpeg_LDADD) $(LIBS) @@ -656,71 +691,77 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/@MEMORYMGR@.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cdjpeg.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cjpeg.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/djpeg.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jaricom.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcapimin.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcapistd.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcarith.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jccoefct.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jccolor.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcdctmgr.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jchuff.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcinit.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcmainct.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcmarker.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcmaster.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcomapi.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcparam.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcprepct.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcsample.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jctrans.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdapimin.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdapistd.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdarith.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdatadst.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdatasrc.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdcoefct.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdcolor.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jddctmgr.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdhuff.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdinput.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdmainct.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdmarker.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdmaster.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdmerge.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdpostct.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdsample.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdtrans.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jerror.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jfdctflt.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jfdctfst.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jfdctint.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jidctflt.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jidctfst.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jidctint.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jmemmgr.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jpegtran.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jquant1.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jquant2.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jutils.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdbmp.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdcolmap.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdgif.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdjpgcom.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdppm.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdrle.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdswitch.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdtarga.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/transupp.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrbmp.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrgif.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrjpgcom.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrppm.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrrle.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrtarga.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/@MEMORYMGR@.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cdjpeg.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cjpeg.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/djpeg.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jaricom.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcapimin.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcapistd.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcarith.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jccoefct.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jccolor.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcdctmgr.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jchuff.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcinit.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcmainct.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcmarker.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcmaster.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcomapi.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcparam.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcprepct.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jcsample.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jctrans.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdapimin.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdapistd.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdarith.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdatadst.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdatasrc.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdcoefct.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdcolor.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jddctmgr.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdhuff.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdinput.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdmainct.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdmarker.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdmaster.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdmerge.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdpostct.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdsample.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jdtrans.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jerror.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jfdctflt.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jfdctfst.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jfdctint.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jidctflt.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jidctfst.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jidctint.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jmemmgr.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jpegtran.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jquant1.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jquant2.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/jutils.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdbmp.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdcolmap.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdgif.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdjpgcom.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdppm.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdrle.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdswitch.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rdtarga.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/transupp.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrbmp.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrgif.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrjpgcom.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrppm.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrrle.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrtarga.Po@am__quote@ # am--include-marker + +$(am__depfiles_remade): + @$(MKDIR_P) $(@D) + @echo '# dummy' >$@-t && $(am__mv) $@-t $@ + +am--depfiles: $(am__depfiles_remade) .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @@ -898,12 +939,12 @@ distclean-tags: check-am: all-am $(MAKE) $(AM_MAKEFLAGS) check-local check: check-am -all-am: Makefile $(LTLIBRARIES) $(PROGRAMS) $(MANS) $(DATA) $(HEADERS) \ +all-am: Makefile $(PROGRAMS) $(LTLIBRARIES) $(MANS) $(DATA) $(HEADERS) \ jconfig.h install-binPROGRAMS: install-libLTLIBRARIES installdirs: - for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(includedir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libdir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(includedir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am @@ -944,7 +985,71 @@ clean-am: clean-binPROGRAMS clean-generic clean-libLTLIBRARIES \ distclean: distclean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf ./$(DEPDIR) + -rm -f ./$(DEPDIR)/@MEMORYMGR@.Plo + -rm -f ./$(DEPDIR)/cdjpeg.Po + -rm -f ./$(DEPDIR)/cjpeg.Po + -rm -f ./$(DEPDIR)/djpeg.Po + -rm -f ./$(DEPDIR)/jaricom.Plo + -rm -f ./$(DEPDIR)/jcapimin.Plo + -rm -f ./$(DEPDIR)/jcapistd.Plo + -rm -f ./$(DEPDIR)/jcarith.Plo + -rm -f ./$(DEPDIR)/jccoefct.Plo + -rm -f ./$(DEPDIR)/jccolor.Plo + -rm -f ./$(DEPDIR)/jcdctmgr.Plo + -rm -f ./$(DEPDIR)/jchuff.Plo + -rm -f ./$(DEPDIR)/jcinit.Plo + -rm -f ./$(DEPDIR)/jcmainct.Plo + -rm -f ./$(DEPDIR)/jcmarker.Plo + -rm -f ./$(DEPDIR)/jcmaster.Plo + -rm -f ./$(DEPDIR)/jcomapi.Plo + -rm -f ./$(DEPDIR)/jcparam.Plo + -rm -f ./$(DEPDIR)/jcprepct.Plo + -rm -f ./$(DEPDIR)/jcsample.Plo + -rm -f ./$(DEPDIR)/jctrans.Plo + -rm -f ./$(DEPDIR)/jdapimin.Plo + -rm -f ./$(DEPDIR)/jdapistd.Plo + -rm -f ./$(DEPDIR)/jdarith.Plo + -rm -f ./$(DEPDIR)/jdatadst.Plo + -rm -f ./$(DEPDIR)/jdatasrc.Plo + -rm -f ./$(DEPDIR)/jdcoefct.Plo + -rm -f ./$(DEPDIR)/jdcolor.Plo + -rm -f ./$(DEPDIR)/jddctmgr.Plo + -rm -f ./$(DEPDIR)/jdhuff.Plo + -rm -f ./$(DEPDIR)/jdinput.Plo + -rm -f ./$(DEPDIR)/jdmainct.Plo + -rm -f ./$(DEPDIR)/jdmarker.Plo + -rm -f ./$(DEPDIR)/jdmaster.Plo + -rm -f ./$(DEPDIR)/jdmerge.Plo + -rm -f ./$(DEPDIR)/jdpostct.Plo + -rm -f ./$(DEPDIR)/jdsample.Plo + -rm -f ./$(DEPDIR)/jdtrans.Plo + -rm -f ./$(DEPDIR)/jerror.Plo + -rm -f ./$(DEPDIR)/jfdctflt.Plo + -rm -f ./$(DEPDIR)/jfdctfst.Plo + -rm -f ./$(DEPDIR)/jfdctint.Plo + -rm -f ./$(DEPDIR)/jidctflt.Plo + -rm -f ./$(DEPDIR)/jidctfst.Plo + -rm -f ./$(DEPDIR)/jidctint.Plo + -rm -f ./$(DEPDIR)/jmemmgr.Plo + -rm -f ./$(DEPDIR)/jpegtran.Po + -rm -f ./$(DEPDIR)/jquant1.Plo + -rm -f ./$(DEPDIR)/jquant2.Plo + -rm -f ./$(DEPDIR)/jutils.Plo + -rm -f ./$(DEPDIR)/rdbmp.Po + -rm -f ./$(DEPDIR)/rdcolmap.Po + -rm -f ./$(DEPDIR)/rdgif.Po + -rm -f ./$(DEPDIR)/rdjpgcom.Po + -rm -f ./$(DEPDIR)/rdppm.Po + -rm -f ./$(DEPDIR)/rdrle.Po + -rm -f ./$(DEPDIR)/rdswitch.Po + -rm -f ./$(DEPDIR)/rdtarga.Po + -rm -f ./$(DEPDIR)/transupp.Po + -rm -f ./$(DEPDIR)/wrbmp.Po + -rm -f ./$(DEPDIR)/wrgif.Po + -rm -f ./$(DEPDIR)/wrjpgcom.Po + -rm -f ./$(DEPDIR)/wrppm.Po + -rm -f ./$(DEPDIR)/wrrle.Po + -rm -f ./$(DEPDIR)/wrtarga.Po -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-hdr distclean-libtool distclean-tags @@ -993,7 +1098,71 @@ installcheck-am: maintainer-clean: maintainer-clean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache - -rm -rf ./$(DEPDIR) + -rm -f ./$(DEPDIR)/@MEMORYMGR@.Plo + -rm -f ./$(DEPDIR)/cdjpeg.Po + -rm -f ./$(DEPDIR)/cjpeg.Po + -rm -f ./$(DEPDIR)/djpeg.Po + -rm -f ./$(DEPDIR)/jaricom.Plo + -rm -f ./$(DEPDIR)/jcapimin.Plo + -rm -f ./$(DEPDIR)/jcapistd.Plo + -rm -f ./$(DEPDIR)/jcarith.Plo + -rm -f ./$(DEPDIR)/jccoefct.Plo + -rm -f ./$(DEPDIR)/jccolor.Plo + -rm -f ./$(DEPDIR)/jcdctmgr.Plo + -rm -f ./$(DEPDIR)/jchuff.Plo + -rm -f ./$(DEPDIR)/jcinit.Plo + -rm -f ./$(DEPDIR)/jcmainct.Plo + -rm -f ./$(DEPDIR)/jcmarker.Plo + -rm -f ./$(DEPDIR)/jcmaster.Plo + -rm -f ./$(DEPDIR)/jcomapi.Plo + -rm -f ./$(DEPDIR)/jcparam.Plo + -rm -f ./$(DEPDIR)/jcprepct.Plo + -rm -f ./$(DEPDIR)/jcsample.Plo + -rm -f ./$(DEPDIR)/jctrans.Plo + -rm -f ./$(DEPDIR)/jdapimin.Plo + -rm -f ./$(DEPDIR)/jdapistd.Plo + -rm -f ./$(DEPDIR)/jdarith.Plo + -rm -f ./$(DEPDIR)/jdatadst.Plo + -rm -f ./$(DEPDIR)/jdatasrc.Plo + -rm -f ./$(DEPDIR)/jdcoefct.Plo + -rm -f ./$(DEPDIR)/jdcolor.Plo + -rm -f ./$(DEPDIR)/jddctmgr.Plo + -rm -f ./$(DEPDIR)/jdhuff.Plo + -rm -f ./$(DEPDIR)/jdinput.Plo + -rm -f ./$(DEPDIR)/jdmainct.Plo + -rm -f ./$(DEPDIR)/jdmarker.Plo + -rm -f ./$(DEPDIR)/jdmaster.Plo + -rm -f ./$(DEPDIR)/jdmerge.Plo + -rm -f ./$(DEPDIR)/jdpostct.Plo + -rm -f ./$(DEPDIR)/jdsample.Plo + -rm -f ./$(DEPDIR)/jdtrans.Plo + -rm -f ./$(DEPDIR)/jerror.Plo + -rm -f ./$(DEPDIR)/jfdctflt.Plo + -rm -f ./$(DEPDIR)/jfdctfst.Plo + -rm -f ./$(DEPDIR)/jfdctint.Plo + -rm -f ./$(DEPDIR)/jidctflt.Plo + -rm -f ./$(DEPDIR)/jidctfst.Plo + -rm -f ./$(DEPDIR)/jidctint.Plo + -rm -f ./$(DEPDIR)/jmemmgr.Plo + -rm -f ./$(DEPDIR)/jpegtran.Po + -rm -f ./$(DEPDIR)/jquant1.Plo + -rm -f ./$(DEPDIR)/jquant2.Plo + -rm -f ./$(DEPDIR)/jutils.Plo + -rm -f ./$(DEPDIR)/rdbmp.Po + -rm -f ./$(DEPDIR)/rdcolmap.Po + -rm -f ./$(DEPDIR)/rdgif.Po + -rm -f ./$(DEPDIR)/rdjpgcom.Po + -rm -f ./$(DEPDIR)/rdppm.Po + -rm -f ./$(DEPDIR)/rdrle.Po + -rm -f ./$(DEPDIR)/rdswitch.Po + -rm -f ./$(DEPDIR)/rdtarga.Po + -rm -f ./$(DEPDIR)/transupp.Po + -rm -f ./$(DEPDIR)/wrbmp.Po + -rm -f ./$(DEPDIR)/wrgif.Po + -rm -f ./$(DEPDIR)/wrjpgcom.Po + -rm -f ./$(DEPDIR)/wrppm.Po + -rm -f ./$(DEPDIR)/wrrle.Po + -rm -f ./$(DEPDIR)/wrtarga.Po -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic @@ -1018,19 +1187,20 @@ uninstall-man: uninstall-man1 .MAKE: all check-am install-am install-strip -.PHONY: CTAGS GTAGS TAGS all all-am am--refresh check check-am \ - check-local clean clean-binPROGRAMS clean-cscope clean-generic \ - clean-libLTLIBRARIES clean-libtool cscope cscopelist-am ctags \ - ctags-am distclean distclean-compile distclean-generic \ - distclean-hdr distclean-libtool distclean-tags dvi dvi-am html \ - html-am info info-am install install-am install-binPROGRAMS \ - install-data install-data-am install-data-local install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-includeHEADERS install-info \ - install-info-am install-libLTLIBRARIES install-man \ - install-man1 install-nodist_pkgconfigDATA install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ +.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles am--refresh check \ + check-am check-local clean clean-binPROGRAMS clean-cscope \ + clean-generic clean-libLTLIBRARIES clean-libtool cscope \ + cscopelist-am ctags ctags-am distclean distclean-compile \ + distclean-generic distclean-hdr distclean-libtool \ + distclean-tags dvi dvi-am html html-am info info-am install \ + install-am install-binPROGRAMS install-data install-data-am \ + install-data-local install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am \ + install-includeHEADERS install-info install-info-am \ + install-libLTLIBRARIES install-man install-man1 \ + install-nodist_pkgconfigDATA install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ @@ -1054,13 +1224,15 @@ uninstall-local: test: check-local check-local: rm -f testout* - ./djpeg -dct int -ppm -outfile testout.ppm $(srcdir)/testorig.jpg - ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp $(srcdir)/testorig.jpg - ./cjpeg -dct int -outfile testout.jpg $(srcdir)/testimg.ppm + ./djpeg -dct int -ppm -outfile testout.ppm $(srcdir)/testorig.jpg + ./djpeg -dct int -gif -outfile testout.gif $(srcdir)/testorig.jpg + ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp $(srcdir)/testorig.jpg + ./cjpeg -dct int -outfile testout.jpg $(srcdir)/testimg.ppm ./djpeg -dct int -ppm -outfile testoutp.ppm $(srcdir)/testprog.jpg ./cjpeg -dct int -progressive -opt -outfile testoutp.jpg $(srcdir)/testimg.ppm ./jpegtran -outfile testoutt.jpg $(srcdir)/testprog.jpg cmp $(srcdir)/testimg.ppm testout.ppm + cmp $(srcdir)/testimg.gif testout.gif cmp $(srcdir)/testimg.bmp testout.bmp cmp $(srcdir)/testimg.jpg testout.jpg cmp $(srcdir)/testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/README b/external/jpeg-9d/README similarity index 96% rename from external/jpeg-9c/README rename to external/jpeg-9d/README index 56cdb600..13b245c5 100644 --- a/external/jpeg-9c/README +++ b/external/jpeg-9d/README @@ -1,7 +1,7 @@ The Independent JPEG Group's JPEG software ========================================== -README for release 9c of 14-Jan-2018 +README for release 9d of 12-Jan-2020 ==================================== This distribution contains the ninth public release of the Independent JPEG @@ -10,8 +10,8 @@ to use it for any purpose, subject to the conditions under LEGAL ISSUES, below. This software is the work of Tom Lane, Guido Vollbeding, Philip Gladstone, Bill Allombert, Jim Boucher, Lee Crocker, Bob Friesenhahn, Ben Jackson, -Julian Minguillon, Luis Ortiz, George Phillips, Davide Rossi, Ge' Weijers, -and other members of the Independent JPEG Group. +John Korejwa, Julian Minguillon, Luis Ortiz, George Phillips, Davide Rossi, +Ge' Weijers, and other members of the Independent JPEG Group. IJG is not affiliated with the ISO/IEC JTC1/SC29/WG1 standards committee (previously known as JPEG, together with ITU-T SG16). @@ -115,7 +115,7 @@ with respect to this software, its quality, accuracy, merchantability, or fitness for a particular purpose. This software is provided "AS IS", and you, its user, assume the entire risk as to its quality and accuracy. -This software is copyright (C) 1991-2018, Thomas G. Lane, Guido Vollbeding. +This software is copyright (C) 1991-2020, Thomas G. Lane, Guido Vollbeding. All Rights Reserved except as specified below. Permission is hereby granted to use, copy, modify, and distribute this @@ -152,13 +152,6 @@ The same holds for its supporting scripts (config.guess, config.sub, ltmain.sh). Another support script, install-sh, is copyright by X Consortium but is also freely distributable. -The IJG distribution formerly included code to read and write GIF files. -To avoid entanglement with the Unisys LZW patent (now expired), GIF reading -support has been removed altogether, and the GIF writer has been simplified -to produce "uncompressed GIFs". This technique does not use the LZW -algorithm; the resulting GIF files are larger than usual, but are readable -by all standard GIF decoders. - REFERENCES ========== @@ -246,8 +239,8 @@ ARCHIVE LOCATIONS The "official" archive site for this software is www.ijg.org. The most recent released version can always be found there in directory "files". This particular version will be archived as -http://www.ijg.org/files/jpegsrc.v9c.tar.gz, and in Windows-compatible -"zip" archive format as http://www.ijg.org/files/jpegsr9c.zip. +http://www.ijg.org/files/jpegsrc.v9d.tar.gz, and in Windows-compatible +"zip" archive format as http://www.ijg.org/files/jpegsr9d.zip. The JPEG FAQ (Frequently Asked Questions) article is a source of some general information about JPEG. diff --git a/external/jpeg-9c/aclocal.m4 b/external/jpeg-9d/aclocal.m4 similarity index 98% rename from external/jpeg-9c/aclocal.m4 rename to external/jpeg-9d/aclocal.m4 index dde9b178..f77f2904 100644 --- a/external/jpeg-9c/aclocal.m4 +++ b/external/jpeg-9d/aclocal.m4 @@ -1,6 +1,6 @@ -# generated automatically by aclocal 1.15.1 -*- Autoconf -*- +# generated automatically by aclocal 1.16.1 -*- Autoconf -*- -# Copyright (C) 1996-2017 Free Software Foundation, Inc. +# Copyright (C) 1996-2018 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9049,7 +9049,7 @@ m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) -# Copyright (C) 2002-2017 Free Software Foundation, Inc. +# Copyright (C) 2002-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9061,10 +9061,10 @@ m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.15' +[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.15.1], [], +m4_if([$1], [1.16.1], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) @@ -9080,12 +9080,12 @@ 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.15.1])dnl +[AM_AUTOMAKE_VERSION([1.16.1])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) -# Copyright (C) 2011-2017 Free Software Foundation, Inc. +# Copyright (C) 2011-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9147,7 +9147,7 @@ AC_SUBST([AR])dnl # AM_AUX_DIR_EXPAND -*- Autoconf -*- -# Copyright (C) 2001-2017 Free Software Foundation, Inc. +# Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9199,7 +9199,7 @@ am_aux_dir=`cd "$ac_aux_dir" && pwd` # AM_CONDITIONAL -*- Autoconf -*- -# Copyright (C) 1997-2017 Free Software Foundation, Inc. +# Copyright (C) 1997-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9230,7 +9230,7 @@ AC_CONFIG_COMMANDS_PRE( Usually this means the macro was only invoked conditionally.]]) fi])]) -# Copyright (C) 1999-2017 Free Software Foundation, Inc. +# Copyright (C) 1999-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9421,13 +9421,12 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl # Generate code to set up dependency tracking. -*- Autoconf -*- -# Copyright (C) 1999-2017 Free Software Foundation, Inc. +# Copyright (C) 1999-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. - # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], @@ -9435,49 +9434,41 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac + # TODO: see whether this extra hack can be removed once we start + # requiring Autoconf 2.70 or later. + AS_CASE([$CONFIG_FILES], + [*\'*], [eval set x "$CONFIG_FILES"], + [*], [set x $CONFIG_FILES]) shift - for mf + # Used to flag and report bootstrapping failures. + am_rc=0 + for am_mf do # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named 'Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line + am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile which includes + # dependency-tracking related rules and includes. + # Grep'ing the whole file directly is not great: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`AS_DIRNAME("$mf")` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running 'make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "$am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`AS_DIRNAME(["$file"])` - AS_MKDIR_P([$dirpart/$fdir]) - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done + sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ + || continue + am_dirpart=`AS_DIRNAME(["$am_mf"])` + am_filepart=`AS_BASENAME(["$am_mf"])` + AM_RUN_LOG([cd "$am_dirpart" \ + && sed -e '/# am--include-marker/d' "$am_filepart" \ + | $MAKE -f - am--depfiles]) || am_rc=$? 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 + '--disable-dependency-tracking' option to at least be able to build + the package (albeit without support for automatic dependency tracking).]) + fi + AS_UNSET([am_dirpart]) + AS_UNSET([am_filepart]) + AS_UNSET([am_mf]) + AS_UNSET([am_rc]) + rm -f conftest-deps.mk } ])# _AM_OUTPUT_DEPENDENCY_COMMANDS @@ -9486,18 +9477,17 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # -# This code is only required when automatic dependency tracking -# is enabled. FIXME. This creates each '.P' file that we will -# need in order to bootstrap the dependency handling code. +# This code is only required when automatic dependency tracking is enabled. +# This creates each '.Po' and '.Plo' makefile fragment that we'll need in +# order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], - [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) -]) + [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])]) # Do all the work for Automake. -*- Autoconf -*- -# Copyright (C) 1996-2017 Free Software Foundation, Inc. +# Copyright (C) 1996-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9584,8 +9574,8 @@ AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl AC_REQUIRE([AC_PROG_MKDIR_P])dnl # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: -# -# +# +# AC_SUBST([mkdir_p], ['$(MKDIR_P)']) # We need awk for the "check" target (and possibly the TAP driver). The # system "awk" is bad on some platforms. @@ -9652,7 +9642,7 @@ END Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: . +that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM @@ -9694,7 +9684,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-2017 Free Software Foundation, Inc. +# Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9715,7 +9705,7 @@ if test x"${install_sh+set}" != xset; then fi AC_SUBST([install_sh])]) -# Copyright (C) 2003-2017 Free Software Foundation, Inc. +# Copyright (C) 2003-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9737,7 +9727,7 @@ AC_SUBST([am__leading_dot])]) # Add --enable-maintainer-mode option to configure. -*- Autoconf -*- # From Jim Meyering -# Copyright (C) 1996-2017 Free Software Foundation, Inc. +# Copyright (C) 1996-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9772,7 +9762,7 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) # Check to see how 'make' treats includes. -*- Autoconf -*- -# Copyright (C) 2001-2017 Free Software Foundation, Inc. +# Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9780,49 +9770,42 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) # AM_MAKE_INCLUDE() # ----------------- -# Check to see how make treats includes. +# Check whether make has an 'include' directive that can support all +# the idioms we need for our automatic dependency tracking code. AC_DEFUN([AM_MAKE_INCLUDE], -[am_make=${MAKE-make} -cat > confinc << 'END' +[AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive]) +cat > confinc.mk << 'END' am__doit: - @echo this is the am__doit target + @echo this is the am__doit target >confinc.out .PHONY: am__doit END -# If we don't find an include directive, just comment out the code. -AC_MSG_CHECKING([for style of include used by $am_make]) am__include="#" am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from 'make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD - ;; - esac -fi -AC_SUBST([am__include]) -AC_SUBST([am__quote]) -AC_MSG_RESULT([$_am_result]) -rm -f confinc confmf -]) +# BSD make does it like this. +echo '.include "confinc.mk" # ignored' > confmf.BSD +# Other make implementations (GNU, Solaris 10, AIX) do it like this. +echo 'include confinc.mk # ignored' > confmf.GNU +_am_result=no +for s in GNU BSD; do + AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out]) + AS_CASE([$?:`cat confinc.out 2>/dev/null`], + ['0:this is the am__doit target'], + [AS_CASE([$s], + [BSD], [am__include='.include' am__quote='"'], + [am__include='include' am__quote=''])]) + if test "$am__include" != "#"; then + _am_result="yes ($s style)" + break + fi +done +rm -f confinc.* confmf.* +AC_MSG_RESULT([${_am_result}]) +AC_SUBST([am__include])]) +AC_SUBST([am__quote])]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- -# Copyright (C) 1997-2017 Free Software Foundation, Inc. +# Copyright (C) 1997-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9861,7 +9844,7 @@ fi # Helper functions for option handling. -*- Autoconf -*- -# Copyright (C) 2001-2017 Free Software Foundation, Inc. +# Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9890,7 +9873,7 @@ AC_DEFUN([_AM_SET_OPTIONS], AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -# Copyright (C) 1999-2017 Free Software Foundation, Inc. +# Copyright (C) 1999-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9937,7 +9920,7 @@ AC_LANG_POP([C])]) # For backward compatibility. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) -# Copyright (C) 2001-2017 Free Software Foundation, Inc. +# Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -9956,7 +9939,7 @@ AC_DEFUN([AM_RUN_LOG], # Check to make sure that the build environment is sane. -*- Autoconf -*- -# Copyright (C) 1996-2017 Free Software Foundation, Inc. +# Copyright (C) 1996-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -10037,7 +10020,7 @@ AC_CONFIG_COMMANDS_PRE( rm -f conftest.file ]) -# Copyright (C) 2009-2017 Free Software Foundation, Inc. +# Copyright (C) 2009-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -10097,7 +10080,7 @@ AC_SUBST([AM_BACKSLASH])dnl _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl ]) -# Copyright (C) 2001-2017 Free Software Foundation, Inc. +# Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -10125,7 +10108,7 @@ fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) -# Copyright (C) 2006-2017 Free Software Foundation, Inc. +# Copyright (C) 2006-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -10144,7 +10127,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- -# Copyright (C) 2004-2017 Free Software Foundation, Inc. +# Copyright (C) 2004-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, diff --git a/external/jpeg-9c/ar-lib b/external/jpeg-9d/ar-lib similarity index 97% rename from external/jpeg-9c/ar-lib rename to external/jpeg-9d/ar-lib index 05094d34..0baa4f60 100755 --- a/external/jpeg-9c/ar-lib +++ b/external/jpeg-9d/ar-lib @@ -4,7 +4,7 @@ me=ar-lib scriptversion=2012-03-01.08; # UTC -# Copyright (C) 2010-2017 Free Software Foundation, Inc. +# Copyright (C) 2010-2018 Free Software Foundation, Inc. # Written by Peter Rosin . # # This program is free software; you can redistribute it and/or modify @@ -18,7 +18,7 @@ scriptversion=2012-03-01.08; # UTC # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a diff --git a/external/jpeg-9c/cderror.h b/external/jpeg-9d/cderror.h similarity index 100% rename from external/jpeg-9c/cderror.h rename to external/jpeg-9d/cderror.h diff --git a/external/jpeg-9c/cdjpeg.c b/external/jpeg-9d/cdjpeg.c similarity index 100% rename from external/jpeg-9c/cdjpeg.c rename to external/jpeg-9d/cdjpeg.c diff --git a/external/jpeg-9c/cdjpeg.h b/external/jpeg-9d/cdjpeg.h similarity index 98% rename from external/jpeg-9c/cdjpeg.h rename to external/jpeg-9d/cdjpeg.h index ed024ac3..524ab3a2 100644 --- a/external/jpeg-9c/cdjpeg.h +++ b/external/jpeg-9d/cdjpeg.h @@ -2,6 +2,7 @@ * cdjpeg.h * * Copyright (C) 1994-1997, Thomas G. Lane. + * Modified 2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -121,7 +122,8 @@ EXTERN(cjpeg_source_ptr) jinit_read_bmp JPP((j_compress_ptr cinfo)); EXTERN(djpeg_dest_ptr) jinit_write_bmp JPP((j_decompress_ptr cinfo, boolean is_os2)); EXTERN(cjpeg_source_ptr) jinit_read_gif JPP((j_compress_ptr cinfo)); -EXTERN(djpeg_dest_ptr) jinit_write_gif JPP((j_decompress_ptr cinfo)); +EXTERN(djpeg_dest_ptr) jinit_write_gif JPP((j_decompress_ptr cinfo, + boolean is_lzw)); EXTERN(cjpeg_source_ptr) jinit_read_ppm JPP((j_compress_ptr cinfo)); EXTERN(djpeg_dest_ptr) jinit_write_ppm JPP((j_decompress_ptr cinfo)); EXTERN(cjpeg_source_ptr) jinit_read_rle JPP((j_compress_ptr cinfo)); diff --git a/external/jpeg-9c/change.log b/external/jpeg-9d/change.log similarity index 91% rename from external/jpeg-9c/change.log rename to external/jpeg-9d/change.log index 674a558a..ed8ec6af 100644 --- a/external/jpeg-9c/change.log +++ b/external/jpeg-9d/change.log @@ -1,6 +1,55 @@ CHANGE LOG for Independent JPEG Group's JPEG software +Version 9d 12-Jan-2020 +----------------------- + +Optimize the optimal Huffman code table generation to produce +slightly smaller files. Thank to John Korejwa for suggestion. +Note: Requires rebuild of testimgp.jpg. + +Decoding Huffman: Use default tables if tables are not defined. +Thank to Simone Azzalin for report (Motion JPEG), +and to Martin Strunz for hint. + +Add sanity check in optimal Huffman code table generation. +Thank to Adam Farley for suggestion. + +rdtarga.c: use read_byte(), with EOF check, instead of getc() +in read_*_pixel(). +Thank to Chijin Zhou for cjpeg potential vulnerability report. + +jmemnobs.c: respect the max_memory_to_use setting in +jpeg_mem_available() computation. Thank to Sheng Shu and +Dongdong She for djpeg potential vulnerability report. + +jdarith.c, jdhuff.c: avoid left shift of negative value +compiler warning in decode_mcu_AC_refine(). +Thank to Indu Bhagat for suggestion. + +Add x64 (64-bit) platform support, avoid compiler warnings. +Thank to Jonathan Potter, Feiyun Wang, and Sheng Shu for suggestion. + +Adjust libjpeg version specification for pkg-config file. +Thank to Chen Chen for suggestion. + +Restore GIF read and write support from libjpeg version 6a. +Thank to Wolfgang Werner (W.W.) Heinz for suggestion. + +Improve consistency in raw (downsampled) image data processing mode. +Thank to Zhongyuan Zhou for hint. + +Avoid out of bounds array read (AC derived table pointers) +in start pass in jdhuff.c. Thank to Peng Li for report. + +Improve code sanity (jdhuff.c). +Thank to Reza Mirzazade farkhani for reports. + +Add jpegtran -drop option; add options to the crop extension and wipe +to fill the extra area with content from the source image region, +instead of gray out. + + Version 9c 14-Jan-2018 ----------------------- diff --git a/external/jpeg-9c/cjpeg.1 b/external/jpeg-9d/cjpeg.1 similarity index 97% rename from external/jpeg-9c/cjpeg.1 rename to external/jpeg-9d/cjpeg.1 index 7d685be5..355d3405 100644 --- a/external/jpeg-9c/cjpeg.1 +++ b/external/jpeg-9d/cjpeg.1 @@ -1,4 +1,4 @@ -.TH CJPEG 1 "26 July 2015" +.TH CJPEG 1 "28 April 2019" .SH NAME cjpeg \- compress an image file to a JPEG file .SH SYNOPSIS @@ -16,8 +16,9 @@ cjpeg \- compress an image file to a JPEG file compresses the named image file, or the standard input if no file is named, and produces a JPEG/JFIF file on the standard output. The currently supported input file formats are: PPM (PBMPLUS color -format), PGM (PBMPLUS grayscale format), BMP, Targa, and RLE (Utah Raster -Toolkit format). (RLE is supported only if the URT library is available.) +format), PGM (PBMPLUS grayscale format), BMP, GIF, Targa, and RLE (Utah Raster +Toolkit format). (RLE is supported only if the URT library is available, +which it isn't on most non-Unix systems.) .SH OPTIONS All switch names may be abbreviated; for example, .B \-grayscale @@ -42,10 +43,10 @@ Scale quantization tables to adjust image quality. Quality is 0 (worst) to .TP .B \-grayscale Create monochrome JPEG file from color input. Be sure to use this switch when -compressing a grayscale BMP file, because +compressing a grayscale BMP or GIF file, because .B cjpeg -isn't bright enough to notice whether a BMP file uses only shades of gray. -By saying +isn't bright enough to notice whether a BMP or GIF file uses only shades of +gray. By saying .BR \-grayscale , you'll get a smaller JPEG file that takes less time to process. .TP @@ -375,10 +376,6 @@ Communications of the ACM, April 1991 (vol. 34, no. 4), pp. 30-44. .SH AUTHOR Independent JPEG Group .SH BUGS -GIF input files are no longer supported, to avoid the Unisys LZW patent -(now expired). -(Conversion of GIF files to JPEG is usually a bad idea anyway.) -.PP Not all variants of BMP and Targa file formats are supported. .PP The diff --git a/external/jpeg-9c/cjpeg.c b/external/jpeg-9d/cjpeg.c similarity index 100% rename from external/jpeg-9c/cjpeg.c rename to external/jpeg-9d/cjpeg.c diff --git a/external/jpeg-9c/ckconfig.c b/external/jpeg-9d/ckconfig.c similarity index 100% rename from external/jpeg-9c/ckconfig.c rename to external/jpeg-9d/ckconfig.c diff --git a/external/jpeg-9c/coderules.txt b/external/jpeg-9d/coderules.txt similarity index 100% rename from external/jpeg-9c/coderules.txt rename to external/jpeg-9d/coderules.txt diff --git a/external/jpeg-9c/compile b/external/jpeg-9d/compile similarity index 97% rename from external/jpeg-9c/compile rename to external/jpeg-9d/compile index 2ab71e4e..99e50524 100755 --- a/external/jpeg-9c/compile +++ b/external/jpeg-9d/compile @@ -1,9 +1,9 @@ #! /bin/sh # Wrapper for compilers which do not understand '-c -o'. -scriptversion=2016-01-11.22; # UTC +scriptversion=2018-03-07.03; # UTC -# Copyright (C) 1999-2017 Free Software Foundation, Inc. +# Copyright (C) 1999-2018 Free Software Foundation, Inc. # Written by Tom Tromey . # # This program is free software; you can redistribute it and/or modify @@ -17,7 +17,7 @@ scriptversion=2016-01-11.22; # UTC # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -340,7 +340,7 @@ exit $ret # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/external/jpeg-9c/config.guess b/external/jpeg-9d/config.guess similarity index 72% rename from external/jpeg-9c/config.guess rename to external/jpeg-9d/config.guess index 2193702b..256083a7 100755 --- a/external/jpeg-9c/config.guess +++ b/external/jpeg-9d/config.guess @@ -1,8 +1,8 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2017 Free Software Foundation, Inc. +# Copyright 1992-2018 Free Software Foundation, Inc. -timestamp='2017-05-27' +timestamp='2018-03-08' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -15,7 +15,7 @@ timestamp='2017-05-27' # General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, see . +# along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -27,7 +27,7 @@ timestamp='2017-05-27' # Originally written by Per Bothner; maintained since 2000 by Ben Elliston. # # You can get the latest version of this script from: -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess +# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess # # Please send patches to . @@ -39,7 +39,7 @@ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. -Operation modes: +Options: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit @@ -50,7 +50,7 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2017 Free Software Foundation, Inc. +Copyright 1992-2018 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -107,9 +107,9 @@ trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; dummy=$tmp/dummy ; tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; case $CC_FOR_BUILD,$HOST_CC,$CC in - ,,) echo "int x;" > $dummy.c ; + ,,) echo "int x;" > "$dummy.c" ; for c in cc gcc c89 c99 ; do - if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then + if ($c -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then CC_FOR_BUILD="$c"; break ; fi ; done ; @@ -132,14 +132,14 @@ UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown -case "${UNAME_SYSTEM}" in +case "$UNAME_SYSTEM" in Linux|GNU|GNU/*) # If the system lacks a compiler, then just pick glibc. # We could probably try harder. LIBC=gnu - eval $set_cc_for_build - cat <<-EOF > $dummy.c + eval "$set_cc_for_build" + cat <<-EOF > "$dummy.c" #include #if defined(__UCLIBC__) LIBC=uclibc @@ -149,13 +149,20 @@ Linux|GNU|GNU/*) LIBC=gnu #endif EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` + eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`" + + # If ldd exists, use it to detect musl libc. + if command -v ldd >/dev/null && \ + ldd --version 2>&1 | grep -q ^musl + then + LIBC=musl + fi ;; esac # Note: order is significant - the case branches are not exclusive. -case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in +case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, @@ -169,30 +176,30 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # portion of the name. We always set it to "unknown". sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ - /sbin/$sysctl 2>/dev/null || \ - /usr/sbin/$sysctl 2>/dev/null || \ + "/sbin/$sysctl" 2>/dev/null || \ + "/usr/sbin/$sysctl" 2>/dev/null || \ echo unknown)` - case "${UNAME_MACHINE_ARCH}" in + case "$UNAME_MACHINE_ARCH" in armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; earmv*) - arch=`echo ${UNAME_MACHINE_ARCH} | sed -e 's,^e\(armv[0-9]\).*$,\1,'` - endian=`echo ${UNAME_MACHINE_ARCH} | sed -ne 's,^.*\(eb\)$,\1,p'` - machine=${arch}${endian}-unknown + arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'` + endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'` + machine="${arch}${endian}"-unknown ;; - *) machine=${UNAME_MACHINE_ARCH}-unknown ;; + *) machine="$UNAME_MACHINE_ARCH"-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently (or will in the future) and ABI. - case "${UNAME_MACHINE_ARCH}" in + case "$UNAME_MACHINE_ARCH" in earm*) os=netbsdelf ;; arm*|i386|m68k|ns32k|sh3*|sparc|vax) - eval $set_cc_for_build + eval "$set_cc_for_build" if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ELF__ then @@ -208,10 +215,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in ;; esac # Determine ABI tags. - case "${UNAME_MACHINE_ARCH}" in + case "$UNAME_MACHINE_ARCH" in earm*) expr='s/^earmv[0-9]/-eabi/;s/eb$//' - abi=`echo ${UNAME_MACHINE_ARCH} | sed -e "$expr"` + abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` ;; esac # The OS release @@ -219,46 +226,55 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. - case "${UNAME_VERSION}" in + case "$UNAME_VERSION" in Debian*) release='-gnu' ;; *) - release=`echo ${UNAME_RELEASE} | sed -e 's/[-_].*//' | cut -d. -f1,2` + release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. - echo "${machine}-${os}${release}${abi}" + echo "$machine-${os}${release}${abi}" exit ;; *:Bitrig:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` - echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} + echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE" exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` - echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} + echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE" exit ;; *:LibertyBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` - echo ${UNAME_MACHINE_ARCH}-unknown-libertybsd${UNAME_RELEASE} + echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE" + exit ;; + *:MidnightBSD:*:*) + echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE" exit ;; *:ekkoBSD:*:*) - echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} + echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE" exit ;; *:SolidBSD:*:*) - echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} + echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE" exit ;; macppc:MirBSD:*:*) - echo powerpc-unknown-mirbsd${UNAME_RELEASE} + echo powerpc-unknown-mirbsd"$UNAME_RELEASE" exit ;; *:MirBSD:*:*) - echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} + echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE" exit ;; *:Sortix:*:*) - echo ${UNAME_MACHINE}-unknown-sortix + echo "$UNAME_MACHINE"-unknown-sortix + exit ;; + *:Redox:*:*) + echo "$UNAME_MACHINE"-unknown-redox exit ;; + mips:OSF1:*.*) + echo mips-dec-osf1 + exit ;; alpha:OSF1:*:*) case $UNAME_RELEASE in *4.0) @@ -310,28 +326,19 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. - echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` + echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`" # Reset EXIT trap before exiting to avoid spurious non-zero exit code. exitcode=$? trap '' 0 exit $exitcode ;; - Alpha\ *:Windows_NT*:*) - # How do we know it's Interix rather than the generic POSIX subsystem? - # Should we change UNAME_MACHINE based on the output of uname instead - # of the specific Alpha model? - echo alpha-pc-interix - exit ;; - 21064:Windows_NT:50:3) - echo alpha-dec-winnt3.5 - exit ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit ;; *:[Aa]miga[Oo][Ss]:*:*) - echo ${UNAME_MACHINE}-unknown-amigaos + echo "$UNAME_MACHINE"-unknown-amigaos exit ;; *:[Mm]orph[Oo][Ss]:*:*) - echo ${UNAME_MACHINE}-unknown-morphos + echo "$UNAME_MACHINE"-unknown-morphos exit ;; *:OS/390:*:*) echo i370-ibm-openedition @@ -343,7 +350,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) - echo arm-acorn-riscix${UNAME_RELEASE} + echo arm-acorn-riscix"$UNAME_RELEASE" exit ;; arm*:riscos:*:*|arm*:RISCOS:*:*) echo arm-unknown-riscos @@ -370,19 +377,19 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in sparc) echo sparc-icl-nx7; exit ;; esac ;; s390x:SunOS:*:*) - echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" exit ;; sun4H:SunOS:5.*:*) - echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) - echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" exit ;; i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) - echo i386-pc-auroraux${UNAME_RELEASE} + echo i386-pc-auroraux"$UNAME_RELEASE" exit ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) - eval $set_cc_for_build + eval "$set_cc_for_build" SUN_ARCH=i386 # If there is a compiler, see if it is configured for 64-bit objects. # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. @@ -395,13 +402,13 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in SUN_ARCH=x86_64 fi fi - echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + echo "$SUN_ARCH"-pc-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. - echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" exit ;; sun4*:SunOS:*:*) case "`/usr/bin/arch -k`" in @@ -410,25 +417,25 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. - echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` + echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`" exit ;; sun3*:SunOS:*:*) - echo m68k-sun-sunos${UNAME_RELEASE} + echo m68k-sun-sunos"$UNAME_RELEASE" exit ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` - test "x${UNAME_RELEASE}" = x && UNAME_RELEASE=3 + test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) - echo m68k-sun-sunos${UNAME_RELEASE} + echo m68k-sun-sunos"$UNAME_RELEASE" ;; sun4) - echo sparc-sun-sunos${UNAME_RELEASE} + echo sparc-sun-sunos"$UNAME_RELEASE" ;; esac exit ;; aushp:SunOS:*:*) - echo sparc-auspex-sunos${UNAME_RELEASE} + echo sparc-auspex-sunos"$UNAME_RELEASE" exit ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not @@ -439,44 +446,44 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint"$UNAME_RELEASE" exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint"$UNAME_RELEASE" exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint"$UNAME_RELEASE" exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint${UNAME_RELEASE} + echo m68k-milan-mint"$UNAME_RELEASE" exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint${UNAME_RELEASE} + echo m68k-hades-mint"$UNAME_RELEASE" exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint${UNAME_RELEASE} + echo m68k-unknown-mint"$UNAME_RELEASE" exit ;; m68k:machten:*:*) - echo m68k-apple-machten${UNAME_RELEASE} + echo m68k-apple-machten"$UNAME_RELEASE" exit ;; powerpc:machten:*:*) - echo powerpc-apple-machten${UNAME_RELEASE} + echo powerpc-apple-machten"$UNAME_RELEASE" exit ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit ;; RISC*:ULTRIX:*:*) - echo mips-dec-ultrix${UNAME_RELEASE} + echo mips-dec-ultrix"$UNAME_RELEASE" exit ;; VAX*:ULTRIX*:*:*) - echo vax-dec-ultrix${UNAME_RELEASE} + echo vax-dec-ultrix"$UNAME_RELEASE" exit ;; 2020:CLIX:*:* | 2430:CLIX:*:*) - echo clipper-intergraph-clix${UNAME_RELEASE} + echo clipper-intergraph-clix"$UNAME_RELEASE" exit ;; mips:*:*:UMIPS | mips:*:*:RISCos) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + eval "$set_cc_for_build" + sed 's/^ //' << EOF > "$dummy.c" #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { @@ -485,23 +492,23 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) - printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); + printf ("mips-mips-riscos%ssysv\\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) - printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); + printf ("mips-mips-riscos%ssvr4\\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) - printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); + printf ("mips-mips-riscos%sbsd\\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF - $CC_FOR_BUILD -o $dummy $dummy.c && - dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && - SYSTEM_NAME=`$dummy $dummyarg` && + $CC_FOR_BUILD -o "$dummy" "$dummy.c" && + dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` && + SYSTEM_NAME=`"$dummy" "$dummyarg"` && { echo "$SYSTEM_NAME"; exit; } - echo mips-mips-riscos${UNAME_RELEASE} + echo mips-mips-riscos"$UNAME_RELEASE" exit ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax @@ -527,17 +534,17 @@ EOF AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` - if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] + if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ] then - if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ - [ ${TARGET_BINARY_INTERFACE}x = x ] + if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \ + [ "$TARGET_BINARY_INTERFACE"x = x ] then - echo m88k-dg-dgux${UNAME_RELEASE} + echo m88k-dg-dgux"$UNAME_RELEASE" else - echo m88k-dg-dguxbcs${UNAME_RELEASE} + echo m88k-dg-dguxbcs"$UNAME_RELEASE" fi else - echo i586-dg-dgux${UNAME_RELEASE} + echo i586-dg-dgux"$UNAME_RELEASE" fi exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) @@ -554,7 +561,7 @@ EOF echo m68k-tektronix-bsd exit ;; *:IRIX*:*:*) - echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` + echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`" exit ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id @@ -566,14 +573,14 @@ EOF if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} + IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" fi - echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} + echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV" exit ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + eval "$set_cc_for_build" + sed 's/^ //' << EOF > "$dummy.c" #include main() @@ -584,7 +591,7 @@ EOF exit(0); } EOF - if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` + if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` then echo "$SYSTEM_NAME" else @@ -598,7 +605,7 @@ EOF exit ;; *:AIX:*:[4567]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` - if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then + if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc @@ -607,18 +614,18 @@ EOF IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` else - IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} + IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" fi - echo ${IBM_ARCH}-ibm-aix${IBM_REV} + echo "$IBM_ARCH"-ibm-aix"$IBM_REV" exit ;; *:AIX:*:*) echo rs6000-ibm-aix exit ;; - ibmrt:4.4BSD:*|romp-ibm:BSD:*) + ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) echo romp-ibm-bsd4.4 exit ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and - echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to + echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to exit ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx @@ -633,28 +640,28 @@ EOF echo m68k-hp-bsd4.4 exit ;; 9000/[34678]??:HP-UX:*:*) - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` - case "${UNAME_MACHINE}" in - 9000/31? ) HP_ARCH=m68000 ;; - 9000/[34]?? ) HP_ARCH=m68k ;; + HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` + case "$UNAME_MACHINE" in + 9000/31?) HP_ARCH=m68000 ;; + 9000/[34]??) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "${sc_cpu_version}" in + case "$sc_cpu_version" in 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 - case "${sc_kernel_bits}" in + case "$sc_kernel_bits" in 32) HP_ARCH=hppa2.0n ;; 64) HP_ARCH=hppa2.0w ;; '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20 esac ;; esac fi - if [ "${HP_ARCH}" = "" ]; then - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + if [ "$HP_ARCH" = "" ]; then + eval "$set_cc_for_build" + sed 's/^ //' << EOF > "$dummy.c" #define _HPUX_SOURCE #include @@ -687,13 +694,13 @@ EOF exit (0); } EOF - (CCOPTS="" $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` + (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac - if [ ${HP_ARCH} = hppa2.0w ] + if [ "$HP_ARCH" = hppa2.0w ] then - eval $set_cc_for_build + eval "$set_cc_for_build" # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler @@ -712,15 +719,15 @@ EOF HP_ARCH=hppa64 fi fi - echo ${HP_ARCH}-hp-hpux${HPUX_REV} + echo "$HP_ARCH"-hp-hpux"$HPUX_REV" exit ;; ia64:HP-UX:*:*) - HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` - echo ia64-hp-hpux${HPUX_REV} + HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` + echo ia64-hp-hpux"$HPUX_REV" exit ;; 3050*:HI-UX:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + eval "$set_cc_for_build" + sed 's/^ //' << EOF > "$dummy.c" #include int main () @@ -745,11 +752,11 @@ EOF exit (0); } EOF - $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && + $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } echo unknown-hitachi-hiuxwe2 exit ;; - 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) + 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) echo hppa1.1-hp-bsd exit ;; 9000/8??:4.3bsd:*:*) @@ -758,7 +765,7 @@ EOF *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit ;; - hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) + hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) echo hppa1.1-hp-osf exit ;; hp8??:OSF1:*:*) @@ -766,9 +773,9 @@ EOF exit ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then - echo ${UNAME_MACHINE}-unknown-osf1mk + echo "$UNAME_MACHINE"-unknown-osf1mk else - echo ${UNAME_MACHINE}-unknown-osf1 + echo "$UNAME_MACHINE"-unknown-osf1 fi exit ;; parisc*:Lites*:*:*) @@ -793,128 +800,109 @@ EOF echo c4-convex-bsd exit ;; CRAY*Y-MP:*:*:*) - echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*[A-Z]90:*:*:*) - echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ + echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) - echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*T3E:*:*:*) - echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*SV1:*:*:*) - echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; *:UNICOS/mp:*:*) - echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` + FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) - echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} + echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE" exit ;; sparc*:BSD/OS:*:*) - echo sparc-unknown-bsdi${UNAME_RELEASE} + echo sparc-unknown-bsdi"$UNAME_RELEASE" exit ;; *:BSD/OS:*:*) - echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} + echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE" exit ;; *:FreeBSD:*:*) UNAME_PROCESSOR=`/usr/bin/uname -p` - case ${UNAME_PROCESSOR} in + case "$UNAME_PROCESSOR" in amd64) UNAME_PROCESSOR=x86_64 ;; i386) UNAME_PROCESSOR=i586 ;; esac - echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" exit ;; i*:CYGWIN*:*) - echo ${UNAME_MACHINE}-pc-cygwin + echo "$UNAME_MACHINE"-pc-cygwin exit ;; *:MINGW64*:*) - echo ${UNAME_MACHINE}-pc-mingw64 + echo "$UNAME_MACHINE"-pc-mingw64 exit ;; *:MINGW*:*) - echo ${UNAME_MACHINE}-pc-mingw32 + echo "$UNAME_MACHINE"-pc-mingw32 exit ;; *:MSYS*:*) - echo ${UNAME_MACHINE}-pc-msys - exit ;; - i*:windows32*:*) - # uname -m includes "-pc" on this system. - echo ${UNAME_MACHINE}-mingw32 + echo "$UNAME_MACHINE"-pc-msys exit ;; i*:PW*:*) - echo ${UNAME_MACHINE}-pc-pw32 + echo "$UNAME_MACHINE"-pc-pw32 exit ;; *:Interix*:*) - case ${UNAME_MACHINE} in + case "$UNAME_MACHINE" in x86) - echo i586-pc-interix${UNAME_RELEASE} + echo i586-pc-interix"$UNAME_RELEASE" exit ;; authenticamd | genuineintel | EM64T) - echo x86_64-unknown-interix${UNAME_RELEASE} + echo x86_64-unknown-interix"$UNAME_RELEASE" exit ;; IA64) - echo ia64-unknown-interix${UNAME_RELEASE} + echo ia64-unknown-interix"$UNAME_RELEASE" exit ;; esac ;; - [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) - echo i${UNAME_MACHINE}-pc-mks - exit ;; - 8664:Windows_NT:*) - echo x86_64-pc-mks - exit ;; - i*:Windows_NT*:* | Pentium*:Windows_NT*:*) - # How do we know it's Interix rather than the generic POSIX subsystem? - # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we - # UNAME_MACHINE based on the output of uname instead of i386? - echo i586-pc-interix - exit ;; i*:UWIN*:*) - echo ${UNAME_MACHINE}-pc-uwin + echo "$UNAME_MACHINE"-pc-uwin exit ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; - p*:CYGWIN*:*) - echo powerpcle-unknown-cygwin - exit ;; prep*:SunOS:5.*:*) - echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" exit ;; *:GNU:*:*) # the GNU system - echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` + echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`" exit ;; *:GNU/*:*:*) # other systems with GNU libc and userland - echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC} + echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC" exit ;; i*86:Minix:*:*) - echo ${UNAME_MACHINE}-pc-minix + echo "$UNAME_MACHINE"-pc-minix exit ;; aarch64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in @@ -928,63 +916,63 @@ EOF esac objdump --private-headers /bin/sh | grep -q ld.so.1 if test "$?" = 0 ; then LIBC=gnulibc1 ; fi - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; arc:Linux:*:* | arceb:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; arm*:Linux:*:*) - eval $set_cc_for_build + eval "$set_cc_for_build" if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" else if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then - echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi else - echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf fi fi exit ;; avr32*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; cris:Linux:*:*) - echo ${UNAME_MACHINE}-axis-linux-${LIBC} + echo "$UNAME_MACHINE"-axis-linux-"$LIBC" exit ;; crisv32:Linux:*:*) - echo ${UNAME_MACHINE}-axis-linux-${LIBC} + echo "$UNAME_MACHINE"-axis-linux-"$LIBC" exit ;; e2k:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; frv:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; hexagon:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; i*86:Linux:*:*) - echo ${UNAME_MACHINE}-pc-linux-${LIBC} + echo "$UNAME_MACHINE"-pc-linux-"$LIBC" exit ;; ia64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; k1om:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; m32r*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; m68*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; mips:Linux:*:* | mips64:Linux:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + eval "$set_cc_for_build" + sed 's/^ //' << EOF > "$dummy.c" #undef CPU #undef ${UNAME_MACHINE} #undef ${UNAME_MACHINE}el @@ -998,70 +986,70 @@ EOF #endif #endif EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` - test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; } + eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU'`" + test "x$CPU" != x && { echo "$CPU-unknown-linux-$LIBC"; exit; } ;; mips64el:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; openrisc*:Linux:*:*) - echo or1k-unknown-linux-${LIBC} + echo or1k-unknown-linux-"$LIBC" exit ;; or32:Linux:*:* | or1k*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; padre:Linux:*:*) - echo sparc-unknown-linux-${LIBC} + echo sparc-unknown-linux-"$LIBC" exit ;; parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-${LIBC} + echo hppa64-unknown-linux-"$LIBC" exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in - PA7*) echo hppa1.1-unknown-linux-${LIBC} ;; - PA8*) echo hppa2.0-unknown-linux-${LIBC} ;; - *) echo hppa-unknown-linux-${LIBC} ;; + PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;; + PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;; + *) echo hppa-unknown-linux-"$LIBC" ;; esac exit ;; ppc64:Linux:*:*) - echo powerpc64-unknown-linux-${LIBC} + echo powerpc64-unknown-linux-"$LIBC" exit ;; ppc:Linux:*:*) - echo powerpc-unknown-linux-${LIBC} + echo powerpc-unknown-linux-"$LIBC" exit ;; ppc64le:Linux:*:*) - echo powerpc64le-unknown-linux-${LIBC} + echo powerpc64le-unknown-linux-"$LIBC" exit ;; ppcle:Linux:*:*) - echo powerpcle-unknown-linux-${LIBC} + echo powerpcle-unknown-linux-"$LIBC" exit ;; riscv32:Linux:*:* | riscv64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; s390:Linux:*:* | s390x:Linux:*:*) - echo ${UNAME_MACHINE}-ibm-linux-${LIBC} + echo "$UNAME_MACHINE"-ibm-linux-"$LIBC" exit ;; sh64*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; sh*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; sparc:Linux:*:* | sparc64:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; tile*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; vax:Linux:*:*) - echo ${UNAME_MACHINE}-dec-linux-${LIBC} + echo "$UNAME_MACHINE"-dec-linux-"$LIBC" exit ;; x86_64:Linux:*:*) - echo ${UNAME_MACHINE}-pc-linux-${LIBC} + echo "$UNAME_MACHINE"-pc-linux-"$LIBC" exit ;; xtensa*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. @@ -1075,34 +1063,34 @@ EOF # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. - echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} + echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION" exit ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. - echo ${UNAME_MACHINE}-pc-os2-emx + echo "$UNAME_MACHINE"-pc-os2-emx exit ;; i*86:XTS-300:*:STOP) - echo ${UNAME_MACHINE}-unknown-stop + echo "$UNAME_MACHINE"-unknown-stop exit ;; i*86:atheos:*:*) - echo ${UNAME_MACHINE}-unknown-atheos + echo "$UNAME_MACHINE"-unknown-atheos exit ;; i*86:syllable:*:*) - echo ${UNAME_MACHINE}-pc-syllable + echo "$UNAME_MACHINE"-pc-syllable exit ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) - echo i386-unknown-lynxos${UNAME_RELEASE} + echo i386-unknown-lynxos"$UNAME_RELEASE" exit ;; i*86:*DOS:*:*) - echo ${UNAME_MACHINE}-pc-msdosdjgpp + echo "$UNAME_MACHINE"-pc-msdosdjgpp exit ;; - i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) - UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` + i*86:*:4.*:*) + UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then - echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} + echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL" else - echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} + echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL" fi exit ;; i*86:*:5:[678]*) @@ -1112,12 +1100,12 @@ EOF *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac - echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} + echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}{$UNAME_VERSION}" exit ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 @@ -1127,9 +1115,9 @@ EOF && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 - echo ${UNAME_MACHINE}-pc-sco$UNAME_REL + echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL" else - echo ${UNAME_MACHINE}-pc-sysv32 + echo "$UNAME_MACHINE"-pc-sysv32 fi exit ;; pc:*:*:*) @@ -1149,9 +1137,9 @@ EOF exit ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then - echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 + echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. - echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 + echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4 fi exit ;; mini*:CTIX:SYS*5:*) @@ -1171,9 +1159,9 @@ EOF test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; + && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; @@ -1182,28 +1170,28 @@ EOF test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } + && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; + && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) - echo m68k-unknown-lynxos${UNAME_RELEASE} + echo m68k-unknown-lynxos"$UNAME_RELEASE" exit ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit ;; TSUNAMI:LynxOS:2.*:*) - echo sparc-unknown-lynxos${UNAME_RELEASE} + echo sparc-unknown-lynxos"$UNAME_RELEASE" exit ;; rs6000:LynxOS:2.*:*) - echo rs6000-unknown-lynxos${UNAME_RELEASE} + echo rs6000-unknown-lynxos"$UNAME_RELEASE" exit ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) - echo powerpc-unknown-lynxos${UNAME_RELEASE} + echo powerpc-unknown-lynxos"$UNAME_RELEASE" exit ;; SM[BE]S:UNIX_SV:*:*) - echo mips-dde-sysv${UNAME_RELEASE} + echo mips-dde-sysv"$UNAME_RELEASE" exit ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 @@ -1214,7 +1202,7 @@ EOF *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` - echo ${UNAME_MACHINE}-sni-sysv4 + echo "$UNAME_MACHINE"-sni-sysv4 else echo ns32k-sni-sysv fi @@ -1234,23 +1222,23 @@ EOF exit ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. - echo ${UNAME_MACHINE}-stratus-vos + echo "$UNAME_MACHINE"-stratus-vos exit ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit ;; mc68*:A/UX:*:*) - echo m68k-apple-aux${UNAME_RELEASE} + echo m68k-apple-aux"$UNAME_RELEASE" exit ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} + echo mips-nec-sysv"$UNAME_RELEASE" else - echo mips-unknown-sysv${UNAME_RELEASE} + echo mips-unknown-sysv"$UNAME_RELEASE" fi exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. @@ -1269,39 +1257,39 @@ EOF echo x86_64-unknown-haiku exit ;; SX-4:SUPER-UX:*:*) - echo sx4-nec-superux${UNAME_RELEASE} + echo sx4-nec-superux"$UNAME_RELEASE" exit ;; SX-5:SUPER-UX:*:*) - echo sx5-nec-superux${UNAME_RELEASE} + echo sx5-nec-superux"$UNAME_RELEASE" exit ;; SX-6:SUPER-UX:*:*) - echo sx6-nec-superux${UNAME_RELEASE} + echo sx6-nec-superux"$UNAME_RELEASE" exit ;; SX-7:SUPER-UX:*:*) - echo sx7-nec-superux${UNAME_RELEASE} + echo sx7-nec-superux"$UNAME_RELEASE" exit ;; SX-8:SUPER-UX:*:*) - echo sx8-nec-superux${UNAME_RELEASE} + echo sx8-nec-superux"$UNAME_RELEASE" exit ;; SX-8R:SUPER-UX:*:*) - echo sx8r-nec-superux${UNAME_RELEASE} + echo sx8r-nec-superux"$UNAME_RELEASE" exit ;; SX-ACE:SUPER-UX:*:*) - echo sxace-nec-superux${UNAME_RELEASE} + echo sxace-nec-superux"$UNAME_RELEASE" exit ;; Power*:Rhapsody:*:*) - echo powerpc-apple-rhapsody${UNAME_RELEASE} + echo powerpc-apple-rhapsody"$UNAME_RELEASE" exit ;; *:Rhapsody:*:*) - echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} + echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE" exit ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown - eval $set_cc_for_build + eval "$set_cc_for_build" if test "$UNAME_PROCESSOR" = unknown ; then UNAME_PROCESSOR=powerpc fi - if test `echo "$UNAME_RELEASE" | sed -e 's/\..*//'` -le 10 ; then + if test "`echo "$UNAME_RELEASE" | sed -e 's/\..*//'`" -le 10 ; then if [ "$CC_FOR_BUILD" != no_compiler_found ]; then if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ @@ -1329,7 +1317,7 @@ EOF # that Apple uses in portable devices. UNAME_PROCESSOR=x86_64 fi - echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} + echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE" exit ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` @@ -1337,22 +1325,25 @@ EOF UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi - echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} + echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE" exit ;; *:QNX:*:4*) echo i386-pc-qnx exit ;; NEO-*:NONSTOP_KERNEL:*:*) - echo neo-tandem-nsk${UNAME_RELEASE} + echo neo-tandem-nsk"$UNAME_RELEASE" exit ;; NSE-*:NONSTOP_KERNEL:*:*) - echo nse-tandem-nsk${UNAME_RELEASE} + echo nse-tandem-nsk"$UNAME_RELEASE" exit ;; NSR-*:NONSTOP_KERNEL:*:*) - echo nsr-tandem-nsk${UNAME_RELEASE} + echo nsr-tandem-nsk"$UNAME_RELEASE" + exit ;; + NSV-*:NONSTOP_KERNEL:*:*) + echo nsv-tandem-nsk"$UNAME_RELEASE" exit ;; NSX-*:NONSTOP_KERNEL:*:*) - echo nsx-tandem-nsk${UNAME_RELEASE} + echo nsx-tandem-nsk"$UNAME_RELEASE" exit ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux @@ -1361,7 +1352,7 @@ EOF echo bs2000-siemens-sysv exit ;; DS/*:UNIX_System_V:*:*) - echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} + echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE" exit ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 @@ -1372,7 +1363,7 @@ EOF else UNAME_MACHINE="$cputype" fi - echo ${UNAME_MACHINE}-unknown-plan9 + echo "$UNAME_MACHINE"-unknown-plan9 exit ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 @@ -1393,14 +1384,14 @@ EOF echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) - echo mips-sei-seiux${UNAME_RELEASE} + echo mips-sei-seiux"$UNAME_RELEASE" exit ;; *:DragonFly:*:*) - echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" exit ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` - case "${UNAME_MACHINE}" in + case "$UNAME_MACHINE" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; V*) echo vax-dec-vms ; exit ;; @@ -1409,32 +1400,44 @@ EOF echo i386-pc-xenix exit ;; i*86:skyos:*:*) - echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE} | sed -e 's/ .*$//'` + echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`" exit ;; i*86:rdos:*:*) - echo ${UNAME_MACHINE}-pc-rdos + echo "$UNAME_MACHINE"-pc-rdos exit ;; i*86:AROS:*:*) - echo ${UNAME_MACHINE}-pc-aros + echo "$UNAME_MACHINE"-pc-aros exit ;; x86_64:VMkernel:*:*) - echo ${UNAME_MACHINE}-unknown-esx + echo "$UNAME_MACHINE"-unknown-esx exit ;; amd64:Isilon\ OneFS:*:*) echo x86_64-unknown-onefs exit ;; esac +echo "$0: unable to guess system type" >&2 + +case "$UNAME_MACHINE:$UNAME_SYSTEM" in + mips:Linux | mips64:Linux) + # If we got here on MIPS GNU/Linux, output extra information. + cat >&2 <&2 </dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` -UNAME_MACHINE = ${UNAME_MACHINE} -UNAME_RELEASE = ${UNAME_RELEASE} -UNAME_SYSTEM = ${UNAME_SYSTEM} -UNAME_VERSION = ${UNAME_VERSION} +UNAME_MACHINE = "$UNAME_MACHINE" +UNAME_RELEASE = "$UNAME_RELEASE" +UNAME_SYSTEM = "$UNAME_SYSTEM" +UNAME_VERSION = "$UNAME_VERSION" EOF exit 1 # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" diff --git a/external/jpeg-9c/config.sub b/external/jpeg-9d/config.sub similarity index 85% rename from external/jpeg-9c/config.sub rename to external/jpeg-9d/config.sub index 40ea5dfe..9ccf09a7 100755 --- a/external/jpeg-9c/config.sub +++ b/external/jpeg-9d/config.sub @@ -1,8 +1,8 @@ #! /bin/sh # Configuration validation subroutine script. -# Copyright 1992-2017 Free Software Foundation, Inc. +# Copyright 1992-2018 Free Software Foundation, Inc. -timestamp='2017-04-02' +timestamp='2018-03-08' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -15,7 +15,7 @@ timestamp='2017-04-02' # General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, see . +# along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -33,7 +33,7 @@ timestamp='2017-04-02' # Otherwise, we print the canonical config type on stdout and succeed. # You can get the latest version of this script from: -# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub +# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases @@ -57,7 +57,7 @@ Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS Canonicalize a configuration name. -Operation modes: +Options: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit @@ -67,7 +67,7 @@ Report bugs and patches to ." version="\ GNU config.sub ($timestamp) -Copyright 1992-2017 Free Software Foundation, Inc. +Copyright 1992-2018 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -94,7 +94,7 @@ while test $# -gt 0 ; do *local*) # First pass through any local machine types. - echo $1 + echo "$1" exit ;; * ) @@ -112,7 +112,7 @@ esac # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). # Here we must recognize all the valid KERNEL-OS combinations. -maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` +maybe_os=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ @@ -120,16 +120,16 @@ case $maybe_os in kopensolaris*-gnu* | cloudabi*-eabi* | \ storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` + basic_machine=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; android-linux) os=-linux-android - basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown + basic_machine=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown ;; *) - basic_machine=`echo $1 | sed 's/-[^-]*$//'` - if [ $basic_machine != $1 ] - then os=`echo $1 | sed 's/.*-/-/'` + basic_machine=`echo "$1" | sed 's/-[^-]*$//'` + if [ "$basic_machine" != "$1" ] + then os=`echo "$1" | sed 's/.*-/-/'` else os=; fi ;; esac @@ -178,44 +178,44 @@ case $os in ;; -sco6) os=-sco5v6 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -sco5) os=-sco3.2v5 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -sco4) os=-sco3.2v4 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -sco3.2.[4-9]*) os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -sco3.2v[4-9]*) # Don't forget version if it is 3.2v4 or newer. - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -sco5v6*) # Don't forget version if it is 3.2v4 or newer. - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -sco*) os=-sco3.2v2 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -udk*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -isc) os=-isc2.2 - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -clix*) basic_machine=clipper-intergraph ;; -isc*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'` ;; -lynx*178) os=-lynxos178 @@ -227,10 +227,7 @@ case $os in os=-lynxos ;; -ptx*) - basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` - ;; - -windowsnt*) - os=`echo $os | sed -e 's/windowsnt/winnt/'` + basic_machine=`echo "$1" | sed -e 's/86-.*/86-sequent/'` ;; -psos*) os=-psos @@ -299,7 +296,7 @@ case $basic_machine in | nios | nios2 | nios2eb | nios2el \ | ns16k | ns32k \ | open8 | or1k | or1knd | or32 \ - | pdp10 | pdp11 | pj | pjl \ + | pdp10 | pj | pjl \ | powerpc | powerpc64 | powerpc64le | powerpcle \ | pru \ | pyramid \ @@ -316,7 +313,6 @@ case $basic_machine in | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ | visium \ | wasm32 \ - | we32k \ | x86 | xc16x | xstormy16 | xtensa \ | z8k | z80) basic_machine=$basic_machine-unknown @@ -337,7 +333,7 @@ case $basic_machine in basic_machine=$basic_machine-unknown os=-none ;; - m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) + m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65) ;; ms1) basic_machine=mt-unknown @@ -366,7 +362,7 @@ case $basic_machine in ;; # Object if more than one company name word. *-*-*) - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2 exit 1 ;; # Recognize the basic CPU types with company name. @@ -461,7 +457,7 @@ case $basic_machine in # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) - basic_machine=i386-unknown + basic_machine=i386-pc os=-bsd ;; 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) @@ -495,7 +491,7 @@ case $basic_machine in basic_machine=x86_64-pc ;; amd64-*) - basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=x86_64-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; amdahl) basic_machine=580-amdahl @@ -540,7 +536,7 @@ case $basic_machine in os=-linux ;; blackfin-*) - basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=bfin-`echo "$basic_machine" | sed 's/^[^-]*-//'` os=-linux ;; bluegene*) @@ -548,13 +544,13 @@ case $basic_machine in os=-cnk ;; c54x-*) - basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=tic54x-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; c55x-*) - basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=tic55x-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; c6x-*) - basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=tic6x-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; c90) basic_machine=c90-cray @@ -643,7 +639,7 @@ case $basic_machine in basic_machine=rs6000-bull os=-bosx ;; - dpx2* | dpx2*-bull) + dpx2*) basic_machine=m68k-bull os=-sysv3 ;; @@ -652,7 +648,7 @@ case $basic_machine in os=$os"spe" ;; e500v[12]-*) - basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'` os=$os"spe" ;; ebmon29k) @@ -744,9 +740,6 @@ case $basic_machine in hp9k8[0-9][0-9] | hp8[0-9][0-9]) basic_machine=hppa1.0-hp ;; - hppa-next) - os=-nextstep3 - ;; hppaosf) basic_machine=hppa1.1-hp os=-osf @@ -759,26 +752,26 @@ case $basic_machine in basic_machine=i370-ibm ;; i*86v32) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; i*86v4*) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; i*86v) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'` os=-sysv ;; i*86sol2) - basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; i386mach) basic_machine=i386-mach os=-mach ;; - i386-vsta | vsta) + vsta) basic_machine=i386-unknown os=-vsta ;; @@ -797,19 +790,16 @@ case $basic_machine in os=-sysv ;; leon-*|leon[3-9]-*) - basic_machine=sparc-`echo $basic_machine | sed 's/-.*//'` + basic_machine=sparc-`echo "$basic_machine" | sed 's/-.*//'` ;; m68knommu) basic_machine=m68k-unknown os=-linux ;; m68knommu-*) - basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=m68k-`echo "$basic_machine" | sed 's/^[^-]*-//'` os=-linux ;; - m88k-omron*) - basic_machine=m88k-omron - ;; magnum | m3230) basic_machine=mips-mips os=-sysv @@ -841,10 +831,10 @@ case $basic_machine in os=-mint ;; mips3*-*) - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` + basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'` ;; mips3*) - basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown + basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'`-unknown ;; monitor) basic_machine=m68k-rom68k @@ -863,7 +853,7 @@ case $basic_machine in os=-msdos ;; ms1-*) - basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` + basic_machine=`echo "$basic_machine" | sed -e 's/ms1-/mt-/'` ;; msys) basic_machine=i686-pc @@ -905,7 +895,7 @@ case $basic_machine in basic_machine=v70-nec os=-sysv ;; - next | m*-next ) + next | m*-next) basic_machine=m68k-next case $os in -nextstep* ) @@ -950,6 +940,9 @@ case $basic_machine in nsr-tandem) basic_machine=nsr-tandem ;; + nsv-tandem) + basic_machine=nsv-tandem + ;; nsx-tandem) basic_machine=nsx-tandem ;; @@ -985,7 +978,7 @@ case $basic_machine in os=-linux ;; parisc-*) - basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=hppa-`echo "$basic_machine" | sed 's/^[^-]*-//'` os=-linux ;; pbd) @@ -1001,7 +994,7 @@ case $basic_machine in basic_machine=i386-pc ;; pc98-*) - basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=i386-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc @@ -1016,16 +1009,16 @@ case $basic_machine in basic_machine=i786-pc ;; pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) - basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=i586-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pentiumpro-* | p6-* | 6x86-* | athlon-*) - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) - basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pentium4-*) - basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=i786-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould @@ -1035,23 +1028,23 @@ case $basic_machine in ppc | ppcbe) basic_machine=powerpc-unknown ;; ppc-* | ppcbe-*) - basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle) basic_machine=powerpcle-unknown ;; ppcle-* | powerpclittle-*) - basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=powerpcle-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; ppc64) basic_machine=powerpc64-unknown ;; - ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` + ppc64-*) basic_machine=powerpc64-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little) basic_machine=powerpc64le-unknown ;; ppc64le-* | powerpc64little-*) - basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=powerpc64le-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; ps2) basic_machine=i386-ibm @@ -1105,17 +1098,10 @@ case $basic_machine in sequent) basic_machine=i386-sequent ;; - sh) - basic_machine=sh-hitachi - os=-hms - ;; sh5el) basic_machine=sh5le-unknown ;; - sh64) - basic_machine=sh64-unknown - ;; - sparclite-wrs | simso-wrs) + simso-wrs) basic_machine=sparclite-wrs os=-vxworks ;; @@ -1134,7 +1120,7 @@ case $basic_machine in os=-sysv4 ;; strongarm-* | thumb-*) - basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` + basic_machine=arm-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; sun2) basic_machine=m68000-sun @@ -1248,9 +1234,6 @@ case $basic_machine in basic_machine=a29k-wrs os=-vxworks ;; - wasm32) - basic_machine=wasm32-unknown - ;; w65*) basic_machine=w65-wdc os=-none @@ -1259,6 +1242,9 @@ case $basic_machine in basic_machine=hppa1.1-winbond os=-proelf ;; + x64) + basic_machine=x86_64-pc + ;; xbox) basic_machine=i686-pc os=-mingw32 @@ -1267,20 +1253,12 @@ case $basic_machine in basic_machine=xps100-honeywell ;; xscale-* | xscalee[bl]-*) - basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` + basic_machine=`echo "$basic_machine" | sed 's/^xscale/arm/'` ;; ymp) basic_machine=ymp-cray os=-unicos ;; - z8k-*-coff) - basic_machine=z8k-unknown - os=-sim - ;; - z80-*-coff) - basic_machine=z80-unknown - os=-sim - ;; none) basic_machine=none-none os=-none @@ -1309,10 +1287,6 @@ case $basic_machine in vax) basic_machine=vax-dec ;; - pdp10) - # there are many clones, so DEC is not a safe bet - basic_machine=pdp10-unknown - ;; pdp11) basic_machine=pdp11-dec ;; @@ -1322,9 +1296,6 @@ case $basic_machine in sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; - sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) - basic_machine=sparc-sun - ;; cydra) basic_machine=cydra-cydrome ;; @@ -1344,7 +1315,7 @@ case $basic_machine in # Make sure to match an already-canonicalized machine name. ;; *) - echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2 exit 1 ;; esac @@ -1352,10 +1323,10 @@ esac # Here we canonicalize certain aliases for manufacturers. case $basic_machine in *-digital*) - basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` + basic_machine=`echo "$basic_machine" | sed 's/digital.*/dec/'` ;; *-commodore*) - basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` + basic_machine=`echo "$basic_machine" | sed 's/commodore.*/cbm/'` ;; *) ;; @@ -1366,8 +1337,8 @@ esac if [ x"$os" != x"" ] then case $os in - # First match some system type aliases - # that might get confused with valid system types. + # First match some system type aliases that might get confused + # with valid system types. # -solaris* is a basic system type, with this one exception. -auroraux) os=-auroraux @@ -1378,18 +1349,19 @@ case $os in -solaris) os=-solaris2 ;; - -svr4*) - os=-sysv4 - ;; -unixware*) os=-sysv4.2uw ;; -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; - # First accept the basic system types. + # es1800 is here to avoid being matched by es* (a different OS) + -es1800*) + os=-ose + ;; + # Now accept the basic system types. # The portable systems comes first. - # Each alternative MUST END IN A *, to match a version number. + # Each alternative MUST end in a * to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ @@ -1399,25 +1371,26 @@ case $os in | -aos* | -aros* | -cloudabi* | -sortix* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ - | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ + | -hiux* | -knetbsd* | -mirbsd* | -netbsd* \ | -bitrig* | -openbsd* | -solidbsd* | -libertybsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ - | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* | -hcos* \ | -chorusos* | -chorusrdb* | -cegcc* | -glidix* \ | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -midipix* | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ | -linux-newlib* | -linux-musl* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \ - | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ - | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ + | -morphos* | -superux* | -rtmk* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* \ - | -onefs* | -tirtos* | -phoenix* | -fuchsia* | -redox*) + | -onefs* | -tirtos* | -phoenix* | -fuchsia* | -redox* | -bme* \ + | -midnightbsd*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) @@ -1434,12 +1407,12 @@ case $os in -nto*) os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; - -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ - | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ + -sim | -xray | -os68k* | -v88r* \ + | -windows* | -osx | -abug | -netware* | -os9* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) - os=`echo $os | sed -e 's|mac|macos|'` + os=`echo "$os" | sed -e 's|mac|macos|'` ;; -linux-dietlibc) os=-linux-dietlibc @@ -1448,10 +1421,10 @@ case $os in os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; -sunos5*) - os=`echo $os | sed -e 's|sunos5|solaris2|'` + os=`echo "$os" | sed -e 's|sunos5|solaris2|'` ;; -sunos6*) - os=`echo $os | sed -e 's|sunos6|solaris3|'` + os=`echo "$os" | sed -e 's|sunos6|solaris3|'` ;; -opened*) os=-openedition @@ -1462,12 +1435,6 @@ case $os in -wince*) os=-wince ;; - -osfrose*) - os=-osfrose - ;; - -osf*) - os=-osf - ;; -utek*) os=-bsd ;; @@ -1492,7 +1459,7 @@ case $os in -nova*) os=-rtmk-nova ;; - -ns2 ) + -ns2) os=-nextstep2 ;; -nsk*) @@ -1514,7 +1481,7 @@ case $os in -oss*) os=-sysv3 ;; - -svr4) + -svr4*) os=-sysv4 ;; -svr3) @@ -1529,24 +1496,28 @@ case $os in -ose*) os=-ose ;; - -es1800*) - os=-ose - ;; - -xenix) - os=-xenix - ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) os=-mint ;; - -aros*) - os=-aros - ;; -zvmoe) os=-zvmoe ;; -dicos*) os=-dicos ;; + -pikeos*) + # Until real need of OS specific support for + # particular features comes up, bare metal + # configurations are quite functional. + case $basic_machine in + arm*) + os=-eabi + ;; + *) + os=-elf + ;; + esac + ;; -nacl*) ;; -ios) @@ -1556,7 +1527,7 @@ case $os in *) # Get rid of the `-' at the beginning of $os. os=`echo $os | sed 's/[^-]*-//'` - echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 + echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2 exit 1 ;; esac @@ -1652,9 +1623,6 @@ case $basic_machine in *-be) os=-beos ;; - *-haiku) - os=-haiku - ;; *-ibm) os=-aix ;; @@ -1694,7 +1662,7 @@ case $basic_machine in m88k-omron*) os=-luna ;; - *-next ) + *-next) os=-nextstep ;; *-sequent) @@ -1709,9 +1677,6 @@ case $basic_machine in i370-*) os=-mvs ;; - *-next) - os=-nextstep3 - ;; *-gould) os=-sysv ;; @@ -1821,15 +1786,15 @@ case $basic_machine in vendor=stratus ;; esac - basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` + basic_machine=`echo "$basic_machine" | sed "s/unknown/$vendor/"` ;; esac -echo $basic_machine$os +echo "$basic_machine$os" exit # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" diff --git a/external/jpeg-9c/configure b/external/jpeg-9d/configure similarity index 99% rename from external/jpeg-9c/configure rename to external/jpeg-9d/configure index 9c593db4..ccd339d1 100755 --- a/external/jpeg-9c/configure +++ b/external/jpeg-9d/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for libjpeg 9.3.0. +# Generated by GNU Autoconf 2.69 for libjpeg 9.4.0. # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. @@ -587,8 +587,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='libjpeg' PACKAGE_TARNAME='libjpeg' -PACKAGE_VERSION='9.3.0' -PACKAGE_STRING='libjpeg 9.3.0' +PACKAGE_VERSION='9.4.0' +PACKAGE_STRING='libjpeg 9.4.0' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -632,6 +632,8 @@ ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS LIBOBJS +JPEG_LIB_VERSION_MINOR +JPEG_LIB_VERSION_MAJOR JPEG_LIB_VERSION MEMORYMGR LT_SYS_LIBRARY_PATH @@ -667,7 +669,6 @@ am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE -am__quote am__include DEPDIR OBJEXT @@ -756,7 +757,8 @@ PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR -SHELL' +SHELL +am__quote' ac_subst_files='' ac_user_opts=' enable_option_checking @@ -1324,7 +1326,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures libjpeg 9.3.0 to adapt to many kinds of systems. +\`configure' configures libjpeg 9.4.0 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1395,7 +1397,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of libjpeg 9.3.0:";; + short | recursive ) echo "Configuration of libjpeg 9.4.0:";; esac cat <<\_ACEOF @@ -1512,7 +1514,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -libjpeg configure 9.3.0 +libjpeg configure 9.4.0 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -1877,7 +1879,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by libjpeg $as_me 9.3.0, which was +It was created by libjpeg $as_me 9.4.0, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -2378,7 +2380,7 @@ test -n "$target_alias" && # Initialize Automake # Don't require all the GNU mandated files -am__api_version='1.15' +am__api_version='1.16' # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or @@ -2864,7 +2866,7 @@ fi # Define the identity of the package. PACKAGE='libjpeg' - VERSION='9.3.0' + VERSION='9.4.0' cat >>confdefs.h <<_ACEOF @@ -2894,8 +2896,8 @@ MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: -# -# +# +# mkdir_p='$(MKDIR_P)' # We need awk for the "check" target (and possibly the TAP driver). The @@ -2946,7 +2948,7 @@ END Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: . +that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM @@ -3880,45 +3882,45 @@ DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" - -am_make=${MAKE-make} -cat > confinc << 'END' +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5 +$as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; } +cat > confinc.mk << 'END' am__doit: - @echo this is the am__doit target + @echo this is the am__doit target >confinc.out .PHONY: am__doit END -# If we don't find an include directive, just comment out the code. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 -$as_echo_n "checking for style of include used by $am_make... " >&6; } am__include="#" am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from 'make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD +# BSD make does it like this. +echo '.include "confinc.mk" # ignored' > confmf.BSD +# Other make implementations (GNU, Solaris 10, AIX) do it like this. +echo 'include confinc.mk # ignored' > confmf.GNU +_am_result=no +for s in GNU BSD; do + { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5 + (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } + case $?:`cat confinc.out 2>/dev/null` in #( + '0:this is the am__doit target') : + case $s in #( + BSD) : + am__include='.include' am__quote='"' ;; #( + *) : + am__include='include' am__quote='' ;; +esac ;; #( + *) : ;; - esac -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 -$as_echo "$_am_result" >&6; } -rm -f confinc confmf +esac + if test "$am__include" != "#"; then + _am_result="yes ($s style)" + break + fi +done +rm -f confinc.* confmf.* +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5 +$as_echo "${_am_result}" >&6; } # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then : @@ -13576,8 +13578,12 @@ major=`sed -ne 's/^#define JPEG_LIB_VERSION_MAJOR *\([0-9][0-9]*\).*$/\1/p' $src minor=`sed -ne 's/^#define JPEG_LIB_VERSION_MINOR *\([0-9][0-9]*\).*$/\1/p' $srcdir/jpeglib.h` JPEG_LIB_VERSION=`expr $major + $minor`:0:$minor -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $JPEG_LIB_VERSION" >&5 -$as_echo "$JPEG_LIB_VERSION" >&6; } +JPEG_LIB_VERSION_MAJOR=$major + +JPEG_LIB_VERSION_MINOR=$minor + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $major.$minor.0" >&5 +$as_echo "$major.$minor.0" >&6; } ac_config_files="$ac_config_files Makefile libjpeg.pc" @@ -14119,7 +14125,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by libjpeg $as_me 9.3.0, which was +This file was extended by libjpeg $as_me 9.4.0, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -14185,7 +14191,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -libjpeg config.status 9.3.0 +libjpeg config.status 9.4.0 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" @@ -14304,7 +14310,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # -AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" +AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}" # The HP-UX ksh and POSIX shell print the target directory to stdout @@ -15203,29 +15209,35 @@ $as_echo "$as_me: executing $ac_file commands" >&6;} # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac + # TODO: see whether this extra hack can be removed once we start + # requiring Autoconf 2.70 or later. + case $CONFIG_FILES in #( + *\'*) : + eval set x "$CONFIG_FILES" ;; #( + *) : + set x $CONFIG_FILES ;; #( + *) : + ;; +esac shift - for mf + # Used to flag and report bootstrapping failures. + am_rc=0 + for am_mf do # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named 'Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line + am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile which includes + # dependency-tracking related rules and includes. + # Grep'ing the whole file directly is not great: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`$as_dirname -- "$mf" || -$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$mf" : 'X\(//\)[^/]' \| \ - X"$mf" : 'X\(//\)$' \| \ - X"$mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$mf" | + sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ + || continue + am_dirpart=`$as_dirname -- "$am_mf" || +$as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$am_mf" : 'X\(//\)[^/]' \| \ + X"$am_mf" : 'X\(//\)$' \| \ + X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$am_mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q @@ -15243,53 +15255,48 @@ $as_echo X"$mf" | q } s/.*/./; q'` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running 'make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "$am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`$as_dirname -- "$file" || -$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$file" : 'X\(//\)[^/]' \| \ - X"$file" : 'X\(//\)$' \| \ - X"$file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ + am_filepart=`$as_basename -- "$am_mf" || +$as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \ + X"$am_mf" : 'X\(//\)$' \| \ + X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$am_mf" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } - /^X\(\/\/\)$/{ + /^X\/\(\/\/\)$/{ s//\1/ q } - /^X\(\/\).*/{ + /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` - as_dir=$dirpart/$fdir; as_fn_mkdir_p - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done + { echo "$as_me:$LINENO: cd "$am_dirpart" \ + && sed -e '/# am--include-marker/d' "$am_filepart" \ + | $MAKE -f - am--depfiles" >&5 + (cd "$am_dirpart" \ + && sed -e '/# am--include-marker/d' "$am_filepart" \ + | $MAKE -f - am--depfiles) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } || am_rc=$? done + if test $am_rc -ne 0; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "Something went wrong bootstrapping makefile fragments + for automatic dependency tracking. 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). +See \`config.log' for more details" "$LINENO" 5; } + fi + { am_dirpart=; unset am_dirpart;} + { am_filepart=; unset am_filepart;} + { am_mf=; unset am_mf;} + { am_rc=; unset am_rc;} + rm -f conftest-deps.mk } ;; "libtool":C) diff --git a/external/jpeg-9c/configure.ac b/external/jpeg-9d/configure.ac similarity index 98% rename from external/jpeg-9c/configure.ac rename to external/jpeg-9d/configure.ac index 503f7361..eb3eeede 100644 --- a/external/jpeg-9c/configure.ac +++ b/external/jpeg-9d/configure.ac @@ -5,7 +5,7 @@ # Configure script for IJG libjpeg # -AC_INIT([libjpeg], [9.3.0]) +AC_INIT([libjpeg], [9.4.0]) # Directory where autotools helper scripts lives. AC_CONFIG_AUX_DIR([.]) @@ -357,9 +357,10 @@ AC_SUBST([MEMORYMGR]) AC_MSG_CHECKING([libjpeg version number]) [major=`sed -ne 's/^#define JPEG_LIB_VERSION_MAJOR *\([0-9][0-9]*\).*$/\1/p' $srcdir/jpeglib.h` minor=`sed -ne 's/^#define JPEG_LIB_VERSION_MINOR *\([0-9][0-9]*\).*$/\1/p' $srcdir/jpeglib.h`] -AC_SUBST([JPEG_LIB_VERSION], - [`expr $major + $minor`:0:$minor]) -AC_MSG_RESULT([$JPEG_LIB_VERSION]) +AC_SUBST([JPEG_LIB_VERSION], [`expr $major + $minor`:0:$minor]) +AC_SUBST([JPEG_LIB_VERSION_MAJOR], [$major]) +AC_SUBST([JPEG_LIB_VERSION_MINOR], [$minor]) +AC_MSG_RESULT([$major.$minor.0]) AC_CONFIG_FILES([Makefile libjpeg.pc]) AC_OUTPUT diff --git a/external/jpeg-9c/depcomp b/external/jpeg-9d/depcomp similarity index 99% rename from external/jpeg-9c/depcomp rename to external/jpeg-9d/depcomp index b39f98f9..65cbf709 100755 --- a/external/jpeg-9c/depcomp +++ b/external/jpeg-9d/depcomp @@ -1,9 +1,9 @@ #! /bin/sh # depcomp - compile a program generating dependencies as side-effects -scriptversion=2016-01-11.22; # UTC +scriptversion=2018-03-07.03; # UTC -# Copyright (C) 1999-2017 Free Software Foundation, Inc. +# Copyright (C) 1999-2018 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 @@ -16,7 +16,7 @@ scriptversion=2016-01-11.22; # UTC # GNU General Public License for more details. # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -783,7 +783,7 @@ exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/external/jpeg-9c/djpeg.1 b/external/jpeg-9d/djpeg.1 similarity index 90% rename from external/jpeg-9c/djpeg.1 rename to external/jpeg-9d/djpeg.1 index dfbe4f12..1cb364f2 100644 --- a/external/jpeg-9c/djpeg.1 +++ b/external/jpeg-9d/djpeg.1 @@ -1,4 +1,4 @@ -.TH DJPEG 1 "26 July 2015" +.TH DJPEG 1 "28 April 2019" .SH NAME djpeg \- decompress a JPEG file to an image file .SH SYNOPSIS @@ -16,7 +16,8 @@ djpeg \- decompress a JPEG file to an image file decompresses the named JPEG file, or the standard input if no file is named, and produces an image file on the standard output. PBMPLUS (PPM/PGM), BMP, GIF, Targa, or RLE (Utah Raster Toolkit) output format can be selected. -(RLE is supported only if the URT library is available.) +(RLE is supported only if the URT library is available, which it isn't +on most non-Unix systems.) .SH OPTIONS All switch names may be abbreviated; for example, .B \-grayscale @@ -76,8 +77,8 @@ Scaling is handy if the image is larger than your screen; also, runs much faster when scaling down the output. .TP .B \-bmp -Select BMP output format (Windows flavor). 8-bit colormapped format is -emitted if +Select BMP output format (Windows flavor). +8-bit colormapped format is emitted if .B \-colors or .B \-grayscale @@ -85,13 +86,24 @@ is specified, or if the JPEG file is grayscale; otherwise, 24-bit full-color format is emitted. .TP .B \-gif -Select GIF output format. Since GIF does not support more than 256 colors, +Select GIF output format (LZW compressed). +Since GIF does not support more than 256 colors, .B \-colors 256 -is assumed (unless you specify a smaller number of colors). +is assumed (unless you specify a smaller number of colors). If you specify +.BR \-fast , +the default number of colors is 216. +.TP +.B \-gif0 +Select GIF output format (uncompressed). +Since GIF does not support more than 256 colors, +.B \-colors 256 +is assumed (unless you specify a smaller number of colors). If you specify +.BR \-fast , +the default number of colors is 216. .TP .B \-os2 -Select BMP output format (OS/2 1.x flavor). 8-bit colormapped format is -emitted if +Select BMP output format (OS/2 1.x flavor). +8-bit colormapped format is emitted if .B \-colors or .B \-grayscale @@ -250,8 +262,3 @@ Wallace, Gregory K. "The JPEG Still Picture Compression Standard", Communications of the ACM, April 1991 (vol. 34, no. 4), pp. 30-44. .SH AUTHOR Independent JPEG Group -.SH BUGS -To avoid the Unisys LZW patent (now expired), -.B djpeg -produces uncompressed GIF files. These are larger than they should be, but -are readable by standard GIF decoders. diff --git a/external/jpeg-9c/djpeg.c b/external/jpeg-9d/djpeg.c similarity index 96% rename from external/jpeg-9c/djpeg.c rename to external/jpeg-9d/djpeg.c index 0c9b89bd..a01b3968 100644 --- a/external/jpeg-9c/djpeg.c +++ b/external/jpeg-9d/djpeg.c @@ -2,7 +2,7 @@ * djpeg.c * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2009-2015 by Guido Vollbeding. + * Modified 2009-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -59,7 +59,8 @@ static const char * const cdjpeg_message_table[] = { typedef enum { FMT_BMP, /* BMP format (Windows flavor) */ - FMT_GIF, /* GIF format */ + FMT_GIF, /* GIF format (LZW compressed) */ + FMT_GIF0, /* GIF format (uncompressed) */ FMT_OS2, /* BMP format (OS/2 flavor) */ FMT_PPM, /* PPM/PGM (PBMPLUS formats) */ FMT_RLE, /* RLE format */ @@ -111,8 +112,10 @@ usage (void) (DEFAULT_FMT == FMT_BMP ? " (default)" : "")); #endif #ifdef GIF_SUPPORTED - fprintf(stderr, " -gif Select GIF output format%s\n", + fprintf(stderr, " -gif Select GIF output format (LZW compressed)%s\n", (DEFAULT_FMT == FMT_GIF ? " (default)" : "")); + fprintf(stderr, " -gif0 Select GIF output format (uncompressed)%s\n", + (DEFAULT_FMT == FMT_GIF0 ? " (default)" : "")); #endif #ifdef BMP_SUPPORTED fprintf(stderr, " -os2 Select BMP output format (OS/2 style)%s\n", @@ -195,7 +198,7 @@ parse_switches (j_decompress_ptr cinfo, int argc, char **argv, arg++; /* advance past switch marker character */ if (keymatch(arg, "bmp", 1)) { - /* BMP output format. */ + /* BMP output format (Windows flavor). */ requested_fmt = FMT_BMP; } else if (keymatch(arg, "colors", 1) || keymatch(arg, "colours", 1) || @@ -258,9 +261,13 @@ parse_switches (j_decompress_ptr cinfo, int argc, char **argv, cinfo->do_fancy_upsampling = FALSE; } else if (keymatch(arg, "gif", 1)) { - /* GIF output format. */ + /* GIF output format (LZW compressed). */ requested_fmt = FMT_GIF; + } else if (keymatch(arg, "gif0", 4)) { + /* GIF output format (uncompressed). */ + requested_fmt = FMT_GIF0; + } else if (keymatch(arg, "grayscale", 2) || keymatch(arg, "greyscale",2)) { /* Force monochrome output. */ cinfo->out_color_space = JCS_GRAYSCALE; @@ -461,7 +468,7 @@ main (int argc, char **argv) * APP12 is used by some digital camera makers for textual info, * so we provide the ability to display it as text. * If you like, additional APPn marker types can be selected for display, - * but don't try to override APP0 or APP14 this way (see libjpeg.doc). + * but don't try to override APP0 or APP14 this way (see libjpeg.txt). */ jpeg_set_marker_processor(&cinfo, JPEG_COM, print_text_marker); jpeg_set_marker_processor(&cinfo, JPEG_APP0+12, print_text_marker); @@ -554,7 +561,10 @@ main (int argc, char **argv) #endif #ifdef GIF_SUPPORTED case FMT_GIF: - dest_mgr = jinit_write_gif(&cinfo); + dest_mgr = jinit_write_gif(&cinfo, TRUE); + break; + case FMT_GIF0: + dest_mgr = jinit_write_gif(&cinfo, FALSE); break; #endif #ifdef PPM_SUPPORTED @@ -574,7 +584,6 @@ main (int argc, char **argv) #endif default: ERREXIT(&cinfo, JERR_UNSUPPORTED_FORMAT); - break; } dest_mgr->output_file = output_file; diff --git a/external/jpeg-9c/example.c b/external/jpeg-9d/example.c similarity index 100% rename from external/jpeg-9c/example.c rename to external/jpeg-9d/example.c diff --git a/external/jpeg-9c/filelist.txt b/external/jpeg-9d/filelist.txt similarity index 98% rename from external/jpeg-9c/filelist.txt rename to external/jpeg-9d/filelist.txt index 583859f0..86def455 100644 --- a/external/jpeg-9c/filelist.txt +++ b/external/jpeg-9d/filelist.txt @@ -1,6 +1,6 @@ IJG JPEG LIBRARY: FILE LIST -Copyright (C) 1994-2017, Thomas G. Lane, Guido Vollbeding. +Copyright (C) 1994-2019, Thomas G. Lane, Guido Vollbeding. This file is part of the Independent JPEG Group's software. For conditions of distribution and use, see the accompanying README file. @@ -151,7 +151,7 @@ transupp.c Support code for jpegtran: lossless image manipulations. Image file reader modules for cjpeg: rdbmp.c BMP file input. -rdgif.c GIF file input (now just a stub). +rdgif.c GIF file input. rdppm.c PPM/PGM file input. rdrle.c Utah RLE file input. rdtarga.c Targa file input. @@ -159,7 +159,7 @@ rdtarga.c Targa file input. Image file writer modules for djpeg: wrbmp.c BMP file output. -wrgif.c GIF file output (a mere shadow of its former self). +wrgif.c GIF file output. wrppm.c PPM/PGM file output. wrrle.c Utah RLE file output. wrtarga.c Targa file output. diff --git a/external/jpeg-9c/install-sh b/external/jpeg-9d/install-sh similarity index 90% rename from external/jpeg-9c/install-sh rename to external/jpeg-9d/install-sh index 0360b79e..8175c640 100755 --- a/external/jpeg-9c/install-sh +++ b/external/jpeg-9d/install-sh @@ -1,7 +1,7 @@ #!/bin/sh # install - install a program, script, or datafile -scriptversion=2016-01-11.22; # UTC +scriptversion=2018-03-11.20; # UTC # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the @@ -271,15 +271,18 @@ do fi dst=$dst_arg - # If destination is a directory, append the input filename; won't work - # if double slashes aren't ignored. + # If destination is a directory, append the input filename. if test -d "$dst"; then if test "$is_target_a_directory" = never; then echo "$0: $dst_arg: Is a directory" >&2 exit 1 fi dstdir=$dst - dst=$dstdir/`basename "$src"` + dstbase=`basename "$src"` + case $dst in + */) dst=$dst$dstbase;; + *) dst=$dst/$dstbase;; + esac dstdir_status=0 else dstdir=`dirname "$dst"` @@ -288,6 +291,11 @@ do fi fi + case $dstdir in + */) dstdirslash=$dstdir;; + *) dstdirslash=$dstdir/;; + esac + obsolete_mkdir_used=false if test $dstdir_status != 0; then @@ -324,34 +332,43 @@ do # 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-$$ - trap 'ret=$?; rmdir "$tmpdir/d" "$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 && - exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 + $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. - ls_ld_tmpdir=`ls -ld "$tmpdir"` + 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 -- "$tmpdir" && { - ls_ld_tmpdir_1=`ls -ld "$tmpdir"` + $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/d" "$tmpdir" + rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" else # Remove any dirs left behind by ancient mkdir implementations. - rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null + rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null fi trap '' 0;; esac;; @@ -427,8 +444,8 @@ do else # Make a couple of temp file names in the proper directory. - dsttmp=$dstdir/_inst.$$_ - rmtmp=$dstdir/_rm.$$_ + dsttmp=${dstdirslash}_inst.$$_ + rmtmp=${dstdirslash}_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 @@ -493,7 +510,7 @@ do done # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/external/jpeg-9c/install.txt b/external/jpeg-9d/install.txt similarity index 96% rename from external/jpeg-9c/install.txt rename to external/jpeg-9d/install.txt index 10600a40..107f6c1f 100644 --- a/external/jpeg-9c/install.txt +++ b/external/jpeg-9d/install.txt @@ -1,6 +1,6 @@ INSTALLATION INSTRUCTIONS for the Independent JPEG Group's JPEG software -Copyright (C) 1991-2017, Thomas G. Lane, Guido Vollbeding. +Copyright (C) 1991-2019, Thomas G. Lane, Guido Vollbeding. This file is part of the Independent JPEG Group's software. For conditions of distribution and use, see the accompanying README file. @@ -150,8 +150,8 @@ makefile.wat jconfig.wat MS-DOS, OS/2, or Windows NT, Watcom C makefile.vc jconfig.vc Windows, MS Visual C++ makefile.vs jconfig.vc Windows, MS Visual C++ 6 Developer Studio make*.vc6 -makefile.vs jconfig.vc Windows, Visual Studio 2017 (v15) -make*.v15 +makefile.vs jconfig.vc Windows, Visual Studio 2019 (v16) +make*.v16 makefile.b32 jconfig.vc Windows, Borland C++ 32-bit (bcc32) makefile.mms jconfig.vms Digital VMS, with MMS software makefile.vms jconfig.vms Digital VMS, without MMS software @@ -1029,48 +1029,66 @@ library, we recommend building the applications so that you can run the self-test.) To use: -1. Open the command prompt, change to the main directory and execute the - command line - NMAKE /f makefile.vs setup-vc6 +1. Open the command prompt, change to the source directory and execute + the command line + NMAKE /f makefile.vs setup-vc6 + If you get an error message saying that the "NMAKE" command could + not be found, execute the command + "%ProgramFiles%\Microsoft Visual Studio\VC98\Bin\VCVARS32" + to set the environment for using Microsoft Visual C++ tools, + and repeat the NMAKE call. This will move jconfig.vc to jconfig.h and makefiles to project files. (Note that the renaming is critical!) + Alternatively you can use + NMAKE /f makefile.vs setupcopy-vc6 + This will create renamed copies of the files, which allows to repeat + the setup later. 2. Open the workspace file jpeg.dsw, build the library project. (If you are using Developer Studio more recent than 6.0, you'll probably get a message saying that the project files are being updated.) 3. Open the workspace file apps.dsw, build the application projects. 4. To perform the self-test, execute the command line - NMAKE /f makefile.vs test-build -5. Move the application .exe files from `app`\Release to an + NMAKE /f makefile.vs test-build +5. Move the application .exe files from the Release folder to an appropriate location on your path. -Microsoft Windows, Visual Studio 2017 (v15): +Microsoft Windows, Visual Studio 2019 (v16): We include makefiles that should work as project files in Visual Studio -2017 (v15) or later. There is a library makefile that builds the IJG -library as a static Win32 library, and application makefiles that build -the sample applications as Win32 console applications. (Even if you only -want the library, we recommend building the applications so that you can -run the self-test.) +2019 (v16) or later. There is a library makefile that builds the IJG +library as a static Win32/x64 library, and application makefiles that +build the sample applications as Win32/x64 console applications. (Even +if you only want the library, we recommend building the applications so +that you can run the self-test.) To use: -1. Open the Developer Command Prompt, change to the main directory and - execute the command line - NMAKE /f makefile.vs setup-v15 +1. Open the Developer Command Prompt for VS 2019, change to the source + directory and execute the command line + NMAKE /f makefile.vs setup-v16 This will move jconfig.vc to jconfig.h and makefiles to project files. (Note that the renaming is critical!) + Alternatively you can use + NMAKE /f makefile.vs setupcopy-v16 + This will create renamed copies of the files, which allows to repeat + the setup later. 2. Open the solution file jpeg.sln, build the library project. a) If you are using Visual Studio more recent than - 2017 (v15), you'll probably get a message saying + 2019 (v16), you'll probably get a message saying that the project files are being updated. b) If necessary, open the project properties and adapt the Windows Target Platform Version in the Configuration Properties, General section; we support the latest version at the time of release. + c) If you want to build x64 code, change the platform setting from + Win32 to x64. You can build Win32 and x64 versions side by side. 3. Open the solution file apps.sln, build the application projects. 4. To perform the self-test, execute the command line - NMAKE /f makefile.vs test-build -5. Move the application .exe files from `app`\Release to an + NMAKE /f makefile.vs test-32 + for the Win32 build, or on a 64-bit system + NMAKE /f makefile.vs test-64 + for the x64 build. +5. Move the application .exe files from the Release folder to an appropriate location on your path. diff --git a/external/jpeg-9c/jaricom.c b/external/jpeg-9d/jaricom.c similarity index 100% rename from external/jpeg-9c/jaricom.c rename to external/jpeg-9d/jaricom.c diff --git a/external/jpeg-9c/jcapimin.c b/external/jpeg-9d/jcapimin.c similarity index 100% rename from external/jpeg-9c/jcapimin.c rename to external/jpeg-9d/jcapimin.c diff --git a/external/jpeg-9c/jcapistd.c b/external/jpeg-9d/jcapistd.c similarity index 100% rename from external/jpeg-9c/jcapistd.c rename to external/jpeg-9d/jcapistd.c diff --git a/external/jpeg-9c/jcarith.c b/external/jpeg-9d/jcarith.c similarity index 98% rename from external/jpeg-9c/jcarith.c rename to external/jpeg-9d/jcarith.c index a64190e7..46ce6c6a 100644 --- a/external/jpeg-9c/jcarith.c +++ b/external/jpeg-9d/jcarith.c @@ -1,7 +1,7 @@ /* * jcarith.c * - * Developed 1997-2013 by Guido Vollbeding. + * Developed 1997-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -181,11 +181,11 @@ finish_pass (j_compress_ptr cinfo) if (e->zc) /* output final pending zero bytes */ do emit_byte(0x00, cinfo); while (--e->zc); - emit_byte((e->c >> 19) & 0xFF, cinfo); + emit_byte((int) ((e->c >> 19) & 0xFF), cinfo); if (((e->c >> 19) & 0xFF) == 0xFF) emit_byte(0x00, cinfo); if (e->c & 0x7F800L) { - emit_byte((e->c >> 11) & 0xFF, cinfo); + emit_byte((int) ((e->c >> 11) & 0xFF), cinfo); if (((e->c >> 11) & 0xFF) == 0xFF) emit_byte(0x00, cinfo); } @@ -280,7 +280,8 @@ arith_encode (j_compress_ptr cinfo, unsigned char *st, int val) /* Note: The 3 spacer bits in the C register guarantee * that the new buffer byte can't be 0xFF here * (see page 160 in the P&M JPEG book). */ - e->buffer = temp & 0xFF; /* new output byte, might overflow later */ + /* New output byte, might overflow later */ + e->buffer = (int) (temp & 0xFF); } else if (temp == 0xFF) { ++e->sc; /* stack 0xFF byte (which might overflow later) */ } else { @@ -302,7 +303,8 @@ arith_encode (j_compress_ptr cinfo, unsigned char *st, int val) emit_byte(0x00, cinfo); } while (--e->sc); } - e->buffer = temp & 0xFF; /* new output byte (can still overflow) */ + /* New output byte (can still overflow) */ + e->buffer = (int) (temp & 0xFF); } e->c &= 0x7FFFFL; e->ct += 8; @@ -926,9 +928,8 @@ jinit_arith_encoder (j_compress_ptr cinfo) arith_entropy_ptr entropy; int i; - entropy = (arith_entropy_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(arith_entropy_encoder)); + entropy = (arith_entropy_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(arith_entropy_encoder)); cinfo->entropy = &entropy->pub; entropy->pub.start_pass = start_pass; entropy->pub.finish_pass = finish_pass; diff --git a/external/jpeg-9c/jccoefct.c b/external/jpeg-9d/jccoefct.c similarity index 100% rename from external/jpeg-9c/jccoefct.c rename to external/jpeg-9d/jccoefct.c diff --git a/external/jpeg-9c/jccolor.c b/external/jpeg-9d/jccolor.c similarity index 91% rename from external/jpeg-9c/jccolor.c rename to external/jpeg-9d/jccolor.c index f6b4a493..db2ca429 100644 --- a/external/jpeg-9c/jccolor.c +++ b/external/jpeg-9d/jccolor.c @@ -2,7 +2,7 @@ * jccolor.c * * Copyright (C) 1991-1996, Thomas G. Lane. - * Modified 2011-2013 by Guido Vollbeding. + * Modified 2011-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -105,14 +105,14 @@ rgb_ycc_start (j_compress_ptr cinfo) /* Allocate and fill in the conversion tables. */ cconvert->rgb_ycc_tab = rgb_ycc_tab = (INT32 *) (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (TABLE_SIZE * SIZEOF(INT32))); + TABLE_SIZE * SIZEOF(INT32)); for (i = 0; i <= MAXJSAMPLE; i++) { rgb_ycc_tab[i+R_Y_OFF] = FIX(0.299) * i; rgb_ycc_tab[i+G_Y_OFF] = FIX(0.587) * i; rgb_ycc_tab[i+B_Y_OFF] = FIX(0.114) * i + ONE_HALF; - rgb_ycc_tab[i+R_CB_OFF] = (-FIX(0.168735892)) * i; - rgb_ycc_tab[i+G_CB_OFF] = (-FIX(0.331264108)) * i; + rgb_ycc_tab[i+R_CB_OFF] = (- FIX(0.168735892)) * i; + rgb_ycc_tab[i+G_CB_OFF] = (- FIX(0.331264108)) * i; /* We use a rounding fudge-factor of 0.5-epsilon for Cb and Cr. * This ensures that the maximum output will round to MAXJSAMPLE * not MAXJSAMPLE+1, and thus that we don't have to range-limit. @@ -121,8 +121,8 @@ rgb_ycc_start (j_compress_ptr cinfo) /* B=>Cb and R=>Cr tables are the same rgb_ycc_tab[i+R_CR_OFF] = FIX(0.5) * i + CBCR_OFFSET + ONE_HALF-1; */ - rgb_ycc_tab[i+G_CR_OFF] = (-FIX(0.418687589)) * i; - rgb_ycc_tab[i+B_CR_OFF] = (-FIX(0.081312411)) * i; + rgb_ycc_tab[i+G_CR_OFF] = (- FIX(0.418687589)) * i; + rgb_ycc_tab[i+B_CR_OFF] = (- FIX(0.081312411)) * i; } } @@ -131,12 +131,12 @@ rgb_ycc_start (j_compress_ptr cinfo) * Convert some rows of samples to the JPEG colorspace. * * Note that we change from the application's interleaved-pixel format - * to our internal noninterleaved, one-plane-per-component format. - * The input buffer is therefore three times as wide as the output buffer. + * to our internal noninterleaved, one-plane-per-component format. The + * input buffer is therefore three times as wide as the output buffer. * - * A starting row offset is provided only for the output buffer. The caller - * can easily adjust the passed input_buf value to accommodate any row - * offset required on that side. + * A starting row offset is provided only for the output buffer. The + * caller can easily adjust the passed input_buf value to accommodate + * any row offset required on that side. */ METHODDEF(void) @@ -145,8 +145,8 @@ rgb_ycc_convert (j_compress_ptr cinfo, JDIMENSION output_row, int num_rows) { my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert; - register INT32 * ctab = cconvert->rgb_ycc_tab; register int r, g, b; + register INT32 * ctab = cconvert->rgb_ycc_tab; register JSAMPROW inptr; register JSAMPROW outptr0, outptr1, outptr2; register JDIMENSION col; @@ -162,6 +162,7 @@ rgb_ycc_convert (j_compress_ptr cinfo, r = GETJSAMPLE(inptr[RGB_RED]); g = GETJSAMPLE(inptr[RGB_GREEN]); b = GETJSAMPLE(inptr[RGB_BLUE]); + inptr += RGB_PIXELSIZE; /* If the inputs are 0..MAXJSAMPLE, the outputs of these equations * must be too; we do not need an explicit range-limiting operation. * Hence the value being shifted is never negative, and we don't @@ -179,7 +180,6 @@ rgb_ycc_convert (j_compress_ptr cinfo, outptr2[col] = (JSAMPLE) ((ctab[r+R_CR_OFF] + ctab[g+G_CR_OFF] + ctab[b+B_CR_OFF]) >> SCALEBITS); - inptr += RGB_PIXELSIZE; } } } @@ -201,8 +201,8 @@ rgb_gray_convert (j_compress_ptr cinfo, JDIMENSION output_row, int num_rows) { my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert; - register INT32 * ctab = cconvert->rgb_ycc_tab; register int r, g, b; + register INT32 * ctab = cconvert->rgb_ycc_tab; register JSAMPROW inptr; register JSAMPROW outptr; register JDIMENSION col; @@ -215,11 +215,11 @@ rgb_gray_convert (j_compress_ptr cinfo, r = GETJSAMPLE(inptr[RGB_RED]); g = GETJSAMPLE(inptr[RGB_GREEN]); b = GETJSAMPLE(inptr[RGB_BLUE]); + inptr += RGB_PIXELSIZE; /* Y */ outptr[col] = (JSAMPLE) ((ctab[r+R_Y_OFF] + ctab[g+G_Y_OFF] + ctab[b+B_Y_OFF]) >> SCALEBITS); - inptr += RGB_PIXELSIZE; } } } @@ -228,8 +228,8 @@ rgb_gray_convert (j_compress_ptr cinfo, /* * Convert some rows of samples to the JPEG colorspace. * This version handles Adobe-style CMYK->YCCK conversion, - * where we convert R=1-C, G=1-M, and B=1-Y to YCbCr using the same - * conversion as above, while passing K (black) unchanged. + * where we convert R=1-C, G=1-M, and B=1-Y to YCbCr using the + * same conversion as above, while passing K (black) unchanged. * We assume rgb_ycc_start has been called. */ @@ -239,8 +239,8 @@ cmyk_ycck_convert (j_compress_ptr cinfo, JDIMENSION output_row, int num_rows) { my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert; - register INT32 * ctab = cconvert->rgb_ycc_tab; register int r, g, b; + register INT32 * ctab = cconvert->rgb_ycc_tab; register JSAMPROW inptr; register JSAMPROW outptr0, outptr1, outptr2, outptr3; register JDIMENSION col; @@ -259,6 +259,7 @@ cmyk_ycck_convert (j_compress_ptr cinfo, b = MAXJSAMPLE - GETJSAMPLE(inptr[2]); /* K passes through as-is */ outptr3[col] = inptr[3]; /* don't need GETJSAMPLE here */ + inptr += 4; /* If the inputs are 0..MAXJSAMPLE, the outputs of these equations * must be too; we do not need an explicit range-limiting operation. * Hence the value being shifted is never negative, and we don't @@ -276,7 +277,6 @@ cmyk_ycck_convert (j_compress_ptr cinfo, outptr2[col] = (JSAMPLE) ((ctab[r+R_CR_OFF] + ctab[g+G_CR_OFF] + ctab[b+B_CR_OFF]) >> SCALEBITS); - inptr += 4; } } } @@ -312,13 +312,13 @@ rgb_rgb1_convert (j_compress_ptr cinfo, r = GETJSAMPLE(inptr[RGB_RED]); g = GETJSAMPLE(inptr[RGB_GREEN]); b = GETJSAMPLE(inptr[RGB_BLUE]); + inptr += RGB_PIXELSIZE; /* Assume that MAXJSAMPLE+1 is a power of 2, so that the MOD * (modulo) operator is equivalent to the bitmask operator AND. */ outptr0[col] = (JSAMPLE) ((r - g + CENTERJSAMPLE) & MAXJSAMPLE); outptr1[col] = (JSAMPLE) g; outptr2[col] = (JSAMPLE) ((b - g + CENTERJSAMPLE) & MAXJSAMPLE); - inptr += RGB_PIXELSIZE; } } } @@ -335,17 +335,17 @@ grayscale_convert (j_compress_ptr cinfo, JSAMPARRAY input_buf, JSAMPIMAGE output_buf, JDIMENSION output_row, int num_rows) { - int instride = cinfo->input_components; register JSAMPROW inptr; register JSAMPROW outptr; - register JDIMENSION col; + register JDIMENSION count; + register int instride = cinfo->input_components; JDIMENSION num_cols = cinfo->image_width; while (--num_rows >= 0) { inptr = *input_buf++; outptr = output_buf[0][output_row++]; - for (col = 0; col < num_cols; col++) { - outptr[col] = inptr[0]; /* don't need GETJSAMPLE() here */ + for (count = num_cols; count > 0; count--) { + *outptr++ = *inptr; /* don't need GETJSAMPLE() here */ inptr += instride; } } @@ -396,21 +396,21 @@ null_convert (j_compress_ptr cinfo, JSAMPARRAY input_buf, JSAMPIMAGE output_buf, JDIMENSION output_row, int num_rows) { - int ci; - register int nc = cinfo->num_components; register JSAMPROW inptr; register JSAMPROW outptr; - register JDIMENSION col; + register JDIMENSION count; + register int num_comps = cinfo->num_components; JDIMENSION num_cols = cinfo->image_width; + int ci; while (--num_rows >= 0) { /* It seems fastest to make a separate pass for each component. */ - for (ci = 0; ci < nc; ci++) { + for (ci = 0; ci < num_comps; ci++) { inptr = input_buf[0] + ci; outptr = output_buf[ci][output_row]; - for (col = 0; col < num_cols; col++) { + for (count = num_cols; count > 0; count--) { *outptr++ = *inptr; /* don't need GETJSAMPLE() here */ - inptr += nc; + inptr += num_comps; } } input_buf++; @@ -439,9 +439,8 @@ jinit_color_converter (j_compress_ptr cinfo) { my_cconvert_ptr cconvert; - cconvert = (my_cconvert_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(my_color_converter)); + cconvert = (my_cconvert_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(my_color_converter)); cinfo->cconvert = &cconvert->pub; /* set start_pass to null method until we find out differently */ cconvert->pub.start_pass = null_method; @@ -455,9 +454,11 @@ jinit_color_converter (j_compress_ptr cinfo) case JCS_RGB: case JCS_BG_RGB: +#if RGB_PIXELSIZE != 3 if (cinfo->input_components != RGB_PIXELSIZE) ERREXIT(cinfo, JERR_BAD_IN_COLORSPACE); break; +#endif /* else share code with YCbCr */ case JCS_YCbCr: case JCS_BG_YCC: @@ -474,7 +475,6 @@ jinit_color_converter (j_compress_ptr cinfo) default: /* JCS_UNKNOWN can be anything */ if (cinfo->input_components < 1) ERREXIT(cinfo, JERR_BAD_IN_COLORSPACE); - break; } /* Support color transform only for RGB colorspaces */ @@ -507,19 +507,18 @@ jinit_color_converter (j_compress_ptr cinfo) case JCS_BG_RGB: if (cinfo->num_components != 3) ERREXIT(cinfo, JERR_BAD_J_COLORSPACE); - if (cinfo->in_color_space == cinfo->jpeg_color_space) { - switch (cinfo->color_transform) { - case JCT_NONE: - cconvert->pub.color_convert = rgb_convert; - break; - case JCT_SUBTRACT_GREEN: - cconvert->pub.color_convert = rgb_rgb1_convert; - break; - default: - ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); - } - } else + if (cinfo->in_color_space != cinfo->jpeg_color_space) ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); + switch (cinfo->color_transform) { + case JCT_NONE: + cconvert->pub.color_convert = rgb_convert; + break; + case JCT_SUBTRACT_GREEN: + cconvert->pub.color_convert = rgb_rgb1_convert; + break; + default: + ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); + } break; case JCS_YCbCr: @@ -572,10 +571,9 @@ jinit_color_converter (j_compress_ptr cinfo) case JCS_CMYK: if (cinfo->num_components != 4) ERREXIT(cinfo, JERR_BAD_J_COLORSPACE); - if (cinfo->in_color_space == JCS_CMYK) - cconvert->pub.color_convert = null_convert; - else + if (cinfo->in_color_space != JCS_CMYK) ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); + cconvert->pub.color_convert = null_convert; break; case JCS_YCCK: @@ -599,6 +597,5 @@ jinit_color_converter (j_compress_ptr cinfo) cinfo->num_components != cinfo->input_components) ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); cconvert->pub.color_convert = null_convert; - break; } } diff --git a/external/jpeg-9c/jcdctmgr.c b/external/jpeg-9d/jcdctmgr.c similarity index 100% rename from external/jpeg-9c/jcdctmgr.c rename to external/jpeg-9d/jcdctmgr.c diff --git a/external/jpeg-9c/jchuff.c b/external/jpeg-9d/jchuff.c similarity index 93% rename from external/jpeg-9c/jchuff.c rename to external/jpeg-9d/jchuff.c index d1313f67..02fc275b 100644 --- a/external/jpeg-9c/jchuff.c +++ b/external/jpeg-9d/jchuff.c @@ -2,7 +2,7 @@ * jchuff.c * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2006-2013 by Guido Vollbeding. + * Modified 2006-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -178,13 +178,12 @@ jpeg_make_c_derived_tbl (j_compress_ptr cinfo, boolean isDC, int tblno, htbl = isDC ? cinfo->dc_huff_tbl_ptrs[tblno] : cinfo->ac_huff_tbl_ptrs[tblno]; if (htbl == NULL) - ERREXIT1(cinfo, JERR_NO_HUFF_TABLE, tblno); + htbl = jpeg_std_huff_table((j_common_ptr) cinfo, isDC, tblno); /* Allocate a workspace if we haven't already done so. */ if (*pdtbl == NULL) - *pdtbl = (c_derived_tbl *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(c_derived_tbl)); + *pdtbl = (c_derived_tbl *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(c_derived_tbl)); dtbl = *pdtbl; /* Figure C.1: make table of Huffman code length for each symbol */ @@ -1256,22 +1255,88 @@ jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[]) UINT8 bits[MAX_CLEN+1]; /* bits[k] = # of symbols with code length k */ int codesize[257]; /* codesize[k] = code length of symbol k */ int others[257]; /* next symbol in current branch of tree */ - int c1, c2; - int p, i, j; + int c1, c2, i, j; + UINT8 *p; long v; + freq[256] = 1; /* make sure 256 has a nonzero count */ + /* Including the pseudo-symbol 256 in the Huffman procedure guarantees + * that no real symbol is given code-value of all ones, because 256 + * will be placed last in the largest codeword category. + * In the symbol list build procedure this element serves as sentinel + * for the zero run loop. + */ + +#ifndef DONT_USE_FANCY_HUFF_OPT + + /* Build list of symbols sorted in order of descending frequency */ + /* This approach has several benefits (thank to John Korejwa for the idea): + * 1. + * If a codelength category is split during the length limiting procedure + * below, the feature that more frequent symbols are assigned shorter + * codewords remains valid for the adjusted code. + * 2. + * To reduce consecutive ones in a Huffman data stream (thus reducing the + * number of stuff bytes in JPEG) it is preferable to follow 0 branches + * (and avoid 1 branches) as much as possible. This is easily done by + * assigning symbols to leaves of the Huffman tree in order of decreasing + * frequency, with no secondary sort based on codelengths. + * 3. + * The symbol list can be built independently from the assignment of code + * lengths by the Huffman procedure below. + * Note: The symbol list build procedure must be performed first, because + * the Huffman procedure assigning the codelengths clobbers the frequency + * counts! + */ + + /* Here we use the others array as a linked list of nonzero frequencies + * to be sorted. Already sorted elements are removed from the list. + */ + + /* Building list */ + + /* This item does not correspond to a valid symbol frequency and is used + * as starting index. + */ + j = 256; + + for (i = 0;; i++) { + if (freq[i] == 0) /* skip zero frequencies */ + continue; + if (i > 255) + break; + others[j] = i; /* this symbol value */ + j = i; /* previous symbol value */ + } + others[j] = -1; /* mark end of list */ + + /* Sorting list */ + + p = htbl->huffval; + while ((c1 = others[256]) >= 0) { + v = freq[c1]; + i = c1; /* first symbol value */ + j = 256; /* pseudo symbol value for starting index */ + while ((c2 = others[c1]) >= 0) { + if (freq[c2] > v) { + v = freq[c2]; + i = c2; /* this symbol value */ + j = c1; /* previous symbol value */ + } + c1 = c2; + } + others[j] = others[i]; /* remove this symbol i from list */ + *p++ = (UINT8) i; + } + +#endif /* DONT_USE_FANCY_HUFF_OPT */ + /* This algorithm is explained in section K.2 of the JPEG standard */ MEMZERO(bits, SIZEOF(bits)); MEMZERO(codesize, SIZEOF(codesize)); for (i = 0; i < 257; i++) others[i] = -1; /* init links to empty */ - - freq[256] = 1; /* make sure 256 has a nonzero count */ - /* Including the pseudo-symbol 256 in the Huffman procedure guarantees - * that no real symbol is given code-value of all ones, because 256 - * will be placed last in the largest codeword category. - */ /* Huffman's basic algorithm to assign optimal code lengths to symbols */ @@ -1301,7 +1366,7 @@ jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[]) /* Done if we've merged everything into one frequency */ if (c2 < 0) break; - + /* Else merge the two counts/trees */ freq[c1] += freq[c2]; freq[c2] = 0; @@ -1312,9 +1377,9 @@ jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[]) c1 = others[c1]; codesize[c1]++; } - + others[c1] = c2; /* chain c2 onto c1's tree branch */ - + /* Increment the codesize of everything in c2's tree branch */ codesize[c2]++; while (others[c2] >= 0) { @@ -1329,7 +1394,7 @@ jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[]) /* The JPEG standard seems to think that this can't happen, */ /* but I'm paranoid... */ if (codesize[i] > MAX_CLEN) - ERREXIT(cinfo, JERR_HUFF_CLEN_OVERFLOW); + ERREXIT(cinfo, JERR_HUFF_CLEN_OUTOFBOUNDS); bits[codesize[i]]++; } @@ -1345,13 +1410,16 @@ jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[]) * shortest nonzero BITS entry is converted into a prefix for two code words * one bit longer. */ - + for (i = MAX_CLEN; i > 16; i--) { while (bits[i] > 0) { j = i - 2; /* find length of new prefix to be used */ - while (bits[j] == 0) + while (bits[j] == 0) { + if (j == 0) + ERREXIT(cinfo, JERR_HUFF_CLEN_OUTOFBOUNDS); j--; - + } + bits[i] -= 2; /* remove two symbols */ bits[i-1]++; /* one goes in this length */ bits[j+1] += 2; /* two new symbols in this length */ @@ -1363,24 +1431,27 @@ jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[]) while (bits[i] == 0) /* find largest codelength still in use */ i--; bits[i]--; - + /* Return final symbol counts (only for lengths 0..16) */ MEMCOPY(htbl->bits, bits, SIZEOF(htbl->bits)); - + +#ifdef DONT_USE_FANCY_HUFF_OPT + /* Return a list of the symbols sorted by code length */ - /* It's not real clear to me why we don't need to consider the codelength - * changes made above, but the JPEG spec seems to think this works. + /* Note: Due to the codelength changes made above, it can happen + * that more frequent symbols are assigned longer codewords. */ - p = 0; + p = htbl->huffval; for (i = 1; i <= MAX_CLEN; i++) { for (j = 0; j <= 255; j++) { if (codesize[j] == i) { - htbl->huffval[p] = (UINT8) j; - p++; + *p++ = (UINT8) j; } } } +#endif /* DONT_USE_FANCY_HUFF_OPT */ + /* Set sent_table FALSE so updated table will be written to JPEG file. */ htbl->sent_table = FALSE; } @@ -1400,13 +1471,13 @@ finish_pass_gather (j_compress_ptr cinfo) boolean did_dc[NUM_HUFF_TBLS]; boolean did_ac[NUM_HUFF_TBLS]; - /* It's important not to apply jpeg_gen_optimal_table more than once - * per table, because it clobbers the input frequency counts! - */ if (cinfo->progressive_mode) /* Flush out buffered data (all we care about is counting the EOB symbol) */ emit_eobrun(entropy); + /* It's important not to apply jpeg_gen_optimal_table more than once + * per table, because it clobbers the input frequency counts! + */ MEMZERO(did_dc, SIZEOF(did_dc)); MEMZERO(did_ac, SIZEOF(did_ac)); @@ -1475,9 +1546,8 @@ start_pass_huff (j_compress_ptr cinfo, boolean gather_statistics) entropy->pub.encode_mcu = encode_mcu_AC_refine; /* AC refinement needs a correction bit buffer */ if (entropy->bit_buffer == NULL) - entropy->bit_buffer = (char *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - MAX_CORR_BITS * SIZEOF(char)); + entropy->bit_buffer = (char *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, MAX_CORR_BITS * SIZEOF(char)); } } @@ -1505,9 +1575,8 @@ start_pass_huff (j_compress_ptr cinfo, boolean gather_statistics) /* Allocate and zero the statistics tables */ /* Note that jpeg_gen_optimal_table expects 257 entries in each table! */ if (entropy->dc_count_ptrs[tbl] == NULL) - entropy->dc_count_ptrs[tbl] = (long *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - 257 * SIZEOF(long)); + entropy->dc_count_ptrs[tbl] = (long *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, 257 * SIZEOF(long)); MEMZERO(entropy->dc_count_ptrs[tbl], 257 * SIZEOF(long)); } else { /* Compute derived values for Huffman tables */ @@ -1525,9 +1594,8 @@ start_pass_huff (j_compress_ptr cinfo, boolean gather_statistics) if (tbl < 0 || tbl >= NUM_HUFF_TBLS) ERREXIT1(cinfo, JERR_NO_HUFF_TABLE, tbl); if (entropy->ac_count_ptrs[tbl] == NULL) - entropy->ac_count_ptrs[tbl] = (long *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - 257 * SIZEOF(long)); + entropy->ac_count_ptrs[tbl] = (long *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, 257 * SIZEOF(long)); MEMZERO(entropy->ac_count_ptrs[tbl], 257 * SIZEOF(long)); } else { jpeg_make_c_derived_tbl(cinfo, FALSE, tbl, @@ -1556,9 +1624,8 @@ jinit_huff_encoder (j_compress_ptr cinfo) huff_entropy_ptr entropy; int i; - entropy = (huff_entropy_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(huff_entropy_encoder)); + entropy = (huff_entropy_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(huff_entropy_encoder)); cinfo->entropy = &entropy->pub; entropy->pub.start_pass = start_pass_huff; diff --git a/external/jpeg-9c/jcinit.c b/external/jpeg-9d/jcinit.c similarity index 100% rename from external/jpeg-9c/jcinit.c rename to external/jpeg-9d/jcinit.c diff --git a/external/jpeg-9c/jcmainct.c b/external/jpeg-9d/jcmainct.c similarity index 100% rename from external/jpeg-9c/jcmainct.c rename to external/jpeg-9d/jcmainct.c diff --git a/external/jpeg-9c/jcmarker.c b/external/jpeg-9d/jcmarker.c similarity index 99% rename from external/jpeg-9c/jcmarker.c rename to external/jpeg-9d/jcmarker.c index ca2bb399..8874cd86 100644 --- a/external/jpeg-9c/jcmarker.c +++ b/external/jpeg-9d/jcmarker.c @@ -2,7 +2,7 @@ * jcmarker.c * * Copyright (C) 1991-1998, Thomas G. Lane. - * Modified 2003-2013 by Guido Vollbeding. + * Modified 2003-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -471,7 +471,6 @@ emit_adobe_app14 (j_compress_ptr cinfo) break; default: emit_byte(cinfo, 0); /* Color transform = 0 */ - break; } } @@ -702,9 +701,8 @@ jinit_marker_writer (j_compress_ptr cinfo) my_marker_ptr marker; /* Create the subobject */ - marker = (my_marker_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(my_marker_writer)); + marker = (my_marker_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(my_marker_writer)); cinfo->marker = &marker->pub; /* Initialize method pointers */ marker->pub.write_file_header = write_file_header; diff --git a/external/jpeg-9c/jcmaster.c b/external/jpeg-9d/jcmaster.c similarity index 96% rename from external/jpeg-9c/jcmaster.c rename to external/jpeg-9d/jcmaster.c index 43d49aec..89dcf78c 100644 --- a/external/jpeg-9c/jcmaster.c +++ b/external/jpeg-9d/jcmaster.c @@ -2,7 +2,7 @@ * jcmaster.c * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2003-2017 by Guido Vollbeding. + * Modified 2003-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -62,7 +62,7 @@ initial_setup (j_compress_ptr cinfo) case 5: cinfo->natural_order = jpeg_natural_order5; break; case 6: cinfo->natural_order = jpeg_natural_order6; break; case 7: cinfo->natural_order = jpeg_natural_order7; break; - default: cinfo->natural_order = jpeg_natural_order; break; + default: cinfo->natural_order = jpeg_natural_order; } /* Derive lim_Se from block_size */ @@ -114,20 +114,24 @@ initial_setup (j_compress_ptr cinfo) */ ssize = 1; #ifdef DCT_SCALING_SUPPORTED - while (cinfo->min_DCT_h_scaled_size * ssize <= - (cinfo->do_fancy_downsampling ? DCTSIZE : DCTSIZE / 2) && - (cinfo->max_h_samp_factor % (compptr->h_samp_factor * ssize * 2)) == 0) { - ssize = ssize * 2; - } + if (! cinfo->raw_data_in) + while (cinfo->min_DCT_h_scaled_size * ssize <= + (cinfo->do_fancy_downsampling ? DCTSIZE : DCTSIZE / 2) && + (cinfo->max_h_samp_factor % (compptr->h_samp_factor * ssize * 2)) == + 0) { + ssize = ssize * 2; + } #endif compptr->DCT_h_scaled_size = cinfo->min_DCT_h_scaled_size * ssize; ssize = 1; #ifdef DCT_SCALING_SUPPORTED - while (cinfo->min_DCT_v_scaled_size * ssize <= - (cinfo->do_fancy_downsampling ? DCTSIZE : DCTSIZE / 2) && - (cinfo->max_v_samp_factor % (compptr->v_samp_factor * ssize * 2)) == 0) { - ssize = ssize * 2; - } + if (! cinfo->raw_data_in) + while (cinfo->min_DCT_v_scaled_size * ssize <= + (cinfo->do_fancy_downsampling ? DCTSIZE : DCTSIZE / 2) && + (cinfo->max_v_samp_factor % (compptr->v_samp_factor * ssize * 2)) == + 0) { + ssize = ssize * 2; + } #endif compptr->DCT_v_scaled_size = cinfo->min_DCT_v_scaled_size * ssize; @@ -620,9 +624,8 @@ jinit_c_master_control (j_compress_ptr cinfo, boolean transcode_only) { my_master_ptr master; - master = (my_master_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(my_comp_master)); + master = (my_master_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(my_comp_master)); cinfo->master = &master->pub; master->pub.prepare_for_pass = prepare_for_pass; master->pub.pass_startup = pass_startup; diff --git a/external/jpeg-9d/jcomapi.c b/external/jpeg-9d/jcomapi.c new file mode 100644 index 00000000..678c5d12 --- /dev/null +++ b/external/jpeg-9d/jcomapi.c @@ -0,0 +1,244 @@ +/* + * jcomapi.c + * + * Copyright (C) 1994-1997, Thomas G. Lane. + * Modified 2019 by Guido Vollbeding. + * This file is part of the Independent JPEG Group's software. + * For conditions of distribution and use, see the accompanying README file. + * + * This file contains application interface routines that are used for both + * compression and decompression. + */ + +#define JPEG_INTERNALS +#include "jinclude.h" +#include "jpeglib.h" + + +/* + * Abort processing of a JPEG compression or decompression operation, + * but don't destroy the object itself. + * + * For this, we merely clean up all the nonpermanent memory pools. + * Note that temp files (virtual arrays) are not allowed to belong to + * the permanent pool, so we will be able to close all temp files here. + * Closing a data source or destination, if necessary, is the application's + * responsibility. + */ + +GLOBAL(void) +jpeg_abort (j_common_ptr cinfo) +{ + int pool; + + /* Do nothing if called on a not-initialized or destroyed JPEG object. */ + if (cinfo->mem == NULL) + return; + + /* Releasing pools in reverse order might help avoid fragmentation + * with some (brain-damaged) malloc libraries. + */ + for (pool = JPOOL_NUMPOOLS-1; pool > JPOOL_PERMANENT; pool--) { + (*cinfo->mem->free_pool) (cinfo, pool); + } + + /* Reset overall state for possible reuse of object */ + if (cinfo->is_decompressor) { + cinfo->global_state = DSTATE_START; + /* Try to keep application from accessing now-deleted marker list. + * A bit kludgy to do it here, but this is the most central place. + */ + ((j_decompress_ptr) cinfo)->marker_list = NULL; + } else { + cinfo->global_state = CSTATE_START; + } +} + + +/* + * Destruction of a JPEG object. + * + * Everything gets deallocated except the master jpeg_compress_struct itself + * and the error manager struct. Both of these are supplied by the application + * and must be freed, if necessary, by the application. (Often they are on + * the stack and so don't need to be freed anyway.) + * Closing a data source or destination, if necessary, is the application's + * responsibility. + */ + +GLOBAL(void) +jpeg_destroy (j_common_ptr cinfo) +{ + /* We need only tell the memory manager to release everything. */ + /* NB: mem pointer is NULL if memory mgr failed to initialize. */ + if (cinfo->mem != NULL) + (*cinfo->mem->self_destruct) (cinfo); + cinfo->mem = NULL; /* be safe if jpeg_destroy is called twice */ + cinfo->global_state = 0; /* mark it destroyed */ +} + + +/* + * Convenience routines for allocating quantization and Huffman tables. + * (Would jutils.c be a more reasonable place to put these?) + */ + +GLOBAL(JQUANT_TBL *) +jpeg_alloc_quant_table (j_common_ptr cinfo) +{ + JQUANT_TBL *tbl; + + tbl = (JQUANT_TBL *) + (*cinfo->mem->alloc_small) (cinfo, JPOOL_PERMANENT, SIZEOF(JQUANT_TBL)); + tbl->sent_table = FALSE; /* make sure this is false in any new table */ + return tbl; +} + + +GLOBAL(JHUFF_TBL *) +jpeg_alloc_huff_table (j_common_ptr cinfo) +{ + JHUFF_TBL *tbl; + + tbl = (JHUFF_TBL *) + (*cinfo->mem->alloc_small) (cinfo, JPOOL_PERMANENT, SIZEOF(JHUFF_TBL)); + tbl->sent_table = FALSE; /* make sure this is false in any new table */ + return tbl; +} + + +/* + * Set up the standard Huffman tables (cf. JPEG standard section K.3). + * IMPORTANT: these are only valid for 8-bit data precision! + * (Would jutils.c be a more reasonable place to put this?) + */ + +GLOBAL(JHUFF_TBL *) +jpeg_std_huff_table (j_common_ptr cinfo, boolean isDC, int tblno) +{ + JHUFF_TBL **htblptr, *htbl; + const UINT8 *bits, *val; + int nsymbols, len; + + static const UINT8 bits_dc_luminance[17] = + { /* 0-base */ 0, 0, 1, 5, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0 }; + static const UINT8 val_dc_luminance[] = + { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 }; + + static const UINT8 bits_dc_chrominance[17] = + { /* 0-base */ 0, 0, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0 }; + static const UINT8 val_dc_chrominance[] = + { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 }; + + static const UINT8 bits_ac_luminance[17] = + { /* 0-base */ 0, 0, 2, 1, 3, 3, 2, 4, 3, 5, 5, 4, 4, 0, 0, 1, 0x7d }; + static const UINT8 val_ac_luminance[] = + { 0x01, 0x02, 0x03, 0x00, 0x04, 0x11, 0x05, 0x12, + 0x21, 0x31, 0x41, 0x06, 0x13, 0x51, 0x61, 0x07, + 0x22, 0x71, 0x14, 0x32, 0x81, 0x91, 0xa1, 0x08, + 0x23, 0x42, 0xb1, 0xc1, 0x15, 0x52, 0xd1, 0xf0, + 0x24, 0x33, 0x62, 0x72, 0x82, 0x09, 0x0a, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, + 0x3a, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, + 0x4a, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, + 0x7a, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, + 0x8a, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, 0x98, + 0x99, 0x9a, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, + 0xb7, 0xb8, 0xb9, 0xba, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xd2, 0xd3, 0xd4, + 0xd5, 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xe1, 0xe2, + 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, 0xe8, 0xe9, 0xea, + 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, 0xf8, + 0xf9, 0xfa }; + + static const UINT8 bits_ac_chrominance[17] = + { /* 0-base */ 0, 0, 2, 1, 2, 4, 4, 3, 4, 7, 5, 4, 4, 0, 1, 2, 0x77 }; + static const UINT8 val_ac_chrominance[] = + { 0x00, 0x01, 0x02, 0x03, 0x11, 0x04, 0x05, 0x21, + 0x31, 0x06, 0x12, 0x41, 0x51, 0x07, 0x61, 0x71, + 0x13, 0x22, 0x32, 0x81, 0x08, 0x14, 0x42, 0x91, + 0xa1, 0xb1, 0xc1, 0x09, 0x23, 0x33, 0x52, 0xf0, + 0x15, 0x62, 0x72, 0xd1, 0x0a, 0x16, 0x24, 0x34, + 0xe1, 0x25, 0xf1, 0x17, 0x18, 0x19, 0x1a, 0x26, + 0x27, 0x28, 0x29, 0x2a, 0x35, 0x36, 0x37, 0x38, + 0x39, 0x3a, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4a, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, + 0x59, 0x5a, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, + 0x69, 0x6a, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, + 0x79, 0x7a, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x8a, 0x92, 0x93, 0x94, 0x95, 0x96, + 0x97, 0x98, 0x99, 0x9a, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xb2, 0xb3, 0xb4, + 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xc2, 0xc3, + 0xc4, 0xc5, 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xd2, + 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, 0xd8, 0xd9, 0xda, + 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, 0xe8, 0xe9, + 0xea, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, 0xf8, + 0xf9, 0xfa }; + + if (cinfo->is_decompressor) { + if (isDC) + htblptr = ((j_decompress_ptr) cinfo)->dc_huff_tbl_ptrs; + else + htblptr = ((j_decompress_ptr) cinfo)->ac_huff_tbl_ptrs; + } else { + if (isDC) + htblptr = ((j_compress_ptr) cinfo)->dc_huff_tbl_ptrs; + else + htblptr = ((j_compress_ptr) cinfo)->ac_huff_tbl_ptrs; + } + + switch (tblno) { + case 0: + if (isDC) { + bits = bits_dc_luminance; + val = val_dc_luminance; + } else { + bits = bits_ac_luminance; + val = val_ac_luminance; + } + break; + case 1: + if (isDC) { + bits = bits_dc_chrominance; + val = val_dc_chrominance; + } else { + bits = bits_ac_chrominance; + val = val_ac_chrominance; + } + break; + default: + ERREXIT1(cinfo, JERR_NO_HUFF_TABLE, tblno); + return NULL; /* avoid compiler warnings for uninitialized variables */ + } + + if (htblptr[tblno] == NULL) + htblptr[tblno] = jpeg_alloc_huff_table(cinfo); + + htbl = htblptr[tblno]; + + /* Copy the number-of-symbols-of-each-code-length counts */ + MEMCOPY(htbl->bits, bits, SIZEOF(htbl->bits)); + + /* Validate the counts. We do this here mainly so we can copy the right + * number of symbols from the val[] array, without risking marching off + * the end of memory. jxhuff.c will do a more thorough test later. + */ + nsymbols = 0; + for (len = 1; len <= 16; len++) + nsymbols += bits[len]; + if (nsymbols > 256) + ERREXIT(cinfo, JERR_BAD_HUFF_TABLE); + + if (nsymbols > 0) + MEMCOPY(htbl->huffval, val, nsymbols * SIZEOF(UINT8)); + + /* Initialize sent_table FALSE so table will be written to JPEG file. */ + htbl->sent_table = FALSE; + + return htbl; +} diff --git a/external/jpeg-9c/jconfig.bcc b/external/jpeg-9d/jconfig.bcc similarity index 100% rename from external/jpeg-9c/jconfig.bcc rename to external/jpeg-9d/jconfig.bcc diff --git a/external/jpeg-9c/jconfig.cfg b/external/jpeg-9d/jconfig.cfg similarity index 100% rename from external/jpeg-9c/jconfig.cfg rename to external/jpeg-9d/jconfig.cfg diff --git a/external/jpeg-9c/jconfig.dj b/external/jpeg-9d/jconfig.dj similarity index 100% rename from external/jpeg-9c/jconfig.dj rename to external/jpeg-9d/jconfig.dj diff --git a/external/jpeg-9c/jconfig.h b/external/jpeg-9d/jconfig.h similarity index 100% rename from external/jpeg-9c/jconfig.h rename to external/jpeg-9d/jconfig.h diff --git a/external/jpeg-9c/jconfig.mac b/external/jpeg-9d/jconfig.mac similarity index 100% rename from external/jpeg-9c/jconfig.mac rename to external/jpeg-9d/jconfig.mac diff --git a/external/jpeg-9c/jconfig.manx b/external/jpeg-9d/jconfig.manx similarity index 100% rename from external/jpeg-9c/jconfig.manx rename to external/jpeg-9d/jconfig.manx diff --git a/external/jpeg-9c/jconfig.mc6 b/external/jpeg-9d/jconfig.mc6 similarity index 100% rename from external/jpeg-9c/jconfig.mc6 rename to external/jpeg-9d/jconfig.mc6 diff --git a/external/jpeg-9c/jconfig.sas b/external/jpeg-9d/jconfig.sas similarity index 100% rename from external/jpeg-9c/jconfig.sas rename to external/jpeg-9d/jconfig.sas diff --git a/external/jpeg-9c/jconfig.st b/external/jpeg-9d/jconfig.st similarity index 100% rename from external/jpeg-9c/jconfig.st rename to external/jpeg-9d/jconfig.st diff --git a/external/jpeg-9c/jconfig.txt b/external/jpeg-9d/jconfig.txt similarity index 100% rename from external/jpeg-9c/jconfig.txt rename to external/jpeg-9d/jconfig.txt diff --git a/external/jpeg-9c/jconfig.vc b/external/jpeg-9d/jconfig.vc similarity index 100% rename from external/jpeg-9c/jconfig.vc rename to external/jpeg-9d/jconfig.vc diff --git a/external/jpeg-9c/jconfig.vms b/external/jpeg-9d/jconfig.vms similarity index 100% rename from external/jpeg-9c/jconfig.vms rename to external/jpeg-9d/jconfig.vms diff --git a/external/jpeg-9c/jconfig.wat b/external/jpeg-9d/jconfig.wat similarity index 100% rename from external/jpeg-9c/jconfig.wat rename to external/jpeg-9d/jconfig.wat diff --git a/external/jpeg-9c/jcparam.c b/external/jpeg-9d/jcparam.c similarity index 81% rename from external/jpeg-9c/jcparam.c rename to external/jpeg-9d/jcparam.c index 4b2bee24..3b7014ff 100644 --- a/external/jpeg-9c/jcparam.c +++ b/external/jpeg-9d/jcparam.c @@ -2,7 +2,7 @@ * jcparam.c * * Copyright (C) 1991-1998, Thomas G. Lane. - * Modified 2003-2013 by Guido Vollbeding. + * Modified 2003-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -162,112 +162,23 @@ jpeg_set_quality (j_compress_ptr cinfo, int quality, boolean force_baseline) /* - * Huffman table setup routines + * Reset standard Huffman tables */ LOCAL(void) -add_huff_table (j_compress_ptr cinfo, - JHUFF_TBL **htblptr, const UINT8 *bits, const UINT8 *val) -/* Define a Huffman table */ +std_huff_tables (j_compress_ptr cinfo) { - int nsymbols, len; - - if (*htblptr == NULL) - *htblptr = jpeg_alloc_huff_table((j_common_ptr) cinfo); - - /* Copy the number-of-symbols-of-each-code-length counts */ - MEMCOPY((*htblptr)->bits, bits, SIZEOF((*htblptr)->bits)); + if (cinfo->dc_huff_tbl_ptrs[0] != NULL) + (void) jpeg_std_huff_table((j_common_ptr) cinfo, TRUE, 0); - /* Validate the counts. We do this here mainly so we can copy the right - * number of symbols from the val[] array, without risking marching off - * the end of memory. jchuff.c will do a more thorough test later. - */ - nsymbols = 0; - for (len = 1; len <= 16; len++) - nsymbols += bits[len]; - if (nsymbols < 1 || nsymbols > 256) - ERREXIT(cinfo, JERR_BAD_HUFF_TABLE); + if (cinfo->ac_huff_tbl_ptrs[0] != NULL) + (void) jpeg_std_huff_table((j_common_ptr) cinfo, FALSE, 0); - MEMCOPY((*htblptr)->huffval, val, nsymbols * SIZEOF(UINT8)); + if (cinfo->dc_huff_tbl_ptrs[1] != NULL) + (void) jpeg_std_huff_table((j_common_ptr) cinfo, TRUE, 1); - /* Initialize sent_table FALSE so table will be written to JPEG file. */ - (*htblptr)->sent_table = FALSE; -} - - -LOCAL(void) -std_huff_tables (j_compress_ptr cinfo) -/* Set up the standard Huffman tables (cf. JPEG standard section K.3) */ -/* IMPORTANT: these are only valid for 8-bit data precision! */ -{ - static const UINT8 bits_dc_luminance[17] = - { /* 0-base */ 0, 0, 1, 5, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0 }; - static const UINT8 val_dc_luminance[] = - { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 }; - - static const UINT8 bits_dc_chrominance[17] = - { /* 0-base */ 0, 0, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0 }; - static const UINT8 val_dc_chrominance[] = - { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 }; - - static const UINT8 bits_ac_luminance[17] = - { /* 0-base */ 0, 0, 2, 1, 3, 3, 2, 4, 3, 5, 5, 4, 4, 0, 0, 1, 0x7d }; - static const UINT8 val_ac_luminance[] = - { 0x01, 0x02, 0x03, 0x00, 0x04, 0x11, 0x05, 0x12, - 0x21, 0x31, 0x41, 0x06, 0x13, 0x51, 0x61, 0x07, - 0x22, 0x71, 0x14, 0x32, 0x81, 0x91, 0xa1, 0x08, - 0x23, 0x42, 0xb1, 0xc1, 0x15, 0x52, 0xd1, 0xf0, - 0x24, 0x33, 0x62, 0x72, 0x82, 0x09, 0x0a, 0x16, - 0x17, 0x18, 0x19, 0x1a, 0x25, 0x26, 0x27, 0x28, - 0x29, 0x2a, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, - 0x3a, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, - 0x4a, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, - 0x5a, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, - 0x6a, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, - 0x7a, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, - 0x8a, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, 0x98, - 0x99, 0x9a, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, - 0xa8, 0xa9, 0xaa, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, - 0xb7, 0xb8, 0xb9, 0xba, 0xc2, 0xc3, 0xc4, 0xc5, - 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xd2, 0xd3, 0xd4, - 0xd5, 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xe1, 0xe2, - 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, 0xe8, 0xe9, 0xea, - 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, 0xf8, - 0xf9, 0xfa }; - - static const UINT8 bits_ac_chrominance[17] = - { /* 0-base */ 0, 0, 2, 1, 2, 4, 4, 3, 4, 7, 5, 4, 4, 0, 1, 2, 0x77 }; - static const UINT8 val_ac_chrominance[] = - { 0x00, 0x01, 0x02, 0x03, 0x11, 0x04, 0x05, 0x21, - 0x31, 0x06, 0x12, 0x41, 0x51, 0x07, 0x61, 0x71, - 0x13, 0x22, 0x32, 0x81, 0x08, 0x14, 0x42, 0x91, - 0xa1, 0xb1, 0xc1, 0x09, 0x23, 0x33, 0x52, 0xf0, - 0x15, 0x62, 0x72, 0xd1, 0x0a, 0x16, 0x24, 0x34, - 0xe1, 0x25, 0xf1, 0x17, 0x18, 0x19, 0x1a, 0x26, - 0x27, 0x28, 0x29, 0x2a, 0x35, 0x36, 0x37, 0x38, - 0x39, 0x3a, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, - 0x49, 0x4a, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, - 0x59, 0x5a, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, - 0x69, 0x6a, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, - 0x79, 0x7a, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, - 0x88, 0x89, 0x8a, 0x92, 0x93, 0x94, 0x95, 0x96, - 0x97, 0x98, 0x99, 0x9a, 0xa2, 0xa3, 0xa4, 0xa5, - 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xb2, 0xb3, 0xb4, - 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xc2, 0xc3, - 0xc4, 0xc5, 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xd2, - 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, 0xd8, 0xd9, 0xda, - 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, 0xe8, 0xe9, - 0xea, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, 0xf8, - 0xf9, 0xfa }; - - add_huff_table(cinfo, &cinfo->dc_huff_tbl_ptrs[0], - bits_dc_luminance, val_dc_luminance); - add_huff_table(cinfo, &cinfo->ac_huff_tbl_ptrs[0], - bits_ac_luminance, val_ac_luminance); - add_huff_table(cinfo, &cinfo->dc_huff_tbl_ptrs[1], - bits_dc_chrominance, val_dc_chrominance); - add_huff_table(cinfo, &cinfo->ac_huff_tbl_ptrs[1], - bits_ac_chrominance, val_ac_chrominance); + if (cinfo->ac_huff_tbl_ptrs[1] != NULL) + (void) jpeg_std_huff_table((j_common_ptr) cinfo, FALSE, 1); } @@ -306,7 +217,7 @@ jpeg_set_defaults (j_compress_ptr cinfo) cinfo->data_precision = BITS_IN_JSAMPLE; /* Set up two quantization tables using default quality of 75 */ jpeg_set_quality(cinfo, 75, TRUE); - /* Set up two Huffman tables */ + /* Reset standard Huffman tables */ std_huff_tables(cinfo); /* Initialize default arithmetic coding conditioning */ diff --git a/external/jpeg-9c/jcprepct.c b/external/jpeg-9d/jcprepct.c similarity index 100% rename from external/jpeg-9c/jcprepct.c rename to external/jpeg-9d/jcprepct.c diff --git a/external/jpeg-9c/jcsample.c b/external/jpeg-9d/jcsample.c similarity index 100% rename from external/jpeg-9c/jcsample.c rename to external/jpeg-9d/jcsample.c diff --git a/external/jpeg-9c/jctrans.c b/external/jpeg-9d/jctrans.c similarity index 100% rename from external/jpeg-9c/jctrans.c rename to external/jpeg-9d/jctrans.c diff --git a/external/jpeg-9c/jdapimin.c b/external/jpeg-9d/jdapimin.c similarity index 100% rename from external/jpeg-9c/jdapimin.c rename to external/jpeg-9d/jdapimin.c diff --git a/external/jpeg-9c/jdapistd.c b/external/jpeg-9d/jdapistd.c similarity index 100% rename from external/jpeg-9c/jdapistd.c rename to external/jpeg-9d/jdapistd.c diff --git a/external/jpeg-9c/jdarith.c b/external/jpeg-9d/jdarith.c similarity index 97% rename from external/jpeg-9c/jdarith.c rename to external/jpeg-9d/jdarith.c index 5533c073..9e4dfdf7 100644 --- a/external/jpeg-9c/jdarith.c +++ b/external/jpeg-9d/jdarith.c @@ -1,7 +1,7 @@ /* * jdarith.c * - * Developed 1997-2015 by Guido Vollbeding. + * Developed 1997-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -280,7 +280,7 @@ decode_mcu_DC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) if ((m = arith_decode(cinfo, st)) != 0) { st = entropy->dc_stats[tbl] + 20; /* Table F.4: X1 = 20 */ while (arith_decode(cinfo, st)) { - if ((m <<= 1) == 0x8000) { + if ((m <<= 1) == (int) 0x8000U) { WARNMS(cinfo, JWRN_ARITH_BAD_CODE); entropy->ct = -1; /* magnitude overflow */ return TRUE; @@ -370,7 +370,7 @@ decode_mcu_AC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) st = entropy->ac_stats[tbl] + (k <= cinfo->arith_ac_K[tbl] ? 189 : 217); while (arith_decode(cinfo, st)) { - if ((m <<= 1) == 0x8000) { + if ((m <<= 1) == (int) 0x8000U) { WARNMS(cinfo, JWRN_ARITH_BAD_CODE); entropy->ct = -1; /* magnitude overflow */ return TRUE; @@ -404,7 +404,8 @@ decode_mcu_DC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) { arith_entropy_ptr entropy = (arith_entropy_ptr) cinfo->entropy; unsigned char *st; - int p1, blkn; + JCOEF p1; + int blkn; /* Process restart marker if needed */ if (cinfo->restart_interval) { @@ -440,7 +441,7 @@ decode_mcu_AC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) JCOEFPTR thiscoef; unsigned char *st; int tbl, k, kex; - int p1, m1; + JCOEF p1, m1; const int * natural_order; /* Process restart marker if needed */ @@ -459,7 +460,7 @@ decode_mcu_AC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) tbl = cinfo->cur_comp_info[0]->ac_tbl_no; p1 = 1 << cinfo->Al; /* 1 in the bit position being coded */ - m1 = (-1) << cinfo->Al; /* -1 in the bit position being coded */ + m1 = -p1; /* -1 in the bit position being coded */ /* Establish EOBx (previous stage end-of-block) index */ kex = cinfo->Se; @@ -555,7 +556,7 @@ decode_mcu (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) if ((m = arith_decode(cinfo, st)) != 0) { st = entropy->dc_stats[tbl] + 20; /* Table F.4: X1 = 20 */ while (arith_decode(cinfo, st)) { - if ((m <<= 1) == 0x8000) { + if ((m <<= 1) == (int) 0x8000U) { WARNMS(cinfo, JWRN_ARITH_BAD_CODE); entropy->ct = -1; /* magnitude overflow */ return TRUE; @@ -612,7 +613,7 @@ decode_mcu (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) st = entropy->ac_stats[tbl] + (k <= cinfo->arith_ac_K[tbl] ? 189 : 217); while (arith_decode(cinfo, st)) { - if ((m <<= 1) == 0x8000) { + if ((m <<= 1) == (int) 0x8000U) { WARNMS(cinfo, JWRN_ARITH_BAD_CODE); entropy->ct = -1; /* magnitude overflow */ return TRUE; @@ -766,9 +767,8 @@ jinit_arith_decoder (j_decompress_ptr cinfo) arith_entropy_ptr entropy; int i; - entropy = (arith_entropy_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(arith_entropy_decoder)); + entropy = (arith_entropy_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(arith_entropy_decoder)); cinfo->entropy = &entropy->pub; entropy->pub.start_pass = start_pass; entropy->pub.finish_pass = finish_pass; @@ -785,9 +785,9 @@ jinit_arith_decoder (j_decompress_ptr cinfo) if (cinfo->progressive_mode) { /* Create progression status table */ int *coef_bit_ptr, ci; - cinfo->coef_bits = (int (*)[DCTSIZE2]) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - cinfo->num_components*DCTSIZE2*SIZEOF(int)); + cinfo->coef_bits = (int (*)[DCTSIZE2]) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, + cinfo->num_components * DCTSIZE2 * SIZEOF(int)); coef_bit_ptr = & cinfo->coef_bits[0][0]; for (ci = 0; ci < cinfo->num_components; ci++) for (i = 0; i < DCTSIZE2; i++) diff --git a/external/jpeg-9c/jdatadst.c b/external/jpeg-9d/jdatadst.c similarity index 92% rename from external/jpeg-9c/jdatadst.c rename to external/jpeg-9d/jdatadst.c index dcac2293..75ebd7c2 100644 --- a/external/jpeg-9c/jdatadst.c +++ b/external/jpeg-9d/jdatadst.c @@ -2,7 +2,7 @@ * jdatadst.c * * Copyright (C) 1994-1996, Thomas G. Lane. - * Modified 2009-2017 by Guido Vollbeding. + * Modified 2009-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -46,7 +46,7 @@ typedef struct { struct jpeg_destination_mgr pub; /* public fields */ unsigned char ** outbuffer; /* target buffer */ - unsigned long * outsize; + size_t * outsize; unsigned char * newbuffer; /* newly allocated buffer */ JOCTET * buffer; /* start of buffer */ size_t bufsize; @@ -66,9 +66,8 @@ init_destination (j_compress_ptr cinfo) my_dest_ptr dest = (my_dest_ptr) cinfo->dest; /* Allocate the output buffer --- it will be released when done with image */ - dest->buffer = (JOCTET *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - OUTPUT_BUF_SIZE * SIZEOF(JOCTET)); + dest->buffer = (JOCTET *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, OUTPUT_BUF_SIZE * SIZEOF(JOCTET)); dest->pub.next_output_byte = dest->buffer; dest->pub.free_in_buffer = OUTPUT_BUF_SIZE; @@ -131,7 +130,7 @@ empty_mem_output_buffer (j_compress_ptr cinfo) nextbuffer = (JOCTET *) malloc(nextsize); if (nextbuffer == NULL) - ERREXIT1(cinfo, JERR_OUT_OF_MEMORY, 10); + ERREXIT1(cinfo, JERR_OUT_OF_MEMORY, 11); MEMCOPY(nextbuffer, dest->buffer, dest->bufsize); @@ -204,9 +203,8 @@ jpeg_stdio_dest (j_compress_ptr cinfo, FILE * outfile) * sizes may be different. Caveat programmer. */ if (cinfo->dest == NULL) { /* first time for this JPEG object? */ - cinfo->dest = (struct jpeg_destination_mgr *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_PERMANENT, - SIZEOF(my_destination_mgr)); + cinfo->dest = (struct jpeg_destination_mgr *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_PERMANENT, SIZEOF(my_destination_mgr)); } dest = (my_dest_ptr) cinfo->dest; @@ -233,7 +231,7 @@ jpeg_stdio_dest (j_compress_ptr cinfo, FILE * outfile) GLOBAL(void) jpeg_mem_dest (j_compress_ptr cinfo, - unsigned char ** outbuffer, unsigned long * outsize) + unsigned char ** outbuffer, size_t * outsize) { my_mem_dest_ptr dest; @@ -244,9 +242,8 @@ jpeg_mem_dest (j_compress_ptr cinfo, * can be written to the same buffer without re-executing jpeg_mem_dest. */ if (cinfo->dest == NULL) { /* first time for this JPEG object? */ - cinfo->dest = (struct jpeg_destination_mgr *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_PERMANENT, - SIZEOF(my_mem_destination_mgr)); + cinfo->dest = (struct jpeg_destination_mgr *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_PERMANENT, SIZEOF(my_mem_destination_mgr)); } dest = (my_mem_dest_ptr) cinfo->dest; diff --git a/external/jpeg-9c/jdatasrc.c b/external/jpeg-9d/jdatasrc.c similarity index 91% rename from external/jpeg-9c/jdatasrc.c rename to external/jpeg-9d/jdatasrc.c index 2a27cfed..606ae11b 100644 --- a/external/jpeg-9c/jdatasrc.c +++ b/external/jpeg-9d/jdatasrc.c @@ -2,7 +2,7 @@ * jdatasrc.c * * Copyright (C) 1994-1996, Thomas G. Lane. - * Modified 2009-2015 by Guido Vollbeding. + * Modified 2009-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -156,21 +156,23 @@ METHODDEF(void) skip_input_data (j_decompress_ptr cinfo, long num_bytes) { struct jpeg_source_mgr * src = cinfo->src; + size_t nbytes; /* Just a dumb implementation for now. Could use fseek() except * it doesn't work on pipes. Not clear that being smart is worth * any trouble anyway --- large skips are infrequent. */ if (num_bytes > 0) { - while (num_bytes > (long) src->bytes_in_buffer) { - num_bytes -= (long) src->bytes_in_buffer; + nbytes = (size_t) num_bytes; + while (nbytes > src->bytes_in_buffer) { + nbytes -= src->bytes_in_buffer; (void) (*src->fill_input_buffer) (cinfo); /* note we assume that fill_input_buffer will never return FALSE, * so suspension need not be handled. */ } - src->next_input_byte += (size_t) num_bytes; - src->bytes_in_buffer -= (size_t) num_bytes; + src->next_input_byte += nbytes; + src->bytes_in_buffer -= nbytes; } } @@ -219,13 +221,11 @@ jpeg_stdio_src (j_decompress_ptr cinfo, FILE * infile) * manager serially with the same JPEG object. Caveat programmer. */ if (cinfo->src == NULL) { /* first time for this JPEG object? */ - cinfo->src = (struct jpeg_source_mgr *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_PERMANENT, - SIZEOF(my_source_mgr)); + cinfo->src = (struct jpeg_source_mgr *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_PERMANENT, SIZEOF(my_source_mgr)); src = (my_src_ptr) cinfo->src; - src->buffer = (JOCTET *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_PERMANENT, - INPUT_BUF_SIZE * SIZEOF(JOCTET)); + src->buffer = (JOCTET *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_PERMANENT, INPUT_BUF_SIZE * SIZEOF(JOCTET)); } src = (my_src_ptr) cinfo->src; @@ -247,7 +247,7 @@ jpeg_stdio_src (j_decompress_ptr cinfo, FILE * infile) GLOBAL(void) jpeg_mem_src (j_decompress_ptr cinfo, - const unsigned char * inbuffer, unsigned long insize) + const unsigned char * inbuffer, size_t insize) { struct jpeg_source_mgr * src; @@ -259,9 +259,8 @@ jpeg_mem_src (j_decompress_ptr cinfo, * the first one. */ if (cinfo->src == NULL) { /* first time for this JPEG object? */ - cinfo->src = (struct jpeg_source_mgr *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_PERMANENT, - SIZEOF(struct jpeg_source_mgr)); + cinfo->src = (struct jpeg_source_mgr *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_PERMANENT, SIZEOF(struct jpeg_source_mgr)); } src = cinfo->src; @@ -270,6 +269,6 @@ jpeg_mem_src (j_decompress_ptr cinfo, src->skip_input_data = skip_input_data; src->resync_to_restart = jpeg_resync_to_restart; /* use default method */ src->term_source = term_source; - src->bytes_in_buffer = (size_t) insize; + src->bytes_in_buffer = insize; src->next_input_byte = (const JOCTET *) inbuffer; } diff --git a/external/jpeg-9c/jdcoefct.c b/external/jpeg-9d/jdcoefct.c similarity index 100% rename from external/jpeg-9c/jdcoefct.c rename to external/jpeg-9d/jdcoefct.c diff --git a/external/jpeg-9c/jdcolor.c b/external/jpeg-9d/jdcolor.c similarity index 87% rename from external/jpeg-9c/jdcolor.c rename to external/jpeg-9d/jdcolor.c index 0316354d..3746c2e9 100644 --- a/external/jpeg-9c/jdcolor.c +++ b/external/jpeg-9d/jdcolor.c @@ -2,7 +2,7 @@ * jdcolor.c * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2011-2017 by Guido Vollbeding. + * Modified 2011-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -124,28 +124,22 @@ build_ycc_rgb_table (j_decompress_ptr cinfo) INT32 x; SHIFT_TEMPS - cconvert->Cr_r_tab = (int *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(int)); - cconvert->Cb_b_tab = (int *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(int)); - cconvert->Cr_g_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(INT32)); - cconvert->Cb_g_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(INT32)); + cconvert->Cr_r_tab = (int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(int)); + cconvert->Cb_b_tab = (int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(int)); + cconvert->Cr_g_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(INT32)); + cconvert->Cb_g_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(INT32)); for (i = 0, x = -CENTERJSAMPLE; i <= MAXJSAMPLE; i++, x++) { /* i is the actual input pixel value, in the range 0..MAXJSAMPLE */ /* The Cb or Cr value we are thinking of is x = i - CENTERJSAMPLE */ /* Cr=>R value is nearest int to 1.402 * x */ - cconvert->Cr_r_tab[i] = (int) - RIGHT_SHIFT(FIX(1.402) * x + ONE_HALF, SCALEBITS); + cconvert->Cr_r_tab[i] = (int) DESCALE(FIX(1.402) * x, SCALEBITS); /* Cb=>B value is nearest int to 1.772 * x */ - cconvert->Cb_b_tab[i] = (int) - RIGHT_SHIFT(FIX(1.772) * x + ONE_HALF, SCALEBITS); + cconvert->Cb_b_tab[i] = (int) DESCALE(FIX(1.772) * x, SCALEBITS); /* Cr=>G value is scaled-up -0.714136286 * x */ cconvert->Cr_g_tab[i] = (- FIX(0.714136286)) * x; /* Cb=>G value is scaled-up -0.344136286 * x */ @@ -164,28 +158,22 @@ build_bg_ycc_rgb_table (j_decompress_ptr cinfo) INT32 x; SHIFT_TEMPS - cconvert->Cr_r_tab = (int *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(int)); - cconvert->Cb_b_tab = (int *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(int)); - cconvert->Cr_g_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(INT32)); - cconvert->Cb_g_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(INT32)); + cconvert->Cr_r_tab = (int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(int)); + cconvert->Cb_b_tab = (int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(int)); + cconvert->Cr_g_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(INT32)); + cconvert->Cb_g_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(INT32)); for (i = 0, x = -CENTERJSAMPLE; i <= MAXJSAMPLE; i++, x++) { /* i is the actual input pixel value, in the range 0..MAXJSAMPLE */ /* The Cb or Cr value we are thinking of is x = i - CENTERJSAMPLE */ /* Cr=>R value is nearest int to 2.804 * x */ - cconvert->Cr_r_tab[i] = (int) - RIGHT_SHIFT(FIX(2.804) * x + ONE_HALF, SCALEBITS); + cconvert->Cr_r_tab[i] = (int) DESCALE(FIX(2.804) * x, SCALEBITS); /* Cb=>B value is nearest int to 3.544 * x */ - cconvert->Cb_b_tab[i] = (int) - RIGHT_SHIFT(FIX(3.544) * x + ONE_HALF, SCALEBITS); + cconvert->Cb_b_tab[i] = (int) DESCALE(FIX(3.544) * x, SCALEBITS); /* Cr=>G value is scaled-up -1.428272572 * x */ cconvert->Cr_g_tab[i] = (- FIX(1.428272572)) * x; /* Cb=>G value is scaled-up -0.688272572 * x */ @@ -201,6 +189,7 @@ build_bg_ycc_rgb_table (j_decompress_ptr cinfo) * Note that we change from noninterleaved, one-plane-per-component format * to interleaved-pixel format. The output buffer is therefore three times * as wide as the input buffer. + * * A starting row offset is provided only for the input buffer. The caller * can easily adjust the passed output_buf value to accommodate any row * offset required on that side. @@ -264,9 +253,8 @@ build_rgb_y_table (j_decompress_ptr cinfo) INT32 i; /* Allocate and fill in the conversion tables. */ - cconvert->rgb_y_tab = rgb_y_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (TABLE_SIZE * SIZEOF(INT32))); + cconvert->rgb_y_tab = rgb_y_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, TABLE_SIZE * SIZEOF(INT32)); for (i = 0; i <= MAXJSAMPLE; i++) { rgb_y_tab[i+R_Y_OFF] = FIX(0.299) * i; @@ -286,8 +274,8 @@ rgb_gray_convert (j_decompress_ptr cinfo, JSAMPARRAY output_buf, int num_rows) { my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert; - register INT32 * ctab = cconvert->rgb_y_tab; register int r, g, b; + register INT32 * ctab = cconvert->rgb_y_tab; register JSAMPROW outptr; register JSAMPROW inptr0, inptr1, inptr2; register JDIMENSION col; @@ -313,6 +301,7 @@ rgb_gray_convert (j_decompress_ptr cinfo, /* + * Convert some rows of samples to the output colorspace. * [R-G,G,B-G] to [R,G,B] conversion with modulo calculation * (inverse color transform). * This can be seen as an adaption of the general YCbCr->RGB @@ -364,8 +353,8 @@ rgb1_gray_convert (j_decompress_ptr cinfo, JSAMPARRAY output_buf, int num_rows) { my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert; - register INT32 * ctab = cconvert->rgb_y_tab; register int r, g, b; + register INT32 * ctab = cconvert->rgb_y_tab; register JSAMPROW outptr; register JSAMPROW inptr0, inptr1, inptr2; register JDIMENSION col; @@ -396,6 +385,7 @@ rgb1_gray_convert (j_decompress_ptr cinfo, /* + * Convert some rows of samples to the output colorspace. * No colorspace change, but conversion from separate-planes * to interleaved representation. */ @@ -430,6 +420,7 @@ rgb_convert (j_decompress_ptr cinfo, /* * Color conversion for no colorspace change: just copy the data, * converting from separate-planes to interleaved representation. + * We assume out_color_components == num_components. */ METHODDEF(void) @@ -437,20 +428,21 @@ null_convert (j_decompress_ptr cinfo, JSAMPIMAGE input_buf, JDIMENSION input_row, JSAMPARRAY output_buf, int num_rows) { - int ci; - register int nc = cinfo->num_components; register JSAMPROW outptr; register JSAMPROW inptr; - register JDIMENSION col; + register JDIMENSION count; + register int num_comps = cinfo->num_components; JDIMENSION num_cols = cinfo->output_width; + int ci; while (--num_rows >= 0) { - for (ci = 0; ci < nc; ci++) { + /* It seems fastest to make a separate pass for each component. */ + for (ci = 0; ci < num_comps; ci++) { inptr = input_buf[ci][input_row]; outptr = output_buf[0] + ci; - for (col = 0; col < num_cols; col++) { - *outptr = *inptr++; /* needn't bother with GETJSAMPLE() here */ - outptr += nc; + for (count = num_cols; count > 0; count--) { + *outptr = *inptr++; /* don't need GETJSAMPLE() here */ + outptr += num_comps; } } input_row++; @@ -504,9 +496,10 @@ gray_rgb_convert (j_decompress_ptr cinfo, /* - * Adobe-style YCCK->CMYK conversion. - * We convert YCbCr to R=1-C, G=1-M, and B=1-Y using the same - * conversion as above, while passing K (black) unchanged. + * Convert some rows of samples to the output colorspace. + * This version handles Adobe-style YCCK->CMYK conversion, + * where we convert YCbCr to R=1-C, G=1-M, and B=1-Y using the + * same conversion as above, while passing K (black) unchanged. * We assume build_ycc_rgb_table has been called. */ @@ -577,9 +570,8 @@ jinit_color_deconverter (j_decompress_ptr cinfo) my_cconvert_ptr cconvert; int ci; - cconvert = (my_cconvert_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(my_color_deconverter)); + cconvert = (my_cconvert_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(my_color_deconverter)); cinfo->cconvert = &cconvert->pub; cconvert->pub.start_pass = start_pass_dcolor; @@ -607,7 +599,6 @@ jinit_color_deconverter (j_decompress_ptr cinfo) default: /* JCS_UNKNOWN can be anything */ if (cinfo->num_components < 1) ERREXIT(cinfo, JERR_BAD_J_COLORSPACE); - break; } /* Support color transform only for RGB colorspaces */ @@ -684,19 +675,18 @@ jinit_color_deconverter (j_decompress_ptr cinfo) case JCS_BG_RGB: cinfo->out_color_components = RGB_PIXELSIZE; - if (cinfo->jpeg_color_space == JCS_BG_RGB) { - switch (cinfo->color_transform) { - case JCT_NONE: - cconvert->pub.color_convert = rgb_convert; - break; - case JCT_SUBTRACT_GREEN: - cconvert->pub.color_convert = rgb1_rgb_convert; - break; - default: - ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); - } - } else + if (cinfo->jpeg_color_space != JCS_BG_RGB) ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); + switch (cinfo->color_transform) { + case JCT_NONE: + cconvert->pub.color_convert = rgb_convert; + break; + case JCT_SUBTRACT_GREEN: + cconvert->pub.color_convert = rgb1_rgb_convert; + break; + default: + ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); + } break; case JCS_CMYK: @@ -714,14 +704,12 @@ jinit_color_deconverter (j_decompress_ptr cinfo) } break; - default: - /* Permit null conversion to same output space */ - if (cinfo->out_color_space == cinfo->jpeg_color_space) { - cinfo->out_color_components = cinfo->num_components; - cconvert->pub.color_convert = null_convert; - } else /* unsupported non-null conversion */ + default: /* permit null conversion to same output space */ + if (cinfo->out_color_space != cinfo->jpeg_color_space) + /* unsupported non-null conversion */ ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL); - break; + cinfo->out_color_components = cinfo->num_components; + cconvert->pub.color_convert = null_convert; } if (cinfo->quantize_colors) diff --git a/external/jpeg-9c/jdct.h b/external/jpeg-9d/jdct.h similarity index 98% rename from external/jpeg-9c/jdct.h rename to external/jpeg-9d/jdct.h index bcfedfcf..c8ec6cd9 100644 --- a/external/jpeg-9c/jdct.h +++ b/external/jpeg-9d/jdct.h @@ -2,7 +2,7 @@ * jdct.h * * Copyright (C) 1994-1996, Thomas G. Lane. - * Modified 2002-2017 by Guido Vollbeding. + * Modified 2002-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -358,13 +358,6 @@ EXTERN(void) jpeg_idct_1x2 #define FIX(x) ((INT32) ((x) * CONST_SCALE + 0.5)) -/* Descale and correctly round an INT32 value that's scaled by N bits. - * We assume RIGHT_SHIFT rounds towards minus infinity, so adding - * the fudge factor is correct for either sign of X. - */ - -#define DESCALE(x,n) RIGHT_SHIFT((x) + (ONE << ((n)-1)), n) - /* Multiply an INT32 variable by an INT32 constant to yield an INT32 result. * This macro is used only when the two inputs will actually be no more than * 16 bits wide, so that a 16x16->32 bit multiply can be used instead of a diff --git a/external/jpeg-9c/jddctmgr.c b/external/jpeg-9d/jddctmgr.c similarity index 100% rename from external/jpeg-9c/jddctmgr.c rename to external/jpeg-9d/jddctmgr.c diff --git a/external/jpeg-9c/jdhuff.c b/external/jpeg-9d/jdhuff.c similarity index 94% rename from external/jpeg-9c/jdhuff.c rename to external/jpeg-9d/jdhuff.c index 835d06ec..aea06f60 100644 --- a/external/jpeg-9c/jdhuff.c +++ b/external/jpeg-9d/jdhuff.c @@ -2,7 +2,7 @@ * jdhuff.c * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2006-2016 by Guido Vollbeding. + * Modified 2006-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -341,13 +341,12 @@ jpeg_make_d_derived_tbl (j_decompress_ptr cinfo, boolean isDC, int tblno, htbl = isDC ? cinfo->dc_huff_tbl_ptrs[tblno] : cinfo->ac_huff_tbl_ptrs[tblno]; if (htbl == NULL) - ERREXIT1(cinfo, JERR_NO_HUFF_TABLE, tblno); + htbl = jpeg_std_huff_table((j_common_ptr) cinfo, isDC, tblno); /* Allocate a workspace if we haven't already done so. */ if (*pdtbl == NULL) - *pdtbl = (d_derived_tbl *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(d_derived_tbl)); + *pdtbl = (d_derived_tbl *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(d_derived_tbl)); dtbl = *pdtbl; dtbl->pub = htbl; /* fill in back link */ @@ -706,7 +705,7 @@ process_restart (j_decompress_ptr cinfo) METHODDEF(boolean) decode_mcu_DC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) -{ +{ huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy; int Al = cinfo->Al; register int s, r; @@ -730,7 +729,7 @@ decode_mcu_DC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) if (! entropy->insufficient_data) { /* Load up working state */ - BITREAD_LOAD_STATE(cinfo,entropy->bitstate); + BITREAD_LOAD_STATE(cinfo, entropy->bitstate); ASSIGN_STATE(state, entropy->saved); /* Outer loop handles each block in the MCU */ @@ -759,12 +758,13 @@ decode_mcu_DC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) } /* Completed MCU, so update state */ - BITREAD_SAVE_STATE(cinfo,entropy->bitstate); + BITREAD_SAVE_STATE(cinfo, entropy->bitstate); ASSIGN_STATE(entropy->saved, state); } - /* Account for restart interval (no-op if not using restarts) */ - entropy->restarts_to_go--; + /* Account for restart interval if using restarts */ + if (cinfo->restart_interval) + entropy->restarts_to_go--; return TRUE; } @@ -777,7 +777,7 @@ decode_mcu_DC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) METHODDEF(boolean) decode_mcu_AC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) -{ +{ huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy; register int s, k, r; unsigned int EOBRUN; @@ -809,7 +809,7 @@ decode_mcu_AC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) if (EOBRUN) /* if it's a band of zeroes... */ EOBRUN--; /* ...process it now (we do nothing) */ else { - BITREAD_LOAD_STATE(cinfo,entropy->bitstate); + BITREAD_LOAD_STATE(cinfo, entropy->bitstate); Se = cinfo->Se; Al = cinfo->Al; natural_order = cinfo->natural_order; @@ -842,15 +842,16 @@ decode_mcu_AC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) } } - BITREAD_SAVE_STATE(cinfo,entropy->bitstate); + BITREAD_SAVE_STATE(cinfo, entropy->bitstate); } /* Completed MCU, so update state */ entropy->saved.EOBRUN = EOBRUN; /* only part of saved state we need */ } - /* Account for restart interval (no-op if not using restarts) */ - entropy->restarts_to_go--; + /* Account for restart interval if using restarts */ + if (cinfo->restart_interval) + entropy->restarts_to_go--; return TRUE; } @@ -864,9 +865,10 @@ decode_mcu_AC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) METHODDEF(boolean) decode_mcu_DC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) -{ +{ huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy; - int p1, blkn; + JCOEF p1; + int blkn; BITREAD_STATE_VARS; /* Process restart marker if needed; may have to suspend */ @@ -881,7 +883,7 @@ decode_mcu_DC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) */ /* Load up working state */ - BITREAD_LOAD_STATE(cinfo,entropy->bitstate); + BITREAD_LOAD_STATE(cinfo, entropy->bitstate); p1 = 1 << cinfo->Al; /* 1 in the bit position being coded */ @@ -896,10 +898,11 @@ decode_mcu_DC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) } /* Completed MCU, so update state */ - BITREAD_SAVE_STATE(cinfo,entropy->bitstate); + BITREAD_SAVE_STATE(cinfo, entropy->bitstate); - /* Account for restart interval (no-op if not using restarts) */ - entropy->restarts_to_go--; + /* Account for restart interval if using restarts */ + if (cinfo->restart_interval) + entropy->restarts_to_go--; return TRUE; } @@ -911,11 +914,12 @@ decode_mcu_DC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) METHODDEF(boolean) decode_mcu_AC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) -{ +{ huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy; register int s, k, r; unsigned int EOBRUN; - int Se, p1, m1; + int Se; + JCOEF p1, m1; const int * natural_order; JBLOCKROW block; JCOEFPTR thiscoef; @@ -937,11 +941,11 @@ decode_mcu_AC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) Se = cinfo->Se; p1 = 1 << cinfo->Al; /* 1 in the bit position being coded */ - m1 = (-1) << cinfo->Al; /* -1 in the bit position being coded */ + m1 = -p1; /* -1 in the bit position being coded */ natural_order = cinfo->natural_order; /* Load up working state */ - BITREAD_LOAD_STATE(cinfo,entropy->bitstate); + BITREAD_LOAD_STATE(cinfo, entropy->bitstate); EOBRUN = entropy->saved.EOBRUN; /* only part of saved state we need */ /* There is always only one block per MCU */ @@ -1043,12 +1047,13 @@ decode_mcu_AC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) } /* Completed MCU, so update state */ - BITREAD_SAVE_STATE(cinfo,entropy->bitstate); + BITREAD_SAVE_STATE(cinfo, entropy->bitstate); entropy->saved.EOBRUN = EOBRUN; /* only part of saved state we need */ } - /* Account for restart interval (no-op if not using restarts) */ - entropy->restarts_to_go--; + /* Account for restart interval if using restarts */ + if (cinfo->restart_interval) + entropy->restarts_to_go--; return TRUE; @@ -1091,7 +1096,7 @@ decode_mcu_sub (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) Se = cinfo->lim_Se; /* Load up working state */ - BITREAD_LOAD_STATE(cinfo,entropy->bitstate); + BITREAD_LOAD_STATE(cinfo, entropy->bitstate); ASSIGN_STATE(state, entropy->saved); /* Outer loop handles each block in the MCU */ @@ -1178,12 +1183,13 @@ decode_mcu_sub (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) } /* Completed MCU, so update state */ - BITREAD_SAVE_STATE(cinfo,entropy->bitstate); + BITREAD_SAVE_STATE(cinfo, entropy->bitstate); ASSIGN_STATE(entropy->saved, state); } - /* Account for restart interval (no-op if not using restarts) */ - entropy->restarts_to_go--; + /* Account for restart interval if using restarts */ + if (cinfo->restart_interval) + entropy->restarts_to_go--; return TRUE; } @@ -1215,7 +1221,7 @@ decode_mcu (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) if (! entropy->insufficient_data) { /* Load up working state */ - BITREAD_LOAD_STATE(cinfo,entropy->bitstate); + BITREAD_LOAD_STATE(cinfo, entropy->bitstate); ASSIGN_STATE(state, entropy->saved); /* Outer loop handles each block in the MCU */ @@ -1302,12 +1308,13 @@ decode_mcu (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) } /* Completed MCU, so update state */ - BITREAD_SAVE_STATE(cinfo,entropy->bitstate); + BITREAD_SAVE_STATE(cinfo, entropy->bitstate); ASSIGN_STATE(entropy->saved, state); } - /* Account for restart interval (no-op if not using restarts) */ - entropy->restarts_to_go--; + /* Account for restart interval if using restarts */ + if (cinfo->restart_interval) + entropy->restarts_to_go--; return TRUE; } @@ -1343,11 +1350,11 @@ start_pass_huff_decoder (j_decompress_ptr cinfo) goto bad; } if (cinfo->Al > 13) { /* need not check for < 0 */ - /* Arguably the maximum Al value should be less than 13 for 8-bit precision, - * but the spec doesn't say so, and we try to be liberal about what we - * accept. Note: large Al values could result in out-of-range DC - * coefficients during early scans, leading to bizarre displays due to - * overflows in the IDCT math. But we won't crash. + /* Arguably the maximum Al value should be less than 13 for 8-bit + * precision, but the spec doesn't say so, and we try to be liberal + * about what we accept. Note: large Al values could result in + * out-of-range DC coefficients during early scans, leading to bizarre + * displays due to overflows in the IDCT math. But we won't crash. */ bad: ERREXIT4(cinfo, JERR_BAD_PROGRESSION, @@ -1451,7 +1458,8 @@ start_pass_huff_decoder (j_decompress_ptr cinfo) compptr = cinfo->cur_comp_info[ci]; /* Precalculate which table to use for each block */ entropy->dc_cur_tbls[blkn] = entropy->dc_derived_tbls[compptr->dc_tbl_no]; - entropy->ac_cur_tbls[blkn] = entropy->ac_derived_tbls[compptr->ac_tbl_no]; + entropy->ac_cur_tbls[blkn] = /* AC needs no table when not present */ + cinfo->lim_Se ? entropy->ac_derived_tbls[compptr->ac_tbl_no] : NULL; /* Decide whether we really care about the coefficient values */ if (compptr->component_needed) { ci = compptr->DCT_v_scaled_size; @@ -1494,7 +1502,6 @@ start_pass_huff_decoder (j_decompress_ptr cinfo) if (ci <= 0 || ci > 8) ci = 8; if (i <= 0 || i > 8) i = 8; entropy->coef_limit[blkn] = 1 + jpeg_zigzag_order[ci - 1][i - 1]; - break; } } else { entropy->coef_limit[blkn] = 0; @@ -1522,9 +1529,8 @@ jinit_huff_decoder (j_decompress_ptr cinfo) huff_entropy_ptr entropy; int i; - entropy = (huff_entropy_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(huff_entropy_decoder)); + entropy = (huff_entropy_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(huff_entropy_decoder)); cinfo->entropy = &entropy->pub; entropy->pub.start_pass = start_pass_huff_decoder; entropy->pub.finish_pass = finish_pass_huff; @@ -1532,9 +1538,9 @@ jinit_huff_decoder (j_decompress_ptr cinfo) if (cinfo->progressive_mode) { /* Create progression status table */ int *coef_bit_ptr, ci; - cinfo->coef_bits = (int (*)[DCTSIZE2]) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - cinfo->num_components*DCTSIZE2*SIZEOF(int)); + cinfo->coef_bits = (int (*)[DCTSIZE2]) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, + cinfo->num_components * DCTSIZE2 * SIZEOF(int)); coef_bit_ptr = & cinfo->coef_bits[0][0]; for (ci = 0; ci < cinfo->num_components; ci++) for (i = 0; i < DCTSIZE2; i++) @@ -1545,7 +1551,7 @@ jinit_huff_decoder (j_decompress_ptr cinfo) entropy->derived_tbls[i] = NULL; } } else { - /* Mark tables unallocated */ + /* Mark derived tables unallocated */ for (i = 0; i < NUM_HUFF_TBLS; i++) { entropy->dc_derived_tbls[i] = entropy->ac_derived_tbls[i] = NULL; } diff --git a/external/jpeg-9c/jdinput.c b/external/jpeg-9d/jdinput.c similarity index 100% rename from external/jpeg-9c/jdinput.c rename to external/jpeg-9d/jdinput.c diff --git a/external/jpeg-9c/jdmainct.c b/external/jpeg-9d/jdmainct.c similarity index 100% rename from external/jpeg-9c/jdmainct.c rename to external/jpeg-9d/jdmainct.c diff --git a/external/jpeg-9c/jdmarker.c b/external/jpeg-9d/jdmarker.c similarity index 99% rename from external/jpeg-9c/jdmarker.c rename to external/jpeg-9d/jdmarker.c index 3fbe5c16..c10fde60 100644 --- a/external/jpeg-9c/jdmarker.c +++ b/external/jpeg-9d/jdmarker.c @@ -2,7 +2,7 @@ * jdmarker.c * * Copyright (C) 1991-1998, Thomas G. Lane. - * Modified 2009-2013 by Guido Vollbeding. + * Modified 2009-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -496,8 +496,6 @@ get_dht (j_decompress_ptr cinfo) if (count > 256 || ((INT32) count) > length) ERREXIT(cinfo, JERR_BAD_HUFF_TABLE); - MEMZERO(huffval, SIZEOF(huffval)); /* pre-zero array for later copy */ - for (i = 0; i < count; i++) INPUT_BYTE(cinfo, huffval[i], return FALSE); @@ -517,7 +515,8 @@ get_dht (j_decompress_ptr cinfo) *htblptr = jpeg_alloc_huff_table((j_common_ptr) cinfo); MEMCOPY((*htblptr)->bits, bits, SIZEOF((*htblptr)->bits)); - MEMCOPY((*htblptr)->huffval, huffval, SIZEOF((*htblptr)->huffval)); + if (count > 0) + MEMCOPY((*htblptr)->huffval, huffval, count * SIZEOF(UINT8)); } if (length != 0) @@ -577,14 +576,14 @@ get_dqt (j_decompress_ptr cinfo) count = DCTSIZE2; } - switch (count) { + switch ((int) count) { case (2*2): natural_order = jpeg_natural_order2; break; case (3*3): natural_order = jpeg_natural_order3; break; case (4*4): natural_order = jpeg_natural_order4; break; case (5*5): natural_order = jpeg_natural_order5; break; case (6*6): natural_order = jpeg_natural_order6; break; case (7*7): natural_order = jpeg_natural_order7; break; - default: natural_order = jpeg_natural_order; break; + default: natural_order = jpeg_natural_order; } for (i = 0; i < count; i++) { @@ -784,7 +783,6 @@ examine_app0 (j_decompress_ptr cinfo, JOCTET FAR * data, default: TRACEMS2(cinfo, 1, JTRC_JFIF_EXTENSION, GETJOCTET(data[5]), (int) totallen); - break; } } else { /* Start of APP0 does not match "JFIF" or "JFXX", or too short */ @@ -858,7 +856,6 @@ get_interesting_appn (j_decompress_ptr cinfo) default: /* can't get here unless jpeg_save_markers chooses wrong processor */ ERREXIT1(cinfo, JERR_UNKNOWN_MARKER, cinfo->unread_marker); - break; } /* skip any remaining data -- could be lots */ @@ -964,7 +961,6 @@ save_marker (j_decompress_ptr cinfo) default: TRACEMS2(cinfo, 1, JTRC_MISC_MARKER, cinfo->unread_marker, (int) (data_length + length)); - break; } /* skip any remaining data -- could be lots */ @@ -1240,7 +1236,6 @@ read_markers (j_decompress_ptr cinfo) * ought to change! */ ERREXIT1(cinfo, JERR_UNKNOWN_MARKER, cinfo->unread_marker); - break; } /* Successfully processed marker, so reset state variable */ cinfo->unread_marker = 0; @@ -1416,9 +1411,8 @@ jinit_marker_reader (j_decompress_ptr cinfo) int i; /* Create subobject in permanent pool */ - marker = (my_marker_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_PERMANENT, - SIZEOF(my_marker_reader)); + marker = (my_marker_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_PERMANENT, SIZEOF(my_marker_reader)); cinfo->marker = &marker->pub; /* Initialize public method pointers */ marker->pub.reset_marker_reader = reset_marker_reader; diff --git a/external/jpeg-9c/jdmaster.c b/external/jpeg-9d/jdmaster.c similarity index 95% rename from external/jpeg-9c/jdmaster.c rename to external/jpeg-9d/jdmaster.c index 62c07671..c309f762 100644 --- a/external/jpeg-9c/jdmaster.c +++ b/external/jpeg-9d/jdmaster.c @@ -2,7 +2,7 @@ * jdmaster.c * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2002-2017 by Guido Vollbeding. + * Modified 2002-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -104,7 +104,7 @@ jpeg_calc_output_dimensions (j_decompress_ptr cinfo) */ { #ifdef IDCT_SCALING_SUPPORTED - int ci; + int ci, ssize; jpeg_component_info *compptr; #endif @@ -124,19 +124,23 @@ jpeg_calc_output_dimensions (j_decompress_ptr cinfo) */ for (ci = 0, compptr = cinfo->comp_info; ci < cinfo->num_components; ci++, compptr++) { - int ssize = 1; - while (cinfo->min_DCT_h_scaled_size * ssize <= - (cinfo->do_fancy_upsampling ? DCTSIZE : DCTSIZE / 2) && - (cinfo->max_h_samp_factor % (compptr->h_samp_factor * ssize * 2)) == 0) { - ssize = ssize * 2; - } + ssize = 1; + if (! cinfo->raw_data_out) + while (cinfo->min_DCT_h_scaled_size * ssize <= + (cinfo->do_fancy_upsampling ? DCTSIZE : DCTSIZE / 2) && + (cinfo->max_h_samp_factor % (compptr->h_samp_factor * ssize * 2)) == + 0) { + ssize = ssize * 2; + } compptr->DCT_h_scaled_size = cinfo->min_DCT_h_scaled_size * ssize; ssize = 1; - while (cinfo->min_DCT_v_scaled_size * ssize <= - (cinfo->do_fancy_upsampling ? DCTSIZE : DCTSIZE / 2) && - (cinfo->max_v_samp_factor % (compptr->v_samp_factor * ssize * 2)) == 0) { - ssize = ssize * 2; - } + if (! cinfo->raw_data_out) + while (cinfo->min_DCT_v_scaled_size * ssize <= + (cinfo->do_fancy_upsampling ? DCTSIZE : DCTSIZE / 2) && + (cinfo->max_v_samp_factor % (compptr->v_samp_factor * ssize * 2)) == + 0) { + ssize = ssize * 2; + } compptr->DCT_v_scaled_size = cinfo->min_DCT_v_scaled_size * ssize; /* We don't support IDCT ratios larger than 2. */ @@ -144,13 +148,10 @@ jpeg_calc_output_dimensions (j_decompress_ptr cinfo) compptr->DCT_h_scaled_size = compptr->DCT_v_scaled_size * 2; else if (compptr->DCT_v_scaled_size > compptr->DCT_h_scaled_size * 2) compptr->DCT_v_scaled_size = compptr->DCT_h_scaled_size * 2; - } - /* Recompute downsampled dimensions of components; - * application needs to know these if using raw downsampled data. - */ - for (ci = 0, compptr = cinfo->comp_info; ci < cinfo->num_components; - ci++, compptr++) { + /* Recompute downsampled dimensions of components; + * application needs to know these if using raw downsampled data. + */ /* Size in samples, after IDCT scaling */ compptr->downsampled_width = (JDIMENSION) jdiv_round_up((long) cinfo->image_width * @@ -172,8 +173,10 @@ jpeg_calc_output_dimensions (j_decompress_ptr cinfo) break; case JCS_RGB: case JCS_BG_RGB: +#if RGB_PIXELSIZE != 3 cinfo->out_color_components = RGB_PIXELSIZE; break; +#endif /* else share code with YCbCr */ case JCS_YCbCr: case JCS_BG_YCC: cinfo->out_color_components = 3; @@ -184,7 +187,6 @@ jpeg_calc_output_dimensions (j_decompress_ptr cinfo) break; default: /* else must be same colorspace as in file */ cinfo->out_color_components = cinfo->num_components; - break; } cinfo->output_components = (cinfo->quantize_colors ? 1 : cinfo->out_color_components); @@ -525,9 +527,8 @@ jinit_master_decompress (j_decompress_ptr cinfo) { my_master_ptr master; - master = (my_master_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(my_decomp_master)); + master = (my_master_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(my_decomp_master)); cinfo->master = &master->pub; master->pub.prepare_for_output_pass = prepare_for_output_pass; master->pub.finish_output_pass = finish_output_pass; diff --git a/external/jpeg-9c/jdmerge.c b/external/jpeg-9d/jdmerge.c similarity index 88% rename from external/jpeg-9c/jdmerge.c rename to external/jpeg-9d/jdmerge.c index 866693f5..8b5c899c 100644 --- a/external/jpeg-9c/jdmerge.c +++ b/external/jpeg-9d/jdmerge.c @@ -2,7 +2,7 @@ * jdmerge.c * * Copyright (C) 1994-1996, Thomas G. Lane. - * Modified 2013-2017 by Guido Vollbeding. + * Modified 2013-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -95,28 +95,22 @@ build_ycc_rgb_table (j_decompress_ptr cinfo) INT32 x; SHIFT_TEMPS - upsample->Cr_r_tab = (int *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(int)); - upsample->Cb_b_tab = (int *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(int)); - upsample->Cr_g_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(INT32)); - upsample->Cb_g_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(INT32)); + upsample->Cr_r_tab = (int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(int)); + upsample->Cb_b_tab = (int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(int)); + upsample->Cr_g_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(INT32)); + upsample->Cb_g_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(INT32)); for (i = 0, x = -CENTERJSAMPLE; i <= MAXJSAMPLE; i++, x++) { /* i is the actual input pixel value, in the range 0..MAXJSAMPLE */ /* The Cb or Cr value we are thinking of is x = i - CENTERJSAMPLE */ /* Cr=>R value is nearest int to 1.402 * x */ - upsample->Cr_r_tab[i] = (int) - RIGHT_SHIFT(FIX(1.402) * x + ONE_HALF, SCALEBITS); + upsample->Cr_r_tab[i] = (int) DESCALE(FIX(1.402) * x, SCALEBITS); /* Cb=>B value is nearest int to 1.772 * x */ - upsample->Cb_b_tab[i] = (int) - RIGHT_SHIFT(FIX(1.772) * x + ONE_HALF, SCALEBITS); + upsample->Cb_b_tab[i] = (int) DESCALE(FIX(1.772) * x, SCALEBITS); /* Cr=>G value is scaled-up -0.714136286 * x */ upsample->Cr_g_tab[i] = (- FIX(0.714136286)) * x; /* Cb=>G value is scaled-up -0.344136286 * x */ @@ -135,28 +129,22 @@ build_bg_ycc_rgb_table (j_decompress_ptr cinfo) INT32 x; SHIFT_TEMPS - upsample->Cr_r_tab = (int *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(int)); - upsample->Cb_b_tab = (int *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(int)); - upsample->Cr_g_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(INT32)); - upsample->Cb_g_tab = (INT32 *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (MAXJSAMPLE+1) * SIZEOF(INT32)); + upsample->Cr_r_tab = (int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(int)); + upsample->Cb_b_tab = (int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(int)); + upsample->Cr_g_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(INT32)); + upsample->Cb_g_tab = (INT32 *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, (MAXJSAMPLE+1) * SIZEOF(INT32)); for (i = 0, x = -CENTERJSAMPLE; i <= MAXJSAMPLE; i++, x++) { /* i is the actual input pixel value, in the range 0..MAXJSAMPLE */ /* The Cb or Cr value we are thinking of is x = i - CENTERJSAMPLE */ /* Cr=>R value is nearest int to 2.804 * x */ - upsample->Cr_r_tab[i] = (int) - RIGHT_SHIFT(FIX(2.804) * x + ONE_HALF, SCALEBITS); + upsample->Cr_r_tab[i] = (int) DESCALE(FIX(2.804) * x, SCALEBITS); /* Cb=>B value is nearest int to 3.544 * x */ - upsample->Cb_b_tab[i] = (int) - RIGHT_SHIFT(FIX(3.544) * x + ONE_HALF, SCALEBITS); + upsample->Cb_b_tab[i] = (int) DESCALE(FIX(3.544) * x, SCALEBITS); /* Cr=>G value is scaled-up -1.428272572 * x */ upsample->Cr_g_tab[i] = (- FIX(1.428272572)) * x; /* Cb=>G value is scaled-up -0.688272572 * x */ @@ -419,9 +407,8 @@ jinit_merged_upsampler (j_decompress_ptr cinfo) { my_upsample_ptr upsample; - upsample = (my_upsample_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(my_upsampler)); + upsample = (my_upsample_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(my_upsampler)); cinfo->upsample = &upsample->pub; upsample->pub.start_pass = start_pass_merged_upsample; upsample->pub.need_context_rows = FALSE; @@ -432,9 +419,9 @@ jinit_merged_upsampler (j_decompress_ptr cinfo) upsample->pub.upsample = merged_2v_upsample; upsample->upmethod = h2v2_merged_upsample; /* Allocate a spare row buffer */ - upsample->spare_row = (JSAMPROW) - (*cinfo->mem->alloc_large) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (size_t) (upsample->out_row_width * SIZEOF(JSAMPLE))); + upsample->spare_row = (JSAMPROW) (*cinfo->mem->alloc_large) + ((j_common_ptr) cinfo, JPOOL_IMAGE, + (size_t) upsample->out_row_width * SIZEOF(JSAMPLE)); } else { upsample->pub.upsample = merged_1v_upsample; upsample->upmethod = h2v1_merged_upsample; diff --git a/external/jpeg-9c/jdpostct.c b/external/jpeg-9d/jdpostct.c similarity index 100% rename from external/jpeg-9c/jdpostct.c rename to external/jpeg-9d/jdpostct.c diff --git a/external/jpeg-9c/jdsample.c b/external/jpeg-9d/jdsample.c similarity index 100% rename from external/jpeg-9c/jdsample.c rename to external/jpeg-9d/jdsample.c diff --git a/external/jpeg-9c/jdtrans.c b/external/jpeg-9d/jdtrans.c similarity index 100% rename from external/jpeg-9c/jdtrans.c rename to external/jpeg-9d/jdtrans.c diff --git a/external/jpeg-9c/jerror.c b/external/jpeg-9d/jerror.c similarity index 100% rename from external/jpeg-9c/jerror.c rename to external/jpeg-9d/jerror.c diff --git a/external/jpeg-9c/jerror.h b/external/jpeg-9d/jerror.h similarity index 99% rename from external/jpeg-9c/jerror.h rename to external/jpeg-9d/jerror.h index a4b661f7..db608b9c 100644 --- a/external/jpeg-9c/jerror.h +++ b/external/jpeg-9d/jerror.h @@ -2,7 +2,7 @@ * jerror.h * * Copyright (C) 1994-1997, Thomas G. Lane. - * Modified 1997-2012 by Guido Vollbeding. + * Modified 1997-2018 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -84,7 +84,7 @@ JMESSAGE(JERR_EOI_EXPECTED, "Didn't expect more than one scan") JMESSAGE(JERR_FILE_READ, "Input file read error") JMESSAGE(JERR_FILE_WRITE, "Output file write error --- out of disk space?") JMESSAGE(JERR_FRACT_SAMPLE_NOTIMPL, "Fractional sampling not implemented yet") -JMESSAGE(JERR_HUFF_CLEN_OVERFLOW, "Huffman code size table overflow") +JMESSAGE(JERR_HUFF_CLEN_OUTOFBOUNDS, "Huffman code size table out of bounds") JMESSAGE(JERR_HUFF_MISSING_CODE, "Missing Huffman code table entry") JMESSAGE(JERR_IMAGE_TOO_BIG, "Maximum supported image dimension is %u pixels") JMESSAGE(JERR_INPUT_EMPTY, "Empty input file") diff --git a/external/jpeg-9c/jfdctflt.c b/external/jpeg-9d/jfdctflt.c similarity index 100% rename from external/jpeg-9c/jfdctflt.c rename to external/jpeg-9d/jfdctflt.c diff --git a/external/jpeg-9c/jfdctfst.c b/external/jpeg-9d/jfdctfst.c similarity index 100% rename from external/jpeg-9c/jfdctfst.c rename to external/jpeg-9d/jfdctfst.c diff --git a/external/jpeg-9c/jfdctint.c b/external/jpeg-9d/jfdctint.c similarity index 98% rename from external/jpeg-9c/jfdctint.c rename to external/jpeg-9d/jfdctint.c index 7ed42e5d..05df4750 100644 --- a/external/jpeg-9c/jfdctint.c +++ b/external/jpeg-9d/jfdctint.c @@ -2,7 +2,7 @@ * jfdctint.c * * Copyright (C) 1991-1996, Thomas G. Lane. - * Modification developed 2003-2015 by Guido Vollbeding. + * Modification developed 2003-2018 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -3261,78 +3261,84 @@ jpeg_fdct_6x3 (DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col) GLOBAL(void) jpeg_fdct_4x2 (DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col) { - INT32 tmp0, tmp1; - INT32 tmp10, tmp11; - DCTELEM *dataptr; + DCTELEM tmp0, tmp2, tmp10, tmp12, tmp4, tmp5; + INT32 tmp1, tmp3, tmp11, tmp13; + INT32 z1, z2, z3; JSAMPROW elemptr; - int ctr; SHIFT_TEMPS /* Pre-zero output coefficient block. */ MEMZERO(data, SIZEOF(DCTELEM) * DCTSIZE2); /* Pass 1: process rows. - * Note results are scaled up by sqrt(8) compared to a true DCT; - * furthermore, we scale the results by 2**PASS1_BITS. - * We must also scale the output by (8/4)*(8/2) = 2**3, which we add here. + * Note results are scaled up by sqrt(8) compared to a true DCT. * 4-point FDCT kernel, * cK represents sqrt(2) * cos(K*pi/16) [refers to 8-point FDCT]. */ - dataptr = data; - for (ctr = 0; ctr < 2; ctr++) { - elemptr = sample_data[ctr] + start_col; + /* Row 0 */ + elemptr = sample_data[0] + start_col; - /* Even part */ + /* Even part */ - tmp0 = GETJSAMPLE(elemptr[0]) + GETJSAMPLE(elemptr[3]); - tmp1 = GETJSAMPLE(elemptr[1]) + GETJSAMPLE(elemptr[2]); + tmp4 = GETJSAMPLE(elemptr[0]) + GETJSAMPLE(elemptr[3]); + tmp5 = GETJSAMPLE(elemptr[1]) + GETJSAMPLE(elemptr[2]); - tmp10 = GETJSAMPLE(elemptr[0]) - GETJSAMPLE(elemptr[3]); - tmp11 = GETJSAMPLE(elemptr[1]) - GETJSAMPLE(elemptr[2]); + tmp0 = tmp4 + tmp5; + tmp2 = tmp4 - tmp5; - /* Apply unsigned->signed conversion. */ - dataptr[0] = (DCTELEM) - ((tmp0 + tmp1 - 4 * CENTERJSAMPLE) << (PASS1_BITS+3)); - dataptr[2] = (DCTELEM) ((tmp0 - tmp1) << (PASS1_BITS+3)); + /* Odd part */ - /* Odd part */ + z2 = GETJSAMPLE(elemptr[0]) - GETJSAMPLE(elemptr[3]); + z3 = GETJSAMPLE(elemptr[1]) - GETJSAMPLE(elemptr[2]); - tmp0 = MULTIPLY(tmp10 + tmp11, FIX_0_541196100); /* c6 */ - /* Add fudge factor here for final descale. */ - tmp0 += ONE << (CONST_BITS-PASS1_BITS-4); + z1 = MULTIPLY(z2 + z3, FIX_0_541196100); /* c6 */ + /* Add fudge factor here for final descale. */ + z1 += ONE << (CONST_BITS-3-1); + tmp1 = z1 + MULTIPLY(z2, FIX_0_765366865); /* c2-c6 */ + tmp3 = z1 - MULTIPLY(z3, FIX_1_847759065); /* c2+c6 */ - dataptr[1] = (DCTELEM) - RIGHT_SHIFT(tmp0 + MULTIPLY(tmp10, FIX_0_765366865), /* c2-c6 */ - CONST_BITS-PASS1_BITS-3); - dataptr[3] = (DCTELEM) - RIGHT_SHIFT(tmp0 - MULTIPLY(tmp11, FIX_1_847759065), /* c2+c6 */ - CONST_BITS-PASS1_BITS-3); + /* Row 1 */ + elemptr = sample_data[1] + start_col; - dataptr += DCTSIZE; /* advance pointer to next row */ - } + /* Even part */ - /* Pass 2: process columns. - * We remove the PASS1_BITS scaling, but leave the results scaled up - * by an overall factor of 8. - */ + tmp4 = GETJSAMPLE(elemptr[0]) + GETJSAMPLE(elemptr[3]); + tmp5 = GETJSAMPLE(elemptr[1]) + GETJSAMPLE(elemptr[2]); - dataptr = data; - for (ctr = 0; ctr < 4; ctr++) { - /* Even part */ + tmp10 = tmp4 + tmp5; + tmp12 = tmp4 - tmp5; - /* Add fudge factor here for final descale. */ - tmp0 = dataptr[DCTSIZE*0] + (ONE << (PASS1_BITS-1)); - tmp1 = dataptr[DCTSIZE*1]; + /* Odd part */ - dataptr[DCTSIZE*0] = (DCTELEM) RIGHT_SHIFT(tmp0 + tmp1, PASS1_BITS); + z2 = GETJSAMPLE(elemptr[0]) - GETJSAMPLE(elemptr[3]); + z3 = GETJSAMPLE(elemptr[1]) - GETJSAMPLE(elemptr[2]); - /* Odd part */ + z1 = MULTIPLY(z2 + z3, FIX_0_541196100); /* c6 */ + tmp11 = z1 + MULTIPLY(z2, FIX_0_765366865); /* c2-c6 */ + tmp13 = z1 - MULTIPLY(z3, FIX_1_847759065); /* c2+c6 */ - dataptr[DCTSIZE*1] = (DCTELEM) RIGHT_SHIFT(tmp0 - tmp1, PASS1_BITS); + /* Pass 2: process columns. + * We leave the results scaled up by an overall factor of 8. + * We must also scale the output by (8/4)*(8/2) = 2**3. + */ - dataptr++; /* advance pointer to next column */ - } + /* Column 0 */ + /* Apply unsigned->signed conversion. */ + data[DCTSIZE*0] = (tmp0 + tmp10 - 8 * CENTERJSAMPLE) << 3; + data[DCTSIZE*1] = (tmp0 - tmp10) << 3; + + /* Column 1 */ + data[DCTSIZE*0+1] = (DCTELEM) RIGHT_SHIFT(tmp1 + tmp11, CONST_BITS-3); + data[DCTSIZE*1+1] = (DCTELEM) RIGHT_SHIFT(tmp1 - tmp11, CONST_BITS-3); + + /* Column 2 */ + data[DCTSIZE*0+2] = (tmp2 + tmp12) << 3; + data[DCTSIZE*1+2] = (tmp2 - tmp12) << 3; + + /* Column 3 */ + data[DCTSIZE*0+3] = (DCTELEM) RIGHT_SHIFT(tmp3 + tmp13, CONST_BITS-3); + data[DCTSIZE*1+3] = (DCTELEM) RIGHT_SHIFT(tmp3 - tmp13, CONST_BITS-3); } @@ -4312,7 +4318,6 @@ jpeg_fdct_2x4 (DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col) /* Pass 1: process rows. * Note results are scaled up by sqrt(8) compared to a true DCT. - * We must also scale the output by (8/2)*(8/4) = 2**3, which we add here. */ dataptr = data; @@ -4325,17 +4330,18 @@ jpeg_fdct_2x4 (DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col) tmp1 = GETJSAMPLE(elemptr[1]); /* Apply unsigned->signed conversion. */ - dataptr[0] = (DCTELEM) ((tmp0 + tmp1 - 2 * CENTERJSAMPLE) << 3); + dataptr[0] = (DCTELEM) (tmp0 + tmp1 - 2 * CENTERJSAMPLE); /* Odd part */ - dataptr[1] = (DCTELEM) ((tmp0 - tmp1) << 3); + dataptr[1] = (DCTELEM) (tmp0 - tmp1); dataptr += DCTSIZE; /* advance pointer to next row */ } /* Pass 2: process columns. * We leave the results scaled up by an overall factor of 8. + * We must also scale the output by (8/2)*(8/4) = 2**3. * 4-point FDCT kernel, * cK represents sqrt(2) * cos(K*pi/16) [refers to 8-point FDCT]. */ @@ -4350,21 +4356,21 @@ jpeg_fdct_2x4 (DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col) tmp10 = dataptr[DCTSIZE*0] - dataptr[DCTSIZE*3]; tmp11 = dataptr[DCTSIZE*1] - dataptr[DCTSIZE*2]; - dataptr[DCTSIZE*0] = (DCTELEM) (tmp0 + tmp1); - dataptr[DCTSIZE*2] = (DCTELEM) (tmp0 - tmp1); + dataptr[DCTSIZE*0] = (DCTELEM) ((tmp0 + tmp1) << 3); + dataptr[DCTSIZE*2] = (DCTELEM) ((tmp0 - tmp1) << 3); /* Odd part */ tmp0 = MULTIPLY(tmp10 + tmp11, FIX_0_541196100); /* c6 */ /* Add fudge factor here for final descale. */ - tmp0 += ONE << (CONST_BITS-1); + tmp0 += ONE << (CONST_BITS-3-1); dataptr[DCTSIZE*1] = (DCTELEM) RIGHT_SHIFT(tmp0 + MULTIPLY(tmp10, FIX_0_765366865), /* c2-c6 */ - CONST_BITS); + CONST_BITS-3); dataptr[DCTSIZE*3] = (DCTELEM) RIGHT_SHIFT(tmp0 - MULTIPLY(tmp11, FIX_1_847759065), /* c2+c6 */ - CONST_BITS); + CONST_BITS-3); dataptr++; /* advance pointer to next column */ } diff --git a/external/jpeg-9c/jidctflt.c b/external/jpeg-9d/jidctflt.c similarity index 100% rename from external/jpeg-9c/jidctflt.c rename to external/jpeg-9d/jidctflt.c diff --git a/external/jpeg-9c/jidctfst.S b/external/jpeg-9d/jidctfst.S similarity index 100% rename from external/jpeg-9c/jidctfst.S rename to external/jpeg-9d/jidctfst.S diff --git a/external/jpeg-9c/jidctfst.c b/external/jpeg-9d/jidctfst.c similarity index 100% rename from external/jpeg-9c/jidctfst.c rename to external/jpeg-9d/jidctfst.c diff --git a/external/jpeg-9c/jidctint.c b/external/jpeg-9d/jidctint.c similarity index 99% rename from external/jpeg-9c/jidctint.c rename to external/jpeg-9d/jidctint.c index 6437079a..e30ec8c8 100644 --- a/external/jpeg-9c/jidctint.c +++ b/external/jpeg-9d/jidctint.c @@ -2,7 +2,7 @@ * jidctint.c * * Copyright (C) 1991-1998, Thomas G. Lane. - * Modification developed 2002-2016 by Guido Vollbeding. + * Modification developed 2002-2018 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -1474,7 +1474,7 @@ jpeg_idct_10x10 (j_decompress_ptr cinfo, jpeg_component_info * compptr, /* * Perform dequantization and inverse DCT on one block of coefficients, - * producing a 11x11 output block. + * producing an 11x11 output block. * * Optimized algorithm with 24 multiplications in the 1-D kernel. * cK represents sqrt(2) * cos(K*pi/22). @@ -3675,7 +3675,7 @@ jpeg_idct_10x5 (j_decompress_ptr cinfo, jpeg_component_info * compptr, /* * Perform dequantization and inverse DCT on one block of coefficients, - * producing a 8x4 output block. + * producing an 8x4 output block. * * 4-point IDCT in pass 1 (columns), 8-point in pass 2 (rows). */ @@ -3835,7 +3835,7 @@ jpeg_idct_8x4 (j_decompress_ptr cinfo, jpeg_component_info * compptr, /* * Perform dequantization and inverse DCT on one block of coefficients, - * producing a reduced-size 6x3 output block. + * producing a 6x3 output block. * * 3-point IDCT in pass 1 (columns), 6-point in pass 2 (rows). */ @@ -4082,7 +4082,7 @@ jpeg_idct_2x1 (j_decompress_ptr cinfo, jpeg_component_info * compptr, /* * Perform dequantization and inverse DCT on one block of coefficients, - * producing a 8x16 output block. + * producing an 8x16 output block. * * 16-point IDCT in pass 1 (columns), 8-point in pass 2 (rows). */ @@ -5004,7 +5004,7 @@ jpeg_idct_4x8 (j_decompress_ptr cinfo, jpeg_component_info * compptr, /* * Perform dequantization and inverse DCT on one block of coefficients, - * producing a reduced-size 3x6 output block. + * producing a 3x6 output block. * * 6-point IDCT in pass 1 (columns), 3-point in pass 2 (rows). */ diff --git a/external/jpeg-9c/jinclude.h b/external/jpeg-9d/jinclude.h similarity index 100% rename from external/jpeg-9c/jinclude.h rename to external/jpeg-9d/jinclude.h diff --git a/external/jpeg-9c/jmem-android.c b/external/jpeg-9d/jmem-android.c similarity index 100% rename from external/jpeg-9c/jmem-android.c rename to external/jpeg-9d/jmem-android.c diff --git a/external/jpeg-9c/jmemansi.c b/external/jpeg-9d/jmemansi.c similarity index 100% rename from external/jpeg-9c/jmemansi.c rename to external/jpeg-9d/jmemansi.c diff --git a/external/jpeg-9c/jmemdos.c b/external/jpeg-9d/jmemdos.c similarity index 100% rename from external/jpeg-9c/jmemdos.c rename to external/jpeg-9d/jmemdos.c diff --git a/external/jpeg-9c/jmemdosa.asm b/external/jpeg-9d/jmemdosa.asm similarity index 100% rename from external/jpeg-9c/jmemdosa.asm rename to external/jpeg-9d/jmemdosa.asm diff --git a/external/jpeg-9c/jmemmac.c b/external/jpeg-9d/jmemmac.c similarity index 100% rename from external/jpeg-9c/jmemmac.c rename to external/jpeg-9d/jmemmac.c diff --git a/external/jpeg-9c/jmemmgr.c b/external/jpeg-9d/jmemmgr.c similarity index 96% rename from external/jpeg-9c/jmemmgr.c rename to external/jpeg-9d/jmemmgr.c index 0a137cdd..40377de4 100644 --- a/external/jpeg-9c/jmemmgr.c +++ b/external/jpeg-9d/jmemmgr.c @@ -2,7 +2,7 @@ * jmemmgr.c * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2011-2012 by Guido Vollbeding. + * Modified 2011-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -130,7 +130,7 @@ typedef struct { jvirt_barray_ptr virt_barray_list; /* This counts total space obtained from jpeg_get_small/large */ - long total_space_allocated; + size_t total_space_allocated; /* alloc_sarray and alloc_barray set this value for use by virtual * array routines. @@ -195,7 +195,7 @@ print_mem_stats (j_common_ptr cinfo, int pool_id) * This is helpful because message parm array can't handle longs. */ fprintf(stderr, "Freeing pool %d, total space = %ld\n", - pool_id, mem->total_space_allocated); + pool_id, (long) mem->total_space_allocated); for (lhdr_ptr = mem->large_list[pool_id]; lhdr_ptr != NULL; lhdr_ptr = lhdr_ptr->hdr.next) { @@ -260,11 +260,11 @@ alloc_small (j_common_ptr cinfo, int pool_id, size_t sizeofobject) { my_mem_ptr mem = (my_mem_ptr) cinfo->mem; small_pool_ptr hdr_ptr, prev_hdr_ptr; - char * data_ptr; size_t odd_bytes, min_request, slop; + char * data_ptr; /* Check for unsatisfiable request (do now to ensure no overflow below) */ - if (sizeofobject > (size_t) (MAX_ALLOC_CHUNK-SIZEOF(small_pool_hdr))) + if (sizeofobject > (size_t) MAX_ALLOC_CHUNK - SIZEOF(small_pool_hdr)) out_of_memory(cinfo, 1); /* request exceeds malloc's ability */ /* Round up the requested size to a multiple of SIZEOF(ALIGN_TYPE) */ @@ -293,8 +293,8 @@ alloc_small (j_common_ptr cinfo, int pool_id, size_t sizeofobject) else slop = extra_pool_slop[pool_id]; /* Don't ask for more than MAX_ALLOC_CHUNK */ - if (slop > (size_t) (MAX_ALLOC_CHUNK-min_request)) - slop = (size_t) (MAX_ALLOC_CHUNK-min_request); + if (slop > (size_t) MAX_ALLOC_CHUNK - min_request) + slop = (size_t) MAX_ALLOC_CHUNK - min_request; /* Try to get space, if fail reduce slop and try again */ for (;;) { hdr_ptr = (small_pool_ptr) jpeg_get_small(cinfo, min_request + slop); @@ -348,7 +348,7 @@ alloc_large (j_common_ptr cinfo, int pool_id, size_t sizeofobject) size_t odd_bytes; /* Check for unsatisfiable request (do now to ensure no overflow below) */ - if (sizeofobject > (size_t) (MAX_ALLOC_CHUNK-SIZEOF(large_pool_hdr))) + if (sizeofobject > (size_t) MAX_ALLOC_CHUNK - SIZEOF(large_pool_hdr)) out_of_memory(cinfo, 3); /* request exceeds malloc's ability */ /* Round up the requested size to a multiple of SIZEOF(ALIGN_TYPE) */ @@ -404,7 +404,7 @@ alloc_sarray (j_common_ptr cinfo, int pool_id, long ltemp; /* Calculate max # of rows allowed in one allocation chunk */ - ltemp = (MAX_ALLOC_CHUNK-SIZEOF(large_pool_hdr)) / + ltemp = (MAX_ALLOC_CHUNK - SIZEOF(large_pool_hdr)) / ((long) samplesperrow * SIZEOF(JSAMPLE)); if (ltemp <= 0) ERREXIT(cinfo, JERR_WIDTH_OVERFLOW); @@ -416,15 +416,14 @@ alloc_sarray (j_common_ptr cinfo, int pool_id, /* Get space for row pointers (small object) */ result = (JSAMPARRAY) alloc_small(cinfo, pool_id, - (size_t) (numrows * SIZEOF(JSAMPROW))); + (size_t) numrows * SIZEOF(JSAMPROW)); /* Get the rows themselves (large objects) */ currow = 0; while (currow < numrows) { rowsperchunk = MIN(rowsperchunk, numrows - currow); workspace = (JSAMPROW) alloc_large(cinfo, pool_id, - (size_t) ((size_t) rowsperchunk * (size_t) samplesperrow - * SIZEOF(JSAMPLE))); + (size_t) rowsperchunk * (size_t) samplesperrow * SIZEOF(JSAMPLE)); for (i = rowsperchunk; i > 0; i--) { result[currow++] = workspace; workspace += samplesperrow; @@ -452,7 +451,7 @@ alloc_barray (j_common_ptr cinfo, int pool_id, long ltemp; /* Calculate max # of rows allowed in one allocation chunk */ - ltemp = (MAX_ALLOC_CHUNK-SIZEOF(large_pool_hdr)) / + ltemp = (MAX_ALLOC_CHUNK - SIZEOF(large_pool_hdr)) / ((long) blocksperrow * SIZEOF(JBLOCK)); if (ltemp <= 0) ERREXIT(cinfo, JERR_WIDTH_OVERFLOW); @@ -464,15 +463,14 @@ alloc_barray (j_common_ptr cinfo, int pool_id, /* Get space for row pointers (small object) */ result = (JBLOCKARRAY) alloc_small(cinfo, pool_id, - (size_t) (numrows * SIZEOF(JBLOCKROW))); + (size_t) numrows * SIZEOF(JBLOCKROW)); /* Get the rows themselves (large objects) */ currow = 0; while (currow < numrows) { rowsperchunk = MIN(rowsperchunk, numrows - currow); workspace = (JBLOCKROW) alloc_large(cinfo, pool_id, - (size_t) ((size_t) rowsperchunk * (size_t) blocksperrow - * SIZEOF(JBLOCK))); + (size_t) rowsperchunk * (size_t) blocksperrow * SIZEOF(JBLOCK)); for (i = rowsperchunk; i > 0; i--) { result[currow++] = workspace; workspace += blocksperrow; @@ -585,8 +583,8 @@ realize_virt_arrays (j_common_ptr cinfo) /* Allocate the in-memory buffers for any unrealized virtual arrays */ { my_mem_ptr mem = (my_mem_ptr) cinfo->mem; - long space_per_minheight, maximum_space, avail_mem; - long minheights, max_minheights; + long bytesperrow, space_per_minheight, maximum_space; + long avail_mem, minheights, max_minheights; jvirt_sarray_ptr sptr; jvirt_barray_ptr bptr; @@ -598,18 +596,16 @@ realize_virt_arrays (j_common_ptr cinfo) maximum_space = 0; for (sptr = mem->virt_sarray_list; sptr != NULL; sptr = sptr->next) { if (sptr->mem_buffer == NULL) { /* if not realized yet */ - space_per_minheight += (long) sptr->maxaccess * - (long) sptr->samplesperrow * SIZEOF(JSAMPLE); - maximum_space += (long) sptr->rows_in_array * - (long) sptr->samplesperrow * SIZEOF(JSAMPLE); + bytesperrow = (long) sptr->samplesperrow * SIZEOF(JSAMPLE); + space_per_minheight += (long) sptr->maxaccess * bytesperrow; + maximum_space += (long) sptr->rows_in_array * bytesperrow; } } for (bptr = mem->virt_barray_list; bptr != NULL; bptr = bptr->next) { if (bptr->mem_buffer == NULL) { /* if not realized yet */ - space_per_minheight += (long) bptr->maxaccess * - (long) bptr->blocksperrow * SIZEOF(JBLOCK); - maximum_space += (long) bptr->rows_in_array * - (long) bptr->blocksperrow * SIZEOF(JBLOCK); + bytesperrow = (long) bptr->blocksperrow * SIZEOF(JBLOCK); + space_per_minheight += (long) bptr->maxaccess * bytesperrow; + maximum_space += (long) bptr->rows_in_array * bytesperrow; } } @@ -618,7 +614,7 @@ realize_virt_arrays (j_common_ptr cinfo) /* Determine amount of memory to actually use; this is system-dependent. */ avail_mem = jpeg_mem_available(cinfo, space_per_minheight, maximum_space, - mem->total_space_allocated); + (long) mem->total_space_allocated); /* If the maximum space needed is available, make all the buffers full * height; otherwise parcel it out with the same number of minheights @@ -694,7 +690,7 @@ do_sarray_io (j_common_ptr cinfo, jvirt_sarray_ptr ptr, boolean writing) long bytesperrow, file_offset, byte_count, rows, thisrow, i; bytesperrow = (long) ptr->samplesperrow * SIZEOF(JSAMPLE); - file_offset = ptr->cur_start_row * bytesperrow; + file_offset = (long) ptr->cur_start_row * bytesperrow; /* Loop to read or write each allocation chunk in mem_buffer */ for (i = 0; i < (long) ptr->rows_in_mem; i += ptr->rowsperchunk) { /* One chunk, but check for short chunk at end of buffer */ @@ -727,7 +723,7 @@ do_barray_io (j_common_ptr cinfo, jvirt_barray_ptr ptr, boolean writing) long bytesperrow, file_offset, byte_count, rows, thisrow, i; bytesperrow = (long) ptr->blocksperrow * SIZEOF(JBLOCK); - file_offset = ptr->cur_start_row * bytesperrow; + file_offset = (long) ptr->cur_start_row * bytesperrow; /* Loop to read or write each allocation chunk in mem_buffer */ for (i = 0; i < (long) ptr->rows_in_mem; i += ptr->rowsperchunk) { /* One chunk, but check for short chunk at end of buffer */ @@ -771,7 +767,7 @@ access_virt_sarray (j_common_ptr cinfo, jvirt_sarray_ptr ptr, /* Make the desired part of the virtual array accessible */ if (start_row < ptr->cur_start_row || - end_row > ptr->cur_start_row+ptr->rows_in_mem) { + end_row > ptr->cur_start_row + ptr->rows_in_mem) { if (! ptr->b_s_open) ERREXIT(cinfo, JERR_VIRTUAL_BUG); /* Flush old buffer contents if necessary */ @@ -856,7 +852,7 @@ access_virt_barray (j_common_ptr cinfo, jvirt_barray_ptr ptr, /* Make the desired part of the virtual array accessible */ if (start_row < ptr->cur_start_row || - end_row > ptr->cur_start_row+ptr->rows_in_mem) { + end_row > ptr->cur_start_row + ptr->rows_in_mem) { if (! ptr->b_s_open) ERREXIT(cinfo, JERR_VIRTUAL_BUG); /* Flush old buffer contents if necessary */ @@ -1093,7 +1089,7 @@ jinit_memory_mgr (j_common_ptr cinfo) mem->total_space_allocated = SIZEOF(my_memory_mgr); /* Declare ourselves open for business */ - cinfo->mem = & mem->pub; + cinfo->mem = &mem->pub; /* Check for an environment variable JPEGMEM; if found, override the * default max_memory setting from jpeg_mem_init. Note that the diff --git a/external/jpeg-9c/jmemname.c b/external/jpeg-9d/jmemname.c similarity index 100% rename from external/jpeg-9c/jmemname.c rename to external/jpeg-9d/jmemname.c diff --git a/external/jpeg-9c/jmemnobs.c b/external/jpeg-9d/jmemnobs.c similarity index 90% rename from external/jpeg-9c/jmemnobs.c rename to external/jpeg-9d/jmemnobs.c index eb8c3377..a364cd82 100644 --- a/external/jpeg-9c/jmemnobs.c +++ b/external/jpeg-9d/jmemnobs.c @@ -2,6 +2,7 @@ * jmemnobs.c * * Copyright (C) 1992-1996, Thomas G. Lane. + * Modified 2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -12,7 +13,7 @@ * This is very portable in the sense that it'll compile on almost anything, * but you'd better have lots of main memory (or virtual memory) if you want * to process big images. - * Note that the max_memory_to_use option is ignored by this implementation. + * Note that the max_memory_to_use option is respected by this implementation. */ #define JPEG_INTERNALS @@ -66,13 +67,16 @@ jpeg_free_large (j_common_ptr cinfo, void FAR * object, size_t sizeofobject) /* * This routine computes the total memory space available for allocation. - * Here we always say, "we got all you want bud!" */ GLOBAL(long) jpeg_mem_available (j_common_ptr cinfo, long min_bytes_needed, long max_bytes_needed, long already_allocated) { + if (cinfo->mem->max_memory_to_use) + return cinfo->mem->max_memory_to_use - already_allocated; + + /* Here we say, "we got all you want bud!" */ return max_bytes_needed; } diff --git a/external/jpeg-9c/jmemsys.h b/external/jpeg-9d/jmemsys.h similarity index 100% rename from external/jpeg-9c/jmemsys.h rename to external/jpeg-9d/jmemsys.h diff --git a/external/jpeg-9c/jmorecfg.h~ b/external/jpeg-9d/jmorecfg.h similarity index 100% rename from external/jpeg-9c/jmorecfg.h~ rename to external/jpeg-9d/jmorecfg.h diff --git a/external/jpeg-9c/jpegint.h b/external/jpeg-9d/jpegint.h similarity index 98% rename from external/jpeg-9c/jpegint.h rename to external/jpeg-9d/jpegint.h index e312e1af..52c708d4 100644 --- a/external/jpeg-9c/jpegint.h +++ b/external/jpeg-9d/jpegint.h @@ -2,7 +2,7 @@ * jpegint.h * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 1997-2017 by Guido Vollbeding. + * Modified 1997-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -302,6 +302,13 @@ struct jpeg_color_quantizer { #define RIGHT_SHIFT(x,shft) ((x) >> (shft)) #endif +/* Descale and correctly round an INT32 value that's scaled by N bits. + * We assume RIGHT_SHIFT rounds towards minus infinity, so adding + * the fudge factor is correct for either sign of X. + */ + +#define DESCALE(x,n) RIGHT_SHIFT((x) + ((INT32) 1 << ((n)-1)), n) + /* Short forms of external names for systems with brain-damaged linkers. */ diff --git a/external/jpeg-9c/jpeglib.h b/external/jpeg-9d/jpeglib.h similarity index 99% rename from external/jpeg-9c/jpeglib.h rename to external/jpeg-9d/jpeglib.h index 4bd98531..591a2cb6 100644 --- a/external/jpeg-9c/jpeglib.h +++ b/external/jpeg-9d/jpeglib.h @@ -2,7 +2,7 @@ * jpeglib.h * * Copyright (C) 1991-1998, Thomas G. Lane. - * Modified 2002-2017 by Guido Vollbeding. + * Modified 2002-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -39,7 +39,7 @@ extern "C" { #define JPEG_LIB_VERSION 90 /* Compatibility version 9.0 */ #define JPEG_LIB_VERSION_MAJOR 9 -#define JPEG_LIB_VERSION_MINOR 3 +#define JPEG_LIB_VERSION_MINOR 4 /* Various constants determining the sizes of things. @@ -909,6 +909,7 @@ typedef JMETHOD(boolean, jpeg_marker_parser_method, (j_decompress_ptr cinfo)); #define jpeg_suppress_tables jSuppressTables #define jpeg_alloc_quant_table jAlcQTable #define jpeg_alloc_huff_table jAlcHTable +#define jpeg_std_huff_table jStdHTable #define jpeg_start_compress jStrtCompress #define jpeg_write_scanlines jWrtScanlines #define jpeg_finish_compress jFinCompress @@ -977,10 +978,10 @@ EXTERN(void) jpeg_stdio_src JPP((j_decompress_ptr cinfo, FILE * infile)); /* Data source and destination managers: memory buffers. */ EXTERN(void) jpeg_mem_dest JPP((j_compress_ptr cinfo, unsigned char ** outbuffer, - unsigned long * outsize)); + size_t * outsize)); EXTERN(void) jpeg_mem_src JPP((j_decompress_ptr cinfo, const unsigned char * inbuffer, - unsigned long insize)); + size_t insize)); /* Default parameter setup for compression */ EXTERN(void) jpeg_set_defaults JPP((j_compress_ptr cinfo)); @@ -1005,6 +1006,8 @@ EXTERN(void) jpeg_suppress_tables JPP((j_compress_ptr cinfo, boolean suppress)); EXTERN(JQUANT_TBL *) jpeg_alloc_quant_table JPP((j_common_ptr cinfo)); EXTERN(JHUFF_TBL *) jpeg_alloc_huff_table JPP((j_common_ptr cinfo)); +EXTERN(JHUFF_TBL *) jpeg_std_huff_table JPP((j_common_ptr cinfo, + boolean isDC, int tblno)); /* Main entry points for compression */ EXTERN(void) jpeg_start_compress JPP((j_compress_ptr cinfo, diff --git a/external/jpeg-9c/jpegtran.1 b/external/jpeg-9d/jpegtran.1 similarity index 88% rename from external/jpeg-9c/jpegtran.1 rename to external/jpeg-9d/jpegtran.1 index 4f051848..7929afdd 100644 --- a/external/jpeg-9c/jpegtran.1 +++ b/external/jpeg-9d/jpegtran.1 @@ -1,4 +1,4 @@ -.TH JPEGTRAN 1 "30 September 2017" +.TH JPEGTRAN 1 "28 August 2019" .SH NAME jpegtran \- lossless transformation of JPEG files .SH SYNOPSIS @@ -169,12 +169,20 @@ region dimensions to keep the lower right crop corner unchanged. (Thus, the output image covers at least the requested region, but may cover more.) The adjustment of the region dimensions may be optionally disabled by attaching an 'f' character ("force") to the width or height number. - +.PP The image can be losslessly cropped by giving the switch: .TP .B \-crop WxH+X+Y Crop to a rectangular subarea of width W, height H starting at point X,Y. .PP +Crop extension: The width or height parameters can be made larger than the +source image. In this case the extra area is filled in with zero (neutral +gray). A larger width parameter has two more options: Attaching an 'f' +character ("flatten") to the width number will fill in the extra area with +the DC of the adjacent block, instead of gray out. Attaching an 'r' +character ("reflect") to the width number will fill in the extra area with +repeated reflections of the source region, instead of gray out. +.PP A complementary lossless-wipe option is provided to discard (gray out) data inside a given image region while losslessly preserving what is outside: .TP @@ -182,8 +190,22 @@ inside a given image region while losslessly preserving what is outside: Wipe (gray out) a rectangular subarea of width W, height H starting at point X,Y. .PP -Attaching an 'f' character ("flatten") to the width number will fill -the region with the average of adjacent blocks, instead of gray out. +Attaching an 'f' character ("flatten") to the width number will fill the +region with the average of adjacent blocks, instead of gray out. In case +the wipe region and outside area form two horizontally adjacent rectangles, +attaching an 'r' character ("reflect") to the width number will fill the +region with repeated reflections of the outside area, instead of gray out. +.PP +Another option is lossless-drop, which replaces data at a given image +position by another image: +.TP +.B \-drop +X+Y filename +Drop another image +.PP +Both source images must have the same subsampling values. It is best if +they also have the same quantization, otherwise quantization adaption occurs. +The trim option can be used with the drop option to requantize the drop file +to the source file. .PP Other not-strictly-lossless transformation switches are: .TP diff --git a/external/jpeg-9c/jpegtran.c b/external/jpeg-9d/jpegtran.c similarity index 86% rename from external/jpeg-9c/jpegtran.c rename to external/jpeg-9d/jpegtran.c index 5269344e..bfaa8aca 100644 --- a/external/jpeg-9c/jpegtran.c +++ b/external/jpeg-9d/jpegtran.c @@ -1,7 +1,7 @@ /* * jpegtran.c * - * Copyright (C) 1995-2013, Thomas G. Lane, Guido Vollbeding. + * Copyright (C) 1995-2019, Thomas G. Lane, Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -37,6 +37,7 @@ static const char * progname; /* program name for error messages */ static char * outfilename; /* for -outfile switch */ +static char * dropfilename; /* for -drop switch */ static char * scaleoption; /* -scale switch */ static JCOPY_OPTION copyoption; /* -copy switch */ static jpeg_transform_info transformoption; /* image transformation options */ @@ -66,6 +67,7 @@ usage (void) fprintf(stderr, "Switches for modifying the image:\n"); #if TRANSFORMS_SUPPORTED fprintf(stderr, " -crop WxH+X+Y Crop to a rectangular subarea\n"); + fprintf(stderr, " -drop +X+Y filename Drop another image\n"); fprintf(stderr, " -flip [horizontal|vertical] Mirror image (left-right or top-bottom)\n"); fprintf(stderr, " -grayscale Reduce to grayscale (omit color data)\n"); fprintf(stderr, " -perfect Fail if there is non-transformable edge blocks\n"); @@ -76,6 +78,7 @@ usage (void) fprintf(stderr, " -transpose Transpose image\n"); fprintf(stderr, " -transverse Transverse transpose image\n"); fprintf(stderr, " -trim Drop non-transformable edge blocks\n"); + fprintf(stderr, " with -drop: Requantize drop file to source file\n"); fprintf(stderr, " -wipe WxH+X+Y Wipe (gray out) a rectangular subarea\n"); #endif fprintf(stderr, "Switches for advanced users:\n"); @@ -188,7 +191,7 @@ parse_switches (j_compress_ptr cinfo, int argc, char **argv, #if TRANSFORMS_SUPPORTED if (++argn >= argc) /* advance to next argument */ usage(); - if (transformoption.crop /* reject multiple crop/wipe requests */ || + if (transformoption.crop /* reject multiple crop/drop/wipe requests */ || ! jtransform_parse_crop_spec(&transformoption, argv[argn])) { fprintf(stderr, "%s: bogus -crop argument '%s'\n", progname, argv[argn]); @@ -198,6 +201,26 @@ parse_switches (j_compress_ptr cinfo, int argc, char **argv, select_transform(JXFORM_NONE); /* force an error */ #endif + } else if (keymatch(arg, "drop", 2)) { +#if TRANSFORMS_SUPPORTED + if (++argn >= argc) /* advance to next argument */ + usage(); + if (transformoption.crop /* reject multiple crop/drop/wipe requests */ || + ! jtransform_parse_crop_spec(&transformoption, argv[argn]) || + transformoption.crop_width_set != JCROP_UNSET || + transformoption.crop_height_set != JCROP_UNSET) { + fprintf(stderr, "%s: bogus -drop argument '%s'\n", + progname, argv[argn]); + exit(EXIT_FAILURE); + } + if (++argn >= argc) /* advance to next argument */ + usage(); + dropfilename = argv[argn]; + select_transform(JXFORM_DROP); +#else + select_transform(JXFORM_NONE); /* force an error */ +#endif + } else if (keymatch(arg, "debug", 1) || keymatch(arg, "verbose", 1)) { /* Enable debug printouts. */ /* On first -d, print version identification */ @@ -342,7 +365,7 @@ parse_switches (j_compress_ptr cinfo, int argc, char **argv, #if TRANSFORMS_SUPPORTED if (++argn >= argc) /* advance to next argument */ usage(); - if (transformoption.crop /* reject multiple crop/wipe requests */ || + if (transformoption.crop /* reject multiple crop/drop/wipe requests */ || ! jtransform_parse_crop_spec(&transformoption, argv[argn])) { fprintf(stderr, "%s: bogus -wipe argument '%s'\n", progname, argv[argn]); @@ -386,8 +409,14 @@ int main (int argc, char **argv) { struct jpeg_decompress_struct srcinfo; + struct jpeg_error_mgr jsrcerr; +#if TRANSFORMS_SUPPORTED + struct jpeg_decompress_struct dropinfo; + struct jpeg_error_mgr jdroperr; + FILE * drop_file; +#endif struct jpeg_compress_struct dstinfo; - struct jpeg_error_mgr jsrcerr, jdsterr; + struct jpeg_error_mgr jdsterr; #ifdef PROGRESS_REPORT struct cdjpeg_progress_mgr progress; #endif @@ -427,7 +456,7 @@ main (int argc, char **argv) * values read here are mostly ignored; we will rescan the switches after * opening the input file. Also note that most of the switches affect the * destination JPEG object, so we parse into that and then copy over what - * needs to affects the source too. + * needs to affect the source too. */ file_index = parse_switches(&dstinfo, argc, argv, 0, FALSE); @@ -469,6 +498,21 @@ main (int argc, char **argv) fp = read_stdin(); } +#if TRANSFORMS_SUPPORTED + /* Open the drop file. */ + if (dropfilename != NULL) { + if ((drop_file = fopen(dropfilename, READ_BINARY)) == NULL) { + fprintf(stderr, "%s: can't open %s for reading\n", progname, dropfilename); + exit(EXIT_FAILURE); + } + dropinfo.err = jpeg_std_error(&jdroperr); + jpeg_create_decompress(&dropinfo); + jpeg_stdio_src(&dropinfo, drop_file); + } else { + drop_file = NULL; + } +#endif + #ifdef PROGRESS_REPORT start_progress_monitor((j_common_ptr) &dstinfo, &progress); #endif @@ -488,6 +532,17 @@ main (int argc, char **argv) &srcinfo.scale_num, &srcinfo.scale_denom) < 1) usage(); +#if TRANSFORMS_SUPPORTED + if (dropfilename != NULL) { + (void) jpeg_read_header(&dropinfo, TRUE); + transformoption.crop_width = dropinfo.image_width; + transformoption.crop_width_set = JCROP_POS; + transformoption.crop_height = dropinfo.image_height; + transformoption.crop_height_set = JCROP_POS; + transformoption.drop_ptr = &dropinfo; + } +#endif + /* Any space needed by a transform option must be requested before * jpeg_read_coefficients so that memory allocation will be done right. */ @@ -503,6 +558,12 @@ main (int argc, char **argv) /* Read source file as DCT coefficients */ src_coef_arrays = jpeg_read_coefficients(&srcinfo); +#if TRANSFORMS_SUPPORTED + if (dropfilename != NULL) { + transformoption.drop_coef_arrays = jpeg_read_coefficients(&dropinfo); + } +#endif + /* Initialize destination compression parameters from source values */ jpeg_copy_critical_parameters(&srcinfo, &dstinfo); @@ -560,18 +621,34 @@ main (int argc, char **argv) /* Finish compression and release memory */ jpeg_finish_compress(&dstinfo); jpeg_destroy_compress(&dstinfo); +#if TRANSFORMS_SUPPORTED + if (dropfilename != NULL) { + (void) jpeg_finish_decompress(&dropinfo); + jpeg_destroy_decompress(&dropinfo); + } +#endif (void) jpeg_finish_decompress(&srcinfo); jpeg_destroy_decompress(&srcinfo); /* Close output file, if we opened it */ if (fp != stdout) fclose(fp); +#if TRANSFORMS_SUPPORTED + if (drop_file != NULL) + fclose(drop_file); +#endif #ifdef PROGRESS_REPORT end_progress_monitor((j_common_ptr) &dstinfo); #endif /* All done. */ - exit(jsrcerr.num_warnings + jdsterr.num_warnings ?EXIT_WARNING:EXIT_SUCCESS); - return 0; /* suppress no-return-value warnings */ +#if TRANSFORMS_SUPPORTED + if (dropfilename != NULL) + exit(jsrcerr.num_warnings + jdroperr.num_warnings + + jdsterr.num_warnings ? EXIT_WARNING : EXIT_SUCCESS); +#endif + exit(jsrcerr.num_warnings + jdsterr.num_warnings ? + EXIT_WARNING : EXIT_SUCCESS); + return 0; /* suppress no-return-value warnings */ } diff --git a/external/jpeg-9c/jquant1.c b/external/jpeg-9d/jquant1.c similarity index 100% rename from external/jpeg-9c/jquant1.c rename to external/jpeg-9d/jquant1.c diff --git a/external/jpeg-9c/jquant2.c b/external/jpeg-9d/jquant2.c similarity index 100% rename from external/jpeg-9c/jquant2.c rename to external/jpeg-9d/jquant2.c diff --git a/external/jpeg-9c/jutils.c b/external/jpeg-9d/jutils.c similarity index 97% rename from external/jpeg-9c/jutils.c rename to external/jpeg-9d/jutils.c index 5b16b6d0..1e2dfb01 100644 --- a/external/jpeg-9c/jutils.c +++ b/external/jpeg-9d/jutils.c @@ -2,7 +2,7 @@ * jutils.c * * Copyright (C) 1991-1996, Thomas G. Lane. - * Modified 2009-2011 by Guido Vollbeding. + * Modified 2009-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -185,7 +185,7 @@ jcopy_sample_rows (JSAMPARRAY input_array, int source_row, { register JSAMPROW inptr, outptr; #ifdef FMEMCOPY - register size_t count = (size_t) (num_cols * SIZEOF(JSAMPLE)); + register size_t count = (size_t) num_cols * SIZEOF(JSAMPLE); #else register JDIMENSION count; #endif @@ -213,7 +213,7 @@ jcopy_block_row (JBLOCKROW input_row, JBLOCKROW output_row, /* Copy a row of coefficient blocks from one place to another. */ { #ifdef FMEMCOPY - FMEMCOPY(output_row, input_row, num_blocks * (DCTSIZE2 * SIZEOF(JCOEF))); + FMEMCOPY(output_row, input_row, (size_t) num_blocks * (DCTSIZE2 * SIZEOF(JCOEF))); #else register JCOEFPTR inptr, outptr; register long count; diff --git a/external/jpeg-9c/jversion.h b/external/jpeg-9d/jversion.h similarity index 59% rename from external/jpeg-9c/jversion.h rename to external/jpeg-9d/jversion.h index d096384f..c9befacd 100644 --- a/external/jpeg-9c/jversion.h +++ b/external/jpeg-9d/jversion.h @@ -1,7 +1,7 @@ /* * jversion.h * - * Copyright (C) 1991-2018, Thomas G. Lane, Guido Vollbeding. + * Copyright (C) 1991-2020, Thomas G. Lane, Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -9,6 +9,6 @@ */ -#define JVERSION "9c 14-Jan-2018" +#define JVERSION "9d 12-Jan-2020" -#define JCOPYRIGHT "Copyright (C) 2018, Thomas G. Lane, Guido Vollbeding" +#define JCOPYRIGHT "Copyright (C) 2020, Thomas G. Lane, Guido Vollbeding" diff --git a/external/jpeg-9c/libjpeg.map b/external/jpeg-9d/libjpeg.map similarity index 100% rename from external/jpeg-9c/libjpeg.map rename to external/jpeg-9d/libjpeg.map diff --git a/external/jpeg-9c/libjpeg.pc.in b/external/jpeg-9d/libjpeg.pc.in similarity index 75% rename from external/jpeg-9c/libjpeg.pc.in rename to external/jpeg-9d/libjpeg.pc.in index 271b742f..d8e738f4 100644 --- a/external/jpeg-9c/libjpeg.pc.in +++ b/external/jpeg-9d/libjpeg.pc.in @@ -5,6 +5,6 @@ includedir=@includedir@ Name: libjpeg Description: Reads and writes JPEG files -Version: @JPEG_LIB_VERSION@ +Version: @JPEG_LIB_VERSION_MAJOR@.@JPEG_LIB_VERSION_MINOR@.0 Libs: -L${libdir} -ljpeg Cflags: -I${includedir} diff --git a/external/jpeg-9c/libjpeg.txt b/external/jpeg-9d/libjpeg.txt similarity index 98% rename from external/jpeg-9c/libjpeg.txt rename to external/jpeg-9d/libjpeg.txt index 4243c246..546a86e2 100644 --- a/external/jpeg-9c/libjpeg.txt +++ b/external/jpeg-9d/libjpeg.txt @@ -1,6 +1,6 @@ USING THE IJG JPEG LIBRARY -Copyright (C) 1994-2013, Thomas G. Lane, Guido Vollbeding. +Copyright (C) 1994-2019, Thomas G. Lane, Guido Vollbeding. This file is part of the Independent JPEG Group's software. For conditions of distribution and use, see the accompanying README file. @@ -2591,8 +2591,8 @@ different sizes. If the image dimensions are not a multiple of the MCU size, you must also pad the data correctly (usually, this is done by replicating the last column and/or row). The data must be padded to a multiple of a DCT block in each component: that is, each downsampled row must contain a -multiple of block_size valid samples, and there must be a multiple of -block_size sample rows for each component. (For applications such as +multiple of DCT_h_scaled_size valid samples, and there must be a multiple of +DCT_v_scaled_size sample rows for each component. (For applications such as conversion of digital TV images, the standard image size is usually a multiple of the DCT block size, so that no padding need actually be done.) @@ -2602,8 +2602,6 @@ jpeg_write_scanlines(). Before calling jpeg_start_compress(), you must do the following: * Set cinfo->raw_data_in to TRUE. (It is set FALSE by jpeg_set_defaults().) This notifies the library that you will be supplying raw data. - Furthermore, set cinfo->do_fancy_downsampling to FALSE if you want to use - real downsampled data. (It is set TRUE by jpeg_set_defaults().) * Ensure jpeg_color_space is correct --- an explicit jpeg_set_colorspace() call is a good idea. Note that since color conversion is bypassed, in_color_space is ignored, except that jpeg_set_defaults() uses it to @@ -2620,23 +2618,25 @@ The scanlines count passed to and returned from jpeg_write_raw_data is measured in terms of the component with the largest v_samp_factor. jpeg_write_raw_data() processes one MCU row per call, which is to say -v_samp_factor*block_size sample rows of each component. The passed num_lines -value must be at least max_v_samp_factor*block_size, and the return value -will be exactly that amount (or possibly some multiple of that amount, in -future library versions). This is true even on the last call at the bottom -of the image; don't forget to pad your data as necessary. +v_samp_factor*min_DCT_v_scaled_size sample rows of each component. The passed +num_lines value must be at least max_v_samp_factor*min_DCT_v_scaled_size, and +the return value will be exactly that amount (or possibly some multiple of +that amount, in future library versions). This is true even on the last call +at the bottom of the image; don't forget to pad your data as necessary. The required dimensions of the supplied data can be computed for each component as - cinfo->comp_info[i].width_in_blocks*block_size samples per row - cinfo->comp_info[i].height_in_blocks*block_size rows in image + cinfo->comp_info[i].width_in_blocks * + cinfo->comp_info[i].DCT_h_scaled_size samples per row + cinfo->comp_info[i].height_in_blocks * + cinfo->comp_info[i].DCT_v_scaled_size rows in image after jpeg_start_compress() has initialized those fields. If the valid data is smaller than this, it must be padded appropriately. For some sampling factors and image sizes, additional dummy DCT blocks are inserted to make the image a multiple of the MCU dimensions. The library creates such dummy blocks itself; it does not read them from your supplied data. Therefore you -need never pad by more than block_size samples. An example may help here. -Assume 2h2v downsampling of YCbCr data, that is +need never pad by more than DCT_scaled_size samples. +An example may help here. Assume 2h2v downsampling of YCbCr data, that is cinfo->comp_info[0].h_samp_factor = 2 for Y cinfo->comp_info[0].v_samp_factor = 2 cinfo->comp_info[1].h_samp_factor = 1 for Cb @@ -2662,27 +2662,26 @@ destination module suspends, jpeg_write_raw_data() will return 0. In this case the same data rows must be passed again on the next call. -Decompression with raw data output implies bypassing all postprocessing. -You must deal with the color space and sampling factors present in the -incoming file. If your application only handles, say, 2h1v YCbCr data, -you must check for and fail on other color spaces or other sampling factors. +Decompression with raw data output implies bypassing all postprocessing: +you cannot ask for color quantization, for instance. More seriously, you +must deal with the color space and sampling factors present in the incoming +file. If your application only handles, say, 2h1v YCbCr data, you must +check for and fail on other color spaces or other sampling factors. The library will not convert to a different color space for you. To obtain raw data output, set cinfo->raw_data_out = TRUE before jpeg_start_decompress() (it is set FALSE by jpeg_read_header()). Be sure to verify that the color space and sampling factors are ones you can handle. -Furthermore, set cinfo->do_fancy_upsampling = FALSE if you want to get real -downsampled data (it is set TRUE by jpeg_read_header()). Then call jpeg_read_raw_data() in place of jpeg_read_scanlines(). The decompression process is otherwise the same as usual. jpeg_read_raw_data() returns one MCU row per call, and thus you must pass a -buffer of at least max_v_samp_factor*block_size scanlines (scanline counting -is the same as for raw-data compression). The buffer you pass must be large -enough to hold the actual data plus padding to DCT-block boundaries. As with -compression, any entirely dummy DCT blocks are not processed so you need not -allocate space for them, but the total scanline count includes them. The -above example of computing buffer dimensions for raw-data compression is +buffer of at least max_v_samp_factor*min_DCT_v_scaled_size scanlines (scanline +counting is the same as for raw-data compression). The buffer you pass must +be large enough to hold the actual data plus padding to DCT-block boundaries. +As with compression, any entirely dummy DCT blocks are not processed so you +need not allocate space for them, but the total scanline count includes them. +The above example of computing buffer dimensions for raw-data compression is equally valid for decompression. Input suspension is supported with raw-data decompression: if the data source diff --git a/external/jpeg-9c/ltmain.sh b/external/jpeg-9d/ltmain.sh similarity index 100% rename from external/jpeg-9c/ltmain.sh rename to external/jpeg-9d/ltmain.sh diff --git a/external/jpeg-9c/makcjpeg.st b/external/jpeg-9d/makcjpeg.st similarity index 100% rename from external/jpeg-9c/makcjpeg.st rename to external/jpeg-9d/makcjpeg.st diff --git a/external/jpeg-9c/makdjpeg.st b/external/jpeg-9d/makdjpeg.st similarity index 100% rename from external/jpeg-9c/makdjpeg.st rename to external/jpeg-9d/makdjpeg.st diff --git a/external/jpeg-9c/makeadsw.vc6 b/external/jpeg-9d/makeadsw.vc6 similarity index 100% rename from external/jpeg-9c/makeadsw.vc6 rename to external/jpeg-9d/makeadsw.vc6 diff --git a/external/jpeg-9c/makeasln.v15 b/external/jpeg-9d/makeasln.v16 similarity index 62% rename from external/jpeg-9c/makeasln.v15 rename to external/jpeg-9d/makeasln.v16 index 617d9e94..10523539 100644 --- a/external/jpeg-9c/makeasln.v15 +++ b/external/jpeg-9d/makeasln.v16 @@ -1,6 +1,8 @@ ‹¯¨ -Microsoft Visual Studio Solution File, Format Version 11.00 -# Visual C++ Express 2010 +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.28307.329 +MinimumVisualStudioVersion = 10.0.40219.1 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cjpeg", "cjpeg.vcxproj", "{2E7FAAD9-2F58-4BDE-81F2-1D6D3FB8BF57}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "djpeg", "djpeg.vcxproj", "{11043137-B453-4DFA-9010-4D2B9DC1545C}" @@ -14,20 +16,34 @@ EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Release|Win32 = Release|Win32 + Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {2E7FAAD9-2F58-4BDE-81F2-1D6D3FB8BF57}.Release|Win32.ActiveCfg = Release|Win32 {2E7FAAD9-2F58-4BDE-81F2-1D6D3FB8BF57}.Release|Win32.Build.0 = Release|Win32 + {2E7FAAD9-2F58-4BDE-81F2-1D6D3FB8BF57}.Release|x64.ActiveCfg = Release|x64 + {2E7FAAD9-2F58-4BDE-81F2-1D6D3FB8BF57}.Release|x64.Build.0 = Release|x64 {11043137-B453-4DFA-9010-4D2B9DC1545C}.Release|Win32.ActiveCfg = Release|Win32 {11043137-B453-4DFA-9010-4D2B9DC1545C}.Release|Win32.Build.0 = Release|Win32 + {11043137-B453-4DFA-9010-4D2B9DC1545C}.Release|x64.ActiveCfg = Release|x64 + {11043137-B453-4DFA-9010-4D2B9DC1545C}.Release|x64.Build.0 = Release|x64 {025BAC50-51B5-4FFE-BC47-3F920BB4047E}.Release|Win32.ActiveCfg = Release|Win32 {025BAC50-51B5-4FFE-BC47-3F920BB4047E}.Release|Win32.Build.0 = Release|Win32 + {025BAC50-51B5-4FFE-BC47-3F920BB4047E}.Release|x64.ActiveCfg = Release|x64 + {025BAC50-51B5-4FFE-BC47-3F920BB4047E}.Release|x64.Build.0 = Release|x64 {C81513DB-78DC-46BC-BC98-82E745203976}.Release|Win32.ActiveCfg = Release|Win32 {C81513DB-78DC-46BC-BC98-82E745203976}.Release|Win32.Build.0 = Release|Win32 + {C81513DB-78DC-46BC-BC98-82E745203976}.Release|x64.ActiveCfg = Release|x64 + {C81513DB-78DC-46BC-BC98-82E745203976}.Release|x64.Build.0 = Release|x64 {B57065D4-DDDA-4668-BAF5-2D49270C973C}.Release|Win32.ActiveCfg = Release|Win32 {B57065D4-DDDA-4668-BAF5-2D49270C973C}.Release|Win32.Build.0 = Release|Win32 + {B57065D4-DDDA-4668-BAF5-2D49270C973C}.Release|x64.ActiveCfg = Release|x64 + {B57065D4-DDDA-4668-BAF5-2D49270C973C}.Release|x64.Build.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {2F6B4B1E-5D02-475F-B2FE-EA2D9E697E54} + EndGlobalSection EndGlobal diff --git a/external/jpeg-9c/makecdep.vc6 b/external/jpeg-9d/makecdep.vc6 similarity index 100% rename from external/jpeg-9c/makecdep.vc6 rename to external/jpeg-9d/makecdep.vc6 diff --git a/external/jpeg-9c/makecdsp.vc6 b/external/jpeg-9d/makecdsp.vc6 similarity index 97% rename from external/jpeg-9c/makecdsp.vc6 rename to external/jpeg-9d/makecdsp.vc6 index 3ab59651..68fea836 100644 --- a/external/jpeg-9c/makecdsp.vc6 +++ b/external/jpeg-9d/makecdsp.vc6 @@ -33,8 +33,8 @@ RSC=rc.exe # PROP BASE Target_Dir ".\cjpeg" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 -# PROP Output_Dir ".\cjpeg\Release" -# PROP Intermediate_Dir ".\cjpeg\Release" +# PROP Output_Dir ".\Release" +# PROP Intermediate_Dir ".\Release\cjpeg" # PROP Ignore_Export_Lib 0 # PROP Target_Dir ".\cjpeg" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /YX /c diff --git a/external/jpeg-9c/makecfil.v15 b/external/jpeg-9d/makecfil.v16 similarity index 100% rename from external/jpeg-9c/makecfil.v15 rename to external/jpeg-9d/makecfil.v16 diff --git a/external/jpeg-9c/makecmak.vc6 b/external/jpeg-9d/makecmak.vc6 similarity index 100% rename from external/jpeg-9c/makecmak.vc6 rename to external/jpeg-9d/makecmak.vc6 diff --git a/external/jpeg-9c/makecvcx.v15 b/external/jpeg-9d/makecvcx.v16 similarity index 54% rename from external/jpeg-9c/makecvcx.v15 rename to external/jpeg-9d/makecvcx.v16 index 9ca1fb3e..90dd80e2 100644 --- a/external/jpeg-9c/makecvcx.v15 +++ b/external/jpeg-9d/makecvcx.v16 @@ -5,12 +5,16 @@ Release Win32 + + Release + x64 + {2E7FAAD9-2F58-4BDE-81F2-1D6D3FB8BF57} Win32Proj cjpeg - 10.0.16299.0 + 10.0 @@ -18,7 +22,14 @@ false true Unicode - v141 + v142 + + + Application + false + true + Unicode + v142 @@ -26,11 +37,19 @@ + + + false - $(ProjectName)\$(Configuration)\ - $(ProjectName)\$(Configuration)\ + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ + + + false + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ @@ -49,7 +68,27 @@ true true true - Release\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + $(Configuration)\$(Platform)\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + + + + + Level3 + NotUsing + Full + true + false + WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS + true + true + 4996 + + + Console + true + true + true + $(Configuration)\$(Platform)\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) diff --git a/external/jpeg-9c/makeddep.vc6 b/external/jpeg-9d/makeddep.vc6 similarity index 100% rename from external/jpeg-9c/makeddep.vc6 rename to external/jpeg-9d/makeddep.vc6 diff --git a/external/jpeg-9c/makeddsp.vc6 b/external/jpeg-9d/makeddsp.vc6 similarity index 97% rename from external/jpeg-9c/makeddsp.vc6 rename to external/jpeg-9d/makeddsp.vc6 index f583a0f6..5ff61ef6 100644 --- a/external/jpeg-9c/makeddsp.vc6 +++ b/external/jpeg-9d/makeddsp.vc6 @@ -33,8 +33,8 @@ RSC=rc.exe # PROP BASE Target_Dir ".\djpeg" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 -# PROP Output_Dir ".\djpeg\Release" -# PROP Intermediate_Dir ".\djpeg\Release" +# PROP Output_Dir ".\Release" +# PROP Intermediate_Dir ".\Release\djpeg" # PROP Ignore_Export_Lib 0 # PROP Target_Dir ".\djpeg" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /YX /c diff --git a/external/jpeg-9c/makedfil.v15 b/external/jpeg-9d/makedfil.v16 similarity index 100% rename from external/jpeg-9c/makedfil.v15 rename to external/jpeg-9d/makedfil.v16 diff --git a/external/jpeg-9c/makedmak.vc6 b/external/jpeg-9d/makedmak.vc6 similarity index 100% rename from external/jpeg-9c/makedmak.vc6 rename to external/jpeg-9d/makedmak.vc6 diff --git a/external/jpeg-9c/makedvcx.v15 b/external/jpeg-9d/makedvcx.v16 similarity index 54% rename from external/jpeg-9c/makedvcx.v15 rename to external/jpeg-9d/makedvcx.v16 index a611ac58..2fb330a4 100644 --- a/external/jpeg-9c/makedvcx.v15 +++ b/external/jpeg-9d/makedvcx.v16 @@ -5,12 +5,16 @@ Release Win32 + + Release + x64 + {11043137-B453-4DFA-9010-4D2B9DC1545C} Win32Proj djpeg - 10.0.16299.0 + 10.0 @@ -18,7 +22,14 @@ false true Unicode - v141 + v142 + + + Application + false + true + Unicode + v142 @@ -26,11 +37,19 @@ + + + false - $(ProjectName)\$(Configuration)\ - $(ProjectName)\$(Configuration)\ + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ + + + false + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ @@ -49,7 +68,27 @@ true true true - Release\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + $(Configuration)\$(Platform)\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + + + + + Level3 + NotUsing + Full + true + false + WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS + true + true + 4996 + + + Console + true + true + true + $(Configuration)\$(Platform)\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) diff --git a/external/jpeg-9c/makefile.ansi b/external/jpeg-9d/makefile.ansi similarity index 95% rename from external/jpeg-9c/makefile.ansi rename to external/jpeg-9d/makefile.ansi index d4ca2d34..cb695c50 100644 --- a/external/jpeg-9c/makefile.ansi +++ b/external/jpeg-9d/makefile.ansi @@ -66,9 +66,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -77,8 +77,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -136,13 +136,15 @@ clean: test: cjpeg djpeg jpegtran $(RM) testout* - ./djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - ./cjpeg -dct int -outfile testout.jpg testimg.ppm + ./djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + ./djpeg -dct int -gif -outfile testout.gif testorig.jpg + ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + ./cjpeg -dct int -outfile testout.jpg testimg.ppm ./djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg ./cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm ./jpegtran -outfile testoutt.jpg testprog.jpg cmp testimg.ppm testout.ppm + cmp testimg.gif testout.gif cmp testimg.bmp testout.bmp cmp testimg.jpg testout.jpg cmp testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/makefile.b32 b/external/jpeg-9d/makefile.b32 similarity index 95% rename from external/jpeg-9c/makefile.b32 rename to external/jpeg-9d/makefile.b32 index 2a7abfd5..083e56d6 100644 --- a/external/jpeg-9c/makefile.b32 +++ b/external/jpeg-9d/makefile.b32 @@ -62,9 +62,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -73,8 +73,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -154,14 +154,16 @@ clean: test: cjpeg.exe djpeg.exe jpegtran.exe - del testout*.* - djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - cjpeg -dct int -outfile testout.jpg testimg.ppm + djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + djpeg -dct int -gif -outfile testout.gif testorig.jpg + djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + cjpeg -dct int -outfile testout.jpg testimg.ppm djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm jpegtran -outfile testoutt.jpg testprog.jpg echo n > n.tmp comp testimg.ppm testout.ppm < n.tmp + comp testimg.gif testout.gif < n.tmp comp testimg.bmp testout.bmp < n.tmp comp testimg.jpg testout.jpg < n.tmp comp testimg.ppm testoutp.ppm < n.tmp diff --git a/external/jpeg-9c/makefile.bcc b/external/jpeg-9d/makefile.bcc similarity index 95% rename from external/jpeg-9c/makefile.bcc rename to external/jpeg-9d/makefile.bcc index 13142a91..16b640ab 100644 --- a/external/jpeg-9c/makefile.bcc +++ b/external/jpeg-9d/makefile.bcc @@ -93,9 +93,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -104,8 +104,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -194,14 +194,16 @@ clean: test: cjpeg.exe djpeg.exe jpegtran.exe - del testout*.* - djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - cjpeg -dct int -outfile testout.jpg testimg.ppm + djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + djpeg -dct int -gif -outfile testout.gif testorig.jpg + djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + cjpeg -dct int -outfile testout.jpg testimg.ppm djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm jpegtran -outfile testoutt.jpg testprog.jpg !if $d(DOS) fc /b testimg.ppm testout.ppm + fc /b testimg.gif testout.gif fc /b testimg.bmp testout.bmp fc /b testimg.jpg testout.jpg fc /b testimg.ppm testoutp.ppm @@ -210,6 +212,7 @@ test: cjpeg.exe djpeg.exe jpegtran.exe !else echo n > n.tmp comp testimg.ppm testout.ppm < n.tmp + comp testimg.gif testout.gif < n.tmp comp testimg.bmp testout.bmp < n.tmp comp testimg.jpg testout.jpg < n.tmp comp testimg.ppm testoutp.ppm < n.tmp diff --git a/external/jpeg-9c/makefile.dj b/external/jpeg-9d/makefile.dj similarity index 95% rename from external/jpeg-9c/makefile.dj rename to external/jpeg-9d/makefile.dj index f69c1458..38724919 100644 --- a/external/jpeg-9c/makefile.dj +++ b/external/jpeg-9d/makefile.dj @@ -66,9 +66,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -77,8 +77,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -142,13 +142,15 @@ clean: test: cjpeg.exe djpeg.exe jpegtran.exe $(RM) testout*.* - ./djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - ./cjpeg -dct int -outfile testout.jpg testimg.ppm + ./djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + ./djpeg -dct int -gif -outfile testout.gif testorig.jpg + ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + ./cjpeg -dct int -outfile testout.jpg testimg.ppm ./djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg ./cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm ./jpegtran -outfile testoutt.jpg testprog.jpg fc /b testimg.ppm testout.ppm + fc /b testimg.gif testout.gif fc /b testimg.bmp testout.bmp fc /b testimg.jpg testout.jpg fc /b testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/makefile.manx b/external/jpeg-9d/makefile.manx similarity index 95% rename from external/jpeg-9c/makefile.manx rename to external/jpeg-9d/makefile.manx index 28eb50db..4776b637 100644 --- a/external/jpeg-9c/makefile.manx +++ b/external/jpeg-9d/makefile.manx @@ -67,9 +67,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -78,8 +78,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -136,13 +136,15 @@ clean: test: cjpeg djpeg jpegtran -$(RM) testout*.* - djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - cjpeg -dct int -outfile testout.jpg testimg.ppm + djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + djpeg -dct int -gif -outfile testout.gif testorig.jpg + djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + cjpeg -dct int -outfile testout.jpg testimg.ppm djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm jpegtran -outfile testoutt.jpg testprog.jpg cmp testimg.ppm testout.ppm + cmp testimg.gif testout.gif cmp testimg.bmp testout.bmp cmp testimg.jpg testout.jpg cmp testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/makefile.mc6 b/external/jpeg-9d/makefile.mc6 similarity index 95% rename from external/jpeg-9c/makefile.mc6 rename to external/jpeg-9d/makefile.mc6 index 401af0c6..7e155f5d 100644 --- a/external/jpeg-9c/makefile.mc6 +++ b/external/jpeg-9d/makefile.mc6 @@ -64,9 +64,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -75,8 +75,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -169,13 +169,15 @@ clean: test: cjpeg.exe djpeg.exe jpegtran.exe del testout*.* - djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - cjpeg -dct int -outfile testout.jpg testimg.ppm + djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + djpeg -dct int -gif -outfile testout.gif testorig.jpg + djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + cjpeg -dct int -outfile testout.jpg testimg.ppm djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm jpegtran -outfile testoutt.jpg testprog.jpg fc /b testimg.ppm testout.ppm + fc /b testimg.gif testout.gif fc /b testimg.bmp testout.bmp fc /b testimg.jpg testout.jpg fc /b testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/makefile.mms b/external/jpeg-9d/makefile.mms similarity index 96% rename from external/jpeg-9c/makefile.mms rename to external/jpeg-9d/makefile.mms index e1792be4..0e616bbb 100644 --- a/external/jpeg-9c/makefile.mms +++ b/external/jpeg-9d/makefile.mms @@ -53,9 +53,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -64,8 +64,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -141,12 +141,14 @@ clean : test : cjpeg.exe djpeg.exe jpegtran.exe mcr sys$disk:[]djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + mcr sys$disk:[]djpeg -dct int -gif -outfile testout.gif testorig.jpg mcr sys$disk:[]djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - mcr sys$disk:[]cjpeg -dct int -outfile testout.jpg testimg.ppm + mcr sys$disk:[]cjpeg -dct int -outfile testout.jpg testimg.ppm mcr sys$disk:[]djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg mcr sys$disk:[]cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm mcr sys$disk:[]jpegtran -outfile testoutt.jpg testprog.jpg - Backup /Compare/Log testimg.ppm testout.ppm + - Backup /Compare/Log testimg.gif testout.gif - Backup /Compare/Log testimg.bmp testout.bmp - Backup /Compare/Log testimg.jpg testout.jpg - Backup /Compare/Log testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/makefile.sas b/external/jpeg-9d/makefile.sas similarity index 95% rename from external/jpeg-9c/makefile.sas rename to external/jpeg-9d/makefile.sas index 90e1d9c9..f5beb1f1 100644 --- a/external/jpeg-9c/makefile.sas +++ b/external/jpeg-9d/makefile.sas @@ -75,9 +75,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -86,8 +86,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -174,13 +174,15 @@ clean: test: cjpeg djpeg jpegtran -$(RM) testout*.* - djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - cjpeg -dct int -outfile testout.jpg testimg.ppm + djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + djpeg -dct int -gif -outfile testout.gif testorig.jpg + djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + cjpeg -dct int -outfile testout.jpg testimg.ppm djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm jpegtran -outfile testoutt.jpg testprog.jpg cmp testimg.ppm testout.ppm + cmp testimg.gif testout.gif cmp testimg.bmp testout.bmp cmp testimg.jpg testout.jpg cmp testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/makefile.unix b/external/jpeg-9d/makefile.unix similarity index 95% rename from external/jpeg-9c/makefile.unix rename to external/jpeg-9d/makefile.unix index 77d38515..5887970b 100644 --- a/external/jpeg-9c/makefile.unix +++ b/external/jpeg-9d/makefile.unix @@ -70,9 +70,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -81,8 +81,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -150,13 +150,15 @@ clean: test: cjpeg djpeg jpegtran $(RM) testout* - ./djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - ./cjpeg -dct int -outfile testout.jpg testimg.ppm + ./djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + ./djpeg -dct int -gif -outfile testout.gif testorig.jpg + ./djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + ./cjpeg -dct int -outfile testout.jpg testimg.ppm ./djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg ./cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm ./jpegtran -outfile testoutt.jpg testprog.jpg cmp testimg.ppm testout.ppm + cmp testimg.gif testout.gif cmp testimg.bmp testout.bmp cmp testimg.jpg testout.jpg cmp testimg.ppm testoutp.ppm diff --git a/external/jpeg-9c/makefile.vc b/external/jpeg-9d/makefile.vc similarity index 71% rename from external/jpeg-9c/makefile.vc rename to external/jpeg-9d/makefile.vc index bb3381cc..aff85a66 100644 --- a/external/jpeg-9c/makefile.vc +++ b/external/jpeg-9d/makefile.vc @@ -63,9 +63,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -74,8 +74,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -154,32 +154,74 @@ setup-vc6: ren makewdep.vc6 wrjpgcom.dep ren makewdsp.vc6 wrjpgcom.dsp -setup-v15: +setupcopy-vc6: + copy /y jconfig.vc jconfig.h + copy /y makejdsw.vc6 jpeg.dsw + copy /y makeadsw.vc6 apps.dsw + copy /y makejmak.vc6 jpeg.mak + copy /y makejdep.vc6 jpeg.dep + copy /y makejdsp.vc6 jpeg.dsp + copy /y makecmak.vc6 cjpeg.mak + copy /y makecdep.vc6 cjpeg.dep + copy /y makecdsp.vc6 cjpeg.dsp + copy /y makedmak.vc6 djpeg.mak + copy /y makeddep.vc6 djpeg.dep + copy /y makeddsp.vc6 djpeg.dsp + copy /y maketmak.vc6 jpegtran.mak + copy /y maketdep.vc6 jpegtran.dep + copy /y maketdsp.vc6 jpegtran.dsp + copy /y makermak.vc6 rdjpgcom.mak + copy /y makerdep.vc6 rdjpgcom.dep + copy /y makerdsp.vc6 rdjpgcom.dsp + copy /y makewmak.vc6 wrjpgcom.mak + copy /y makewdep.vc6 wrjpgcom.dep + copy /y makewdsp.vc6 wrjpgcom.dsp + +setup-v16: ren jconfig.vc jconfig.h - ren makejsln.v15 jpeg.sln - ren makeasln.v15 apps.sln - ren makejvcx.v15 jpeg.vcxproj - ren makejfil.v15 jpeg.vcxproj.filters - ren makecvcx.v15 cjpeg.vcxproj - ren makecfil.v15 cjpeg.vcxproj.filters - ren makedvcx.v15 djpeg.vcxproj - ren makedfil.v15 djpeg.vcxproj.filters - ren maketvcx.v15 jpegtran.vcxproj - ren maketfil.v15 jpegtran.vcxproj.filters - ren makervcx.v15 rdjpgcom.vcxproj - ren makerfil.v15 rdjpgcom.vcxproj.filters - ren makewvcx.v15 wrjpgcom.vcxproj - ren makewfil.v15 wrjpgcom.vcxproj.filters + ren makejsln.v16 jpeg.sln + ren makeasln.v16 apps.sln + ren makejvcx.v16 jpeg.vcxproj + ren makejfil.v16 jpeg.vcxproj.filters + ren makecvcx.v16 cjpeg.vcxproj + ren makecfil.v16 cjpeg.vcxproj.filters + ren makedvcx.v16 djpeg.vcxproj + ren makedfil.v16 djpeg.vcxproj.filters + ren maketvcx.v16 jpegtran.vcxproj + ren maketfil.v16 jpegtran.vcxproj.filters + ren makervcx.v16 rdjpgcom.vcxproj + ren makerfil.v16 rdjpgcom.vcxproj.filters + ren makewvcx.v16 wrjpgcom.vcxproj + ren makewfil.v16 wrjpgcom.vcxproj.filters + +setupcopy-v16: + copy /y jconfig.vc jconfig.h + copy /y makejsln.v16 jpeg.sln + copy /y makeasln.v16 apps.sln + copy /y makejvcx.v16 jpeg.vcxproj + copy /y makejfil.v16 jpeg.vcxproj.filters + copy /y makecvcx.v16 cjpeg.vcxproj + copy /y makecfil.v16 cjpeg.vcxproj.filters + copy /y makedvcx.v16 djpeg.vcxproj + copy /y makedfil.v16 djpeg.vcxproj.filters + copy /y maketvcx.v16 jpegtran.vcxproj + copy /y maketfil.v16 jpegtran.vcxproj.filters + copy /y makervcx.v16 rdjpgcom.vcxproj + copy /y makerfil.v16 rdjpgcom.vcxproj.filters + copy /y makewvcx.v16 wrjpgcom.vcxproj + copy /y makewfil.v16 wrjpgcom.vcxproj.filters test: IF EXIST testout* $(RM) testout* - .\djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - .\djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - .\cjpeg -dct int -outfile testout.jpg testimg.ppm + .\djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + .\djpeg -dct int -gif -outfile testout.gif testorig.jpg + .\djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + .\cjpeg -dct int -outfile testout.jpg testimg.ppm .\djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg .\cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm .\jpegtran -outfile testoutt.jpg testprog.jpg fc /b testimg.ppm testout.ppm + fc /b testimg.gif testout.gif fc /b testimg.bmp testout.bmp fc /b testimg.jpg testout.jpg fc /b testimg.ppm testoutp.ppm @@ -187,19 +229,55 @@ test: fc /b testorig.jpg testoutt.jpg test-build: - IF EXIST testout* $(RM) testout* - .\djpeg\Release\djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - .\djpeg\Release\djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - .\cjpeg\Release\cjpeg -dct int -outfile testout.jpg testimg.ppm - .\djpeg\Release\djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg - .\cjpeg\Release\cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm - .\jpegtran\Release\jpegtran -outfile testoutt.jpg testprog.jpg - fc /b testimg.ppm testout.ppm - fc /b testimg.bmp testout.bmp - fc /b testimg.jpg testout.jpg - fc /b testimg.ppm testoutp.ppm - fc /b testimgp.jpg testoutp.jpg - fc /b testorig.jpg testoutt.jpg + IF EXIST .\Release\testout* $(RM) .\Release\testout* + .\Release\djpeg -dct int -ppm -outfile .\Release\testout.ppm testorig.jpg + .\Release\djpeg -dct int -gif -outfile .\Release\testout.gif testorig.jpg + .\Release\djpeg -dct int -bmp -colors 256 -outfile .\Release\testout.bmp testorig.jpg + .\Release\cjpeg -dct int -outfile .\Release\testout.jpg testimg.ppm + .\Release\djpeg -dct int -ppm -outfile .\Release\testoutp.ppm testprog.jpg + .\Release\cjpeg -dct int -progressive -opt -outfile .\Release\testoutp.jpg testimg.ppm + .\Release\jpegtran -outfile .\Release\testoutt.jpg testprog.jpg + fc /b testimg.ppm .\Release\testout.ppm + fc /b testimg.gif .\Release\testout.gif + fc /b testimg.bmp .\Release\testout.bmp + fc /b testimg.jpg .\Release\testout.jpg + fc /b testimg.ppm .\Release\testoutp.ppm + fc /b testimgp.jpg .\Release\testoutp.jpg + fc /b testorig.jpg .\Release\testoutt.jpg + +test-32: + IF EXIST .\Release\testout* $(RM) .\Release\testout* + .\Release\Win32\djpeg -dct int -ppm -outfile .\Release\testout.ppm testorig.jpg + .\Release\Win32\djpeg -dct int -gif -outfile .\Release\testout.gif testorig.jpg + .\Release\Win32\djpeg -dct int -bmp -colors 256 -outfile .\Release\testout.bmp testorig.jpg + .\Release\Win32\cjpeg -dct int -outfile .\Release\testout.jpg testimg.ppm + .\Release\Win32\djpeg -dct int -ppm -outfile .\Release\testoutp.ppm testprog.jpg + .\Release\Win32\cjpeg -dct int -progressive -opt -outfile .\Release\testoutp.jpg testimg.ppm + .\Release\Win32\jpegtran -outfile .\Release\testoutt.jpg testprog.jpg + fc /b testimg.ppm .\Release\testout.ppm + fc /b testimg.gif .\Release\testout.gif + fc /b testimg.bmp .\Release\testout.bmp + fc /b testimg.jpg .\Release\testout.jpg + fc /b testimg.ppm .\Release\testoutp.ppm + fc /b testimgp.jpg .\Release\testoutp.jpg + fc /b testorig.jpg .\Release\testoutt.jpg + +test-64: + IF EXIST .\Release\testout* $(RM) .\Release\testout* + .\Release\x64\djpeg -dct int -ppm -outfile .\Release\testout.ppm testorig.jpg + .\Release\x64\djpeg -dct int -gif -outfile .\Release\testout.gif testorig.jpg + .\Release\x64\djpeg -dct int -bmp -colors 256 -outfile .\Release\testout.bmp testorig.jpg + .\Release\x64\cjpeg -dct int -outfile .\Release\testout.jpg testimg.ppm + .\Release\x64\djpeg -dct int -ppm -outfile .\Release\testoutp.ppm testprog.jpg + .\Release\x64\cjpeg -dct int -progressive -opt -outfile .\Release\testoutp.jpg testimg.ppm + .\Release\x64\jpegtran -outfile .\Release\testoutt.jpg testprog.jpg + fc /b testimg.ppm .\Release\testout.ppm + fc /b testimg.gif .\Release\testout.gif + fc /b testimg.bmp .\Release\testout.bmp + fc /b testimg.jpg .\Release\testout.jpg + fc /b testimg.ppm .\Release\testoutp.ppm + fc /b testimgp.jpg .\Release\testoutp.jpg + fc /b testorig.jpg .\Release\testoutt.jpg jaricom.obj: jaricom.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h diff --git a/external/jpeg-9c/makefile.vms b/external/jpeg-9d/makefile.vms similarity index 100% rename from external/jpeg-9c/makefile.vms rename to external/jpeg-9d/makefile.vms diff --git a/external/jpeg-9c/makefile.vs b/external/jpeg-9d/makefile.vs similarity index 71% rename from external/jpeg-9c/makefile.vs rename to external/jpeg-9d/makefile.vs index 4fdead5f..bb10fcb6 100644 --- a/external/jpeg-9c/makefile.vs +++ b/external/jpeg-9d/makefile.vs @@ -63,9 +63,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 \ makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 \ makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 \ makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 \ - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 \ - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 \ - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 \ + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 \ + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 \ + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 \ makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st \ makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ @@ -74,8 +74,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat \ CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp \ missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg \ - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg \ + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) \ $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -154,32 +154,74 @@ setup-vc6: ren makewdep.vc6 wrjpgcom.dep ren makewdsp.vc6 wrjpgcom.dsp -setup-v15: +setupcopy-vc6: + copy /y jconfig.vc jconfig.h + copy /y makejdsw.vc6 jpeg.dsw + copy /y makeadsw.vc6 apps.dsw + copy /y makejmak.vc6 jpeg.mak + copy /y makejdep.vc6 jpeg.dep + copy /y makejdsp.vc6 jpeg.dsp + copy /y makecmak.vc6 cjpeg.mak + copy /y makecdep.vc6 cjpeg.dep + copy /y makecdsp.vc6 cjpeg.dsp + copy /y makedmak.vc6 djpeg.mak + copy /y makeddep.vc6 djpeg.dep + copy /y makeddsp.vc6 djpeg.dsp + copy /y maketmak.vc6 jpegtran.mak + copy /y maketdep.vc6 jpegtran.dep + copy /y maketdsp.vc6 jpegtran.dsp + copy /y makermak.vc6 rdjpgcom.mak + copy /y makerdep.vc6 rdjpgcom.dep + copy /y makerdsp.vc6 rdjpgcom.dsp + copy /y makewmak.vc6 wrjpgcom.mak + copy /y makewdep.vc6 wrjpgcom.dep + copy /y makewdsp.vc6 wrjpgcom.dsp + +setup-v16: ren jconfig.vc jconfig.h - ren makejsln.v15 jpeg.sln - ren makeasln.v15 apps.sln - ren makejvcx.v15 jpeg.vcxproj - ren makejfil.v15 jpeg.vcxproj.filters - ren makecvcx.v15 cjpeg.vcxproj - ren makecfil.v15 cjpeg.vcxproj.filters - ren makedvcx.v15 djpeg.vcxproj - ren makedfil.v15 djpeg.vcxproj.filters - ren maketvcx.v15 jpegtran.vcxproj - ren maketfil.v15 jpegtran.vcxproj.filters - ren makervcx.v15 rdjpgcom.vcxproj - ren makerfil.v15 rdjpgcom.vcxproj.filters - ren makewvcx.v15 wrjpgcom.vcxproj - ren makewfil.v15 wrjpgcom.vcxproj.filters + ren makejsln.v16 jpeg.sln + ren makeasln.v16 apps.sln + ren makejvcx.v16 jpeg.vcxproj + ren makejfil.v16 jpeg.vcxproj.filters + ren makecvcx.v16 cjpeg.vcxproj + ren makecfil.v16 cjpeg.vcxproj.filters + ren makedvcx.v16 djpeg.vcxproj + ren makedfil.v16 djpeg.vcxproj.filters + ren maketvcx.v16 jpegtran.vcxproj + ren maketfil.v16 jpegtran.vcxproj.filters + ren makervcx.v16 rdjpgcom.vcxproj + ren makerfil.v16 rdjpgcom.vcxproj.filters + ren makewvcx.v16 wrjpgcom.vcxproj + ren makewfil.v16 wrjpgcom.vcxproj.filters + +setupcopy-v16: + copy /y jconfig.vc jconfig.h + copy /y makejsln.v16 jpeg.sln + copy /y makeasln.v16 apps.sln + copy /y makejvcx.v16 jpeg.vcxproj + copy /y makejfil.v16 jpeg.vcxproj.filters + copy /y makecvcx.v16 cjpeg.vcxproj + copy /y makecfil.v16 cjpeg.vcxproj.filters + copy /y makedvcx.v16 djpeg.vcxproj + copy /y makedfil.v16 djpeg.vcxproj.filters + copy /y maketvcx.v16 jpegtran.vcxproj + copy /y maketfil.v16 jpegtran.vcxproj.filters + copy /y makervcx.v16 rdjpgcom.vcxproj + copy /y makerfil.v16 rdjpgcom.vcxproj.filters + copy /y makewvcx.v16 wrjpgcom.vcxproj + copy /y makewfil.v16 wrjpgcom.vcxproj.filters test: IF EXIST testout* $(RM) testout* - .\djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - .\djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - .\cjpeg -dct int -outfile testout.jpg testimg.ppm + .\djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + .\djpeg -dct int -gif -outfile testout.gif testorig.jpg + .\djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + .\cjpeg -dct int -outfile testout.jpg testimg.ppm .\djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg .\cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm .\jpegtran -outfile testoutt.jpg testprog.jpg fc /b testimg.ppm testout.ppm + fc /b testimg.gif testout.gif fc /b testimg.bmp testout.bmp fc /b testimg.jpg testout.jpg fc /b testimg.ppm testoutp.ppm @@ -187,19 +229,55 @@ test: fc /b testorig.jpg testoutt.jpg test-build: - IF EXIST testout* $(RM) testout* - .\djpeg\Release\djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - .\djpeg\Release\djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - .\cjpeg\Release\cjpeg -dct int -outfile testout.jpg testimg.ppm - .\djpeg\Release\djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg - .\cjpeg\Release\cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm - .\jpegtran\Release\jpegtran -outfile testoutt.jpg testprog.jpg - fc /b testimg.ppm testout.ppm - fc /b testimg.bmp testout.bmp - fc /b testimg.jpg testout.jpg - fc /b testimg.ppm testoutp.ppm - fc /b testimgp.jpg testoutp.jpg - fc /b testorig.jpg testoutt.jpg + IF EXIST .\Release\testout* $(RM) .\Release\testout* + .\Release\djpeg -dct int -ppm -outfile .\Release\testout.ppm testorig.jpg + .\Release\djpeg -dct int -gif -outfile .\Release\testout.gif testorig.jpg + .\Release\djpeg -dct int -bmp -colors 256 -outfile .\Release\testout.bmp testorig.jpg + .\Release\cjpeg -dct int -outfile .\Release\testout.jpg testimg.ppm + .\Release\djpeg -dct int -ppm -outfile .\Release\testoutp.ppm testprog.jpg + .\Release\cjpeg -dct int -progressive -opt -outfile .\Release\testoutp.jpg testimg.ppm + .\Release\jpegtran -outfile .\Release\testoutt.jpg testprog.jpg + fc /b testimg.ppm .\Release\testout.ppm + fc /b testimg.gif .\Release\testout.gif + fc /b testimg.bmp .\Release\testout.bmp + fc /b testimg.jpg .\Release\testout.jpg + fc /b testimg.ppm .\Release\testoutp.ppm + fc /b testimgp.jpg .\Release\testoutp.jpg + fc /b testorig.jpg .\Release\testoutt.jpg + +test-32: + IF EXIST .\Release\testout* $(RM) .\Release\testout* + .\Release\Win32\djpeg -dct int -ppm -outfile .\Release\testout.ppm testorig.jpg + .\Release\Win32\djpeg -dct int -gif -outfile .\Release\testout.gif testorig.jpg + .\Release\Win32\djpeg -dct int -bmp -colors 256 -outfile .\Release\testout.bmp testorig.jpg + .\Release\Win32\cjpeg -dct int -outfile .\Release\testout.jpg testimg.ppm + .\Release\Win32\djpeg -dct int -ppm -outfile .\Release\testoutp.ppm testprog.jpg + .\Release\Win32\cjpeg -dct int -progressive -opt -outfile .\Release\testoutp.jpg testimg.ppm + .\Release\Win32\jpegtran -outfile .\Release\testoutt.jpg testprog.jpg + fc /b testimg.ppm .\Release\testout.ppm + fc /b testimg.gif .\Release\testout.gif + fc /b testimg.bmp .\Release\testout.bmp + fc /b testimg.jpg .\Release\testout.jpg + fc /b testimg.ppm .\Release\testoutp.ppm + fc /b testimgp.jpg .\Release\testoutp.jpg + fc /b testorig.jpg .\Release\testoutt.jpg + +test-64: + IF EXIST .\Release\testout* $(RM) .\Release\testout* + .\Release\x64\djpeg -dct int -ppm -outfile .\Release\testout.ppm testorig.jpg + .\Release\x64\djpeg -dct int -gif -outfile .\Release\testout.gif testorig.jpg + .\Release\x64\djpeg -dct int -bmp -colors 256 -outfile .\Release\testout.bmp testorig.jpg + .\Release\x64\cjpeg -dct int -outfile .\Release\testout.jpg testimg.ppm + .\Release\x64\djpeg -dct int -ppm -outfile .\Release\testoutp.ppm testprog.jpg + .\Release\x64\cjpeg -dct int -progressive -opt -outfile .\Release\testoutp.jpg testimg.ppm + .\Release\x64\jpegtran -outfile .\Release\testoutt.jpg testprog.jpg + fc /b testimg.ppm .\Release\testout.ppm + fc /b testimg.gif .\Release\testout.gif + fc /b testimg.bmp .\Release\testout.bmp + fc /b testimg.jpg .\Release\testout.jpg + fc /b testimg.ppm .\Release\testoutp.ppm + fc /b testimgp.jpg .\Release\testoutp.jpg + fc /b testorig.jpg .\Release\testoutt.jpg jaricom.obj: jaricom.c jinclude.h jconfig.h jpeglib.h jmorecfg.h jpegint.h jerror.h diff --git a/external/jpeg-9c/makefile.wat b/external/jpeg-9d/makefile.wat similarity index 95% rename from external/jpeg-9c/makefile.wat rename to external/jpeg-9d/makefile.wat index 0dfc9780..56b2f0dd 100644 --- a/external/jpeg-9c/makefile.wat +++ b/external/jpeg-9d/makefile.wat @@ -65,9 +65,9 @@ MKFILES= configure Makefile.in makefile.ansi makefile.unix makefile.b32 & makejmak.vc6 makecdep.vc6 makecdsp.vc6 makecmak.vc6 makeddep.vc6 & makeddsp.vc6 makedmak.vc6 maketdep.vc6 maketdsp.vc6 maketmak.vc6 & makerdep.vc6 makerdsp.vc6 makermak.vc6 makewdep.vc6 makewdsp.vc6 & - makewmak.vc6 makejsln.v15 makeasln.v15 makejvcx.v15 makejfil.v15 & - makecvcx.v15 makecfil.v15 makedvcx.v15 makedfil.v15 maketvcx.v15 & - maketfil.v15 makervcx.v15 makerfil.v15 makewvcx.v15 makewfil.v15 & + makewmak.vc6 makejsln.v16 makeasln.v16 makejvcx.v16 makejfil.v16 & + makecvcx.v16 makecfil.v16 makedvcx.v16 makedfil.v16 maketvcx.v16 & + maketfil.v16 makervcx.v16 makerfil.v16 makewvcx.v16 makewfil.v16 & makeproj.mac makcjpeg.st makdjpeg.st makljpeg.st maktjpeg.st & makefile.manx makefile.sas makefile.mms makefile.vms makvms.opt CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat & @@ -76,8 +76,8 @@ CONFIGFILES= jconfig.cfg jconfig.bcc jconfig.mc6 jconfig.dj jconfig.wat & CONFIGUREFILES= config.guess config.sub install-sh ltmain.sh depcomp & missing ar-lib OTHERFILES= jconfig.txt ckconfig.c jmemdosa.asm libjpeg.map libjpeg.pc.in -TESTFILES= testorig.jpg testimg.ppm testimg.bmp testimg.jpg testprog.jpg & - testimgp.jpg +TESTFILES= testorig.jpg testimg.ppm testimg.gif testimg.bmp testimg.jpg & + testprog.jpg testimgp.jpg DISTFILES= $(DOCS) $(MKFILES) $(CONFIGFILES) $(SOURCES) $(INCLUDES) & $(CONFIGUREFILES) $(OTHERFILES) $(TESTFILES) # library object files common to compression and decompression @@ -144,14 +144,16 @@ clean: .SYMBOLIC test: cjpeg.exe djpeg.exe jpegtran.exe .SYMBOLIC - del testout*.* - djpeg -dct int -ppm -outfile testout.ppm testorig.jpg - djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg - cjpeg -dct int -outfile testout.jpg testimg.ppm + djpeg -dct int -ppm -outfile testout.ppm testorig.jpg + djpeg -dct int -gif -outfile testout.gif testorig.jpg + djpeg -dct int -bmp -colors 256 -outfile testout.bmp testorig.jpg + cjpeg -dct int -outfile testout.jpg testimg.ppm djpeg -dct int -ppm -outfile testoutp.ppm testprog.jpg cjpeg -dct int -progressive -opt -outfile testoutp.jpg testimg.ppm jpegtran -outfile testoutt.jpg testprog.jpg !ifeq SYSTEM DOS fc /b testimg.ppm testout.ppm + fc /b testimg.gif testout.gif fc /b testimg.bmp testout.bmp fc /b testimg.jpg testout.jpg fc /b testimg.ppm testoutp.ppm @@ -160,6 +162,7 @@ test: cjpeg.exe djpeg.exe jpegtran.exe .SYMBOLIC !else echo n > n.tmp comp testimg.ppm testout.ppm < n.tmp + comp testimg.gif testout.gif < n.tmp comp testimg.bmp testout.bmp < n.tmp comp testimg.jpg testout.jpg < n.tmp comp testimg.ppm testoutp.ppm < n.tmp diff --git a/external/jpeg-9c/makejdep.vc6 b/external/jpeg-9d/makejdep.vc6 similarity index 100% rename from external/jpeg-9c/makejdep.vc6 rename to external/jpeg-9d/makejdep.vc6 diff --git a/external/jpeg-9c/makejdsp.vc6 b/external/jpeg-9d/makejdsp.vc6 similarity index 99% rename from external/jpeg-9c/makejdsp.vc6 rename to external/jpeg-9d/makejdsp.vc6 index 738f1ab4..8cd27bd6 100644 --- a/external/jpeg-9c/makejdsp.vc6 +++ b/external/jpeg-9d/makejdsp.vc6 @@ -34,7 +34,7 @@ RSC=rc.exe # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 # PROP Output_Dir ".\Release" -# PROP Intermediate_Dir ".\Release" +# PROP Intermediate_Dir ".\Release\jpeg" # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /c # ADD CPP /nologo /G6 /MT /W3 /GX /Ox /Oa /Ob2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c diff --git a/external/jpeg-9c/makejdsw.vc6 b/external/jpeg-9d/makejdsw.vc6 similarity index 100% rename from external/jpeg-9c/makejdsw.vc6 rename to external/jpeg-9d/makejdsw.vc6 diff --git a/external/jpeg-9c/makejfil.v15 b/external/jpeg-9d/makejfil.v16 similarity index 100% rename from external/jpeg-9c/makejfil.v15 rename to external/jpeg-9d/makejfil.v16 diff --git a/external/jpeg-9c/makejmak.vc6 b/external/jpeg-9d/makejmak.vc6 similarity index 100% rename from external/jpeg-9c/makejmak.vc6 rename to external/jpeg-9d/makejmak.vc6 diff --git a/external/jpeg-9c/makejsln.v15 b/external/jpeg-9d/makejsln.v16 similarity index 56% rename from external/jpeg-9c/makejsln.v15 rename to external/jpeg-9d/makejsln.v16 index 6a5befdf..9e843d4f 100644 --- a/external/jpeg-9c/makejsln.v15 +++ b/external/jpeg-9d/makejsln.v16 @@ -1,17 +1,25 @@ ‹¯¨ -Microsoft Visual Studio Solution File, Format Version 11.00 -# Visual C++ Express 2010 +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.28307.329 +MinimumVisualStudioVersion = 10.0.40219.1 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jpeg", "jpeg.vcxproj", "{019DBD2A-273D-4BA4-BF86-B5EFE2ED76B1}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Release|Win32 = Release|Win32 + Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {019DBD2A-273D-4BA4-BF86-B5EFE2ED76B1}.Release|Win32.ActiveCfg = Release|Win32 {019DBD2A-273D-4BA4-BF86-B5EFE2ED76B1}.Release|Win32.Build.0 = Release|Win32 + {019DBD2A-273D-4BA4-BF86-B5EFE2ED76B1}.Release|x64.ActiveCfg = Release|x64 + {019DBD2A-273D-4BA4-BF86-B5EFE2ED76B1}.Release|x64.Build.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {F3829CB8-BF87-4A30-B5D3-E3ADB548485D} + EndGlobalSection EndGlobal diff --git a/external/jpeg-9c/makejvcx.v15 b/external/jpeg-9d/makejvcx.v16 similarity index 67% rename from external/jpeg-9c/makejvcx.v15 rename to external/jpeg-9d/makejvcx.v16 index 31579e28..1487199d 100644 --- a/external/jpeg-9c/makejvcx.v15 +++ b/external/jpeg-9d/makejvcx.v16 @@ -5,6 +5,10 @@ Release Win32 + + Release + x64 + @@ -69,7 +73,7 @@ {019DBD2A-273D-4BA4-BF86-B5EFE2ED76B1} Win32Proj jpeg - 10.0.16299.0 + 10.0 @@ -77,7 +81,14 @@ false true Unicode - v141 + v142 + + + StaticLibrary + false + true + Unicode + v142 @@ -85,8 +96,18 @@ + + + - + + $(SolutionDir)$(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ + + + $(SolutionDir)$(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ + Level3 @@ -105,6 +126,24 @@ true + + + Level3 + NotUsing + Full + true + false + NDEBUG;_LIB;_CRT_SECURE_NO_WARNINGS + true + true + + + Windows + true + true + true + + diff --git a/external/jpeg-9c/makeproj.mac b/external/jpeg-9d/makeproj.mac similarity index 100% rename from external/jpeg-9c/makeproj.mac rename to external/jpeg-9d/makeproj.mac diff --git a/external/jpeg-9c/makerdep.vc6 b/external/jpeg-9d/makerdep.vc6 similarity index 100% rename from external/jpeg-9c/makerdep.vc6 rename to external/jpeg-9d/makerdep.vc6 diff --git a/external/jpeg-9c/makerdsp.vc6 b/external/jpeg-9d/makerdsp.vc6 similarity index 96% rename from external/jpeg-9c/makerdsp.vc6 rename to external/jpeg-9d/makerdsp.vc6 index 60de09af..8eaf4467 100644 --- a/external/jpeg-9c/makerdsp.vc6 +++ b/external/jpeg-9d/makerdsp.vc6 @@ -33,8 +33,8 @@ RSC=rc.exe # PROP BASE Target_Dir ".\rdjpgcom" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 -# PROP Output_Dir ".\rdjpgcom\Release" -# PROP Intermediate_Dir ".\rdjpgcom\Release" +# PROP Output_Dir ".\Release" +# PROP Intermediate_Dir ".\Release\rdjpgcom" # PROP Ignore_Export_Lib 0 # PROP Target_Dir ".\rdjpgcom" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /YX /c diff --git a/external/jpeg-9c/makerfil.v15 b/external/jpeg-9d/makerfil.v16 similarity index 100% rename from external/jpeg-9c/makerfil.v15 rename to external/jpeg-9d/makerfil.v16 diff --git a/external/jpeg-9c/makermak.vc6 b/external/jpeg-9d/makermak.vc6 similarity index 100% rename from external/jpeg-9c/makermak.vc6 rename to external/jpeg-9d/makermak.vc6 diff --git a/external/jpeg-9c/makervcx.v15 b/external/jpeg-9d/makervcx.v16 similarity index 55% rename from external/jpeg-9c/makervcx.v15 rename to external/jpeg-9d/makervcx.v16 index 76bb6de0..ffc86709 100644 --- a/external/jpeg-9c/makervcx.v15 +++ b/external/jpeg-9d/makervcx.v16 @@ -5,12 +5,16 @@ Release Win32 + + Release + x64 + {C81513DB-78DC-46BC-BC98-82E745203976} Win32Proj rdjpgcom - 10.0.16299.0 + 10.0 @@ -18,7 +22,14 @@ false true Unicode - v141 + v142 + + + Application + false + true + Unicode + v142 @@ -26,11 +37,19 @@ + + + false - $(ProjectName)\$(Configuration)\ - $(ProjectName)\$(Configuration)\ + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ + + + false + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ @@ -51,6 +70,25 @@ true + + + Level3 + NotUsing + Full + true + false + WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS + true + true + 4996 + + + Console + true + true + true + + diff --git a/external/jpeg-9c/maketdep.vc6 b/external/jpeg-9d/maketdep.vc6 similarity index 100% rename from external/jpeg-9c/maketdep.vc6 rename to external/jpeg-9d/maketdep.vc6 diff --git a/external/jpeg-9c/maketdsp.vc6 b/external/jpeg-9d/maketdsp.vc6 similarity index 97% rename from external/jpeg-9c/maketdsp.vc6 rename to external/jpeg-9d/maketdsp.vc6 index fe1ae9a3..00df01af 100644 --- a/external/jpeg-9c/maketdsp.vc6 +++ b/external/jpeg-9d/maketdsp.vc6 @@ -33,8 +33,8 @@ RSC=rc.exe # PROP BASE Target_Dir ".\jpegtran" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 -# PROP Output_Dir ".\jpegtran\Release" -# PROP Intermediate_Dir ".\jpegtran\Release" +# PROP Output_Dir ".\Release" +# PROP Intermediate_Dir ".\Release\jpegtran" # PROP Ignore_Export_Lib 0 # PROP Target_Dir ".\jpegtran" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /YX /c diff --git a/external/jpeg-9c/maketfil.v15 b/external/jpeg-9d/maketfil.v16 similarity index 100% rename from external/jpeg-9c/maketfil.v15 rename to external/jpeg-9d/maketfil.v16 diff --git a/external/jpeg-9c/maketmak.vc6 b/external/jpeg-9d/maketmak.vc6 similarity index 100% rename from external/jpeg-9c/maketmak.vc6 rename to external/jpeg-9d/maketmak.vc6 diff --git a/external/jpeg-9c/maketvcx.v15 b/external/jpeg-9d/maketvcx.v16 similarity index 53% rename from external/jpeg-9c/maketvcx.v15 rename to external/jpeg-9d/maketvcx.v16 index 2cf5eed3..277cdaa6 100644 --- a/external/jpeg-9c/maketvcx.v15 +++ b/external/jpeg-9d/maketvcx.v16 @@ -5,12 +5,16 @@ Release Win32 + + Release + x64 + {025BAC50-51B5-4FFE-BC47-3F920BB4047E} Win32Proj jpegtran - 10.0.16299.0 + 10.0 @@ -18,7 +22,14 @@ false true Unicode - v141 + v142 + + + Application + false + true + Unicode + v142 @@ -26,11 +37,19 @@ + + + false - $(ProjectName)\$(Configuration)\ - $(ProjectName)\$(Configuration)\ + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ + + + false + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ @@ -49,7 +68,27 @@ true true true - Release\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + $(Configuration)\$(Platform)\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + + + + + Level3 + NotUsing + Full + true + false + WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS + true + true + 4996 + + + Console + true + true + true + $(Configuration)\$(Platform)\jpeg.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) diff --git a/external/jpeg-9c/makewdep.vc6 b/external/jpeg-9d/makewdep.vc6 similarity index 100% rename from external/jpeg-9c/makewdep.vc6 rename to external/jpeg-9d/makewdep.vc6 diff --git a/external/jpeg-9c/makewdsp.vc6 b/external/jpeg-9d/makewdsp.vc6 similarity index 96% rename from external/jpeg-9c/makewdsp.vc6 rename to external/jpeg-9d/makewdsp.vc6 index 2063b1a5..d2f3887c 100644 --- a/external/jpeg-9c/makewdsp.vc6 +++ b/external/jpeg-9d/makewdsp.vc6 @@ -33,8 +33,8 @@ RSC=rc.exe # PROP BASE Target_Dir ".\wrjpgcom" # PROP Use_MFC 0 # PROP Use_Debug_Libraries 0 -# PROP Output_Dir ".\wrjpgcom\Release" -# PROP Intermediate_Dir ".\wrjpgcom\Release" +# PROP Output_Dir ".\Release" +# PROP Intermediate_Dir ".\Release\wrjpgcom" # PROP Ignore_Export_Lib 0 # PROP Target_Dir ".\wrjpgcom" # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /YX /c diff --git a/external/jpeg-9c/makewfil.v15 b/external/jpeg-9d/makewfil.v16 similarity index 100% rename from external/jpeg-9c/makewfil.v15 rename to external/jpeg-9d/makewfil.v16 diff --git a/external/jpeg-9c/makewmak.vc6 b/external/jpeg-9d/makewmak.vc6 similarity index 100% rename from external/jpeg-9c/makewmak.vc6 rename to external/jpeg-9d/makewmak.vc6 diff --git a/external/jpeg-9c/makewvcx.v15 b/external/jpeg-9d/makewvcx.v16 similarity index 55% rename from external/jpeg-9c/makewvcx.v15 rename to external/jpeg-9d/makewvcx.v16 index 5f8b8df3..dc161b8b 100644 --- a/external/jpeg-9c/makewvcx.v15 +++ b/external/jpeg-9d/makewvcx.v16 @@ -5,12 +5,16 @@ Release Win32 + + Release + x64 + {B57065D4-DDDA-4668-BAF5-2D49270C973C} Win32Proj wrjpgcom - 10.0.16299.0 + 10.0 @@ -18,7 +22,14 @@ false true Unicode - v141 + v142 + + + Application + false + true + Unicode + v142 @@ -26,11 +37,19 @@ + + + false - $(ProjectName)\$(Configuration)\ - $(ProjectName)\$(Configuration)\ + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ + + + false + $(Configuration)\$(Platform)\ + $(Configuration)\$(Platform)\$(ProjectName)\ @@ -51,6 +70,25 @@ true + + + Level3 + NotUsing + Full + true + false + WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS + true + true + 4996 + + + Console + true + true + true + + diff --git a/external/jpeg-9c/makljpeg.st b/external/jpeg-9d/makljpeg.st similarity index 100% rename from external/jpeg-9c/makljpeg.st rename to external/jpeg-9d/makljpeg.st diff --git a/external/jpeg-9c/maktjpeg.st b/external/jpeg-9d/maktjpeg.st similarity index 100% rename from external/jpeg-9c/maktjpeg.st rename to external/jpeg-9d/maktjpeg.st diff --git a/external/jpeg-9c/makvms.opt b/external/jpeg-9d/makvms.opt similarity index 100% rename from external/jpeg-9c/makvms.opt rename to external/jpeg-9d/makvms.opt diff --git a/external/jpeg-9c/missing b/external/jpeg-9d/missing similarity index 95% rename from external/jpeg-9c/missing rename to external/jpeg-9d/missing index c6e37958..625aeb11 100755 --- a/external/jpeg-9c/missing +++ b/external/jpeg-9d/missing @@ -1,9 +1,9 @@ #! /bin/sh # Common wrapper for a few potentially missing GNU programs. -scriptversion=2016-01-11.22; # UTC +scriptversion=2018-03-07.03; # UTC -# Copyright (C) 1996-2017 Free Software Foundation, Inc. +# Copyright (C) 1996-2018 Free Software Foundation, Inc. # Originally written by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify @@ -17,7 +17,7 @@ scriptversion=2016-01-11.22; # UTC # GNU General Public License for more details. # You should have received a copy of the GNU General Public License -# along with this program. If not, see . +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -101,9 +101,9 @@ else exit $st fi -perl_URL=http://www.perl.org/ -flex_URL=http://flex.sourceforge.net/ -gnu_software_URL=http://www.gnu.org/software +perl_URL=https://www.perl.org/ +flex_URL=https://github.com/westes/flex +gnu_software_URL=https://www.gnu.org/software program_details () { @@ -207,7 +207,7 @@ give_advice "$1" | sed -e '1s/^/WARNING: /' \ exit $st # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/external/jpeg-9c/rdbmp.c b/external/jpeg-9d/rdbmp.c similarity index 84% rename from external/jpeg-9c/rdbmp.c rename to external/jpeg-9d/rdbmp.c index 6639ad06..6749ea01 100644 --- a/external/jpeg-9c/rdbmp.c +++ b/external/jpeg-9d/rdbmp.c @@ -2,7 +2,7 @@ * rdbmp.c * * Copyright (C) 1994-1996, Thomas G. Lane. - * Modified 2009-2017 by Guido Vollbeding. + * Modified 2009-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -33,11 +33,10 @@ typedef unsigned char U_CHAR; #define UCH(x) ((int) (x)) #else /* !HAVE_UNSIGNED_CHAR */ -#ifdef CHAR_IS_UNSIGNED typedef char U_CHAR; +#ifdef CHAR_IS_UNSIGNED #define UCH(x) ((int) (x)) #else -typedef char U_CHAR; #define UCH(x) ((int) (x) & 0xFF) #endif #endif /* HAVE_UNSIGNED_CHAR */ @@ -105,7 +104,6 @@ read_colormap (bmp_source_ptr sinfo, int cmaplen, int mapentrysize) break; default: ERREXIT(sinfo->cinfo, JERR_BMP_BADCMAP); - break; } } @@ -122,7 +120,6 @@ get_8bit_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) /* This version is for reading 8-bit colormap indexes */ { bmp_source_ptr source = (bmp_source_ptr) sinfo; - JSAMPARRAY image_ptr; register JSAMPROW inptr, outptr; register JSAMPARRAY colormap; register JDIMENSION col; @@ -131,12 +128,10 @@ get_8bit_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) /* Fetch next row from virtual array */ source->source_row--; - image_ptr = (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, source->whole_image, - source->source_row, (JDIMENSION) 1, FALSE); + inptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + source->whole_image, source->source_row, (JDIMENSION) 1, FALSE); /* Expand the colormap indexes to real data */ - inptr = image_ptr[0]; outptr = source->pub.buffer[0]; colormap = source->colormap; cmaplen = source->cmap_length; @@ -152,26 +147,22 @@ get_8bit_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) return 1; } - METHODDEF(JDIMENSION) get_24bit_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) /* This version is for reading 24-bit pixels */ { bmp_source_ptr source = (bmp_source_ptr) sinfo; - JSAMPARRAY image_ptr; register JSAMPROW inptr, outptr; register JDIMENSION col; /* Fetch next row from virtual array */ source->source_row--; - image_ptr = (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, source->whole_image, - source->source_row, (JDIMENSION) 1, FALSE); + inptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + source->whole_image, source->source_row, (JDIMENSION) 1, FALSE); /* Transfer data. Note source values are in BGR order * (even though Microsoft's own documents say the opposite). */ - inptr = image_ptr[0]; outptr = source->pub.buffer[0]; for (col = cinfo->image_width; col > 0; col--) { outptr[2] = *inptr++; /* can omit GETJSAMPLE() safely */ @@ -183,26 +174,22 @@ get_24bit_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) return 1; } - METHODDEF(JDIMENSION) get_32bit_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) /* This version is for reading 32-bit pixels */ { bmp_source_ptr source = (bmp_source_ptr) sinfo; - JSAMPARRAY image_ptr; register JSAMPROW inptr, outptr; register JDIMENSION col; /* Fetch next row from virtual array */ source->source_row--; - image_ptr = (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, source->whole_image, - source->source_row, (JDIMENSION) 1, FALSE); + inptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + source->whole_image, source->source_row, (JDIMENSION) 1, FALSE); /* Transfer data. Note source values are in BGR order * (even though Microsoft's own documents say the opposite). */ - inptr = image_ptr[0]; outptr = source->pub.buffer[0]; for (col = cinfo->image_width; col > 0; col--) { outptr[2] = *inptr++; /* can omit GETJSAMPLE() safely */ @@ -229,7 +216,6 @@ preload_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) register FILE *infile = source->pub.input_file; register int c; register JSAMPROW out_ptr; - JSAMPARRAY image_ptr; JDIMENSION row, col; cd_progress_ptr progress = (cd_progress_ptr) cinfo->progress; @@ -240,10 +226,8 @@ preload_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) progress->pub.pass_limit = (long) cinfo->image_height; (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); } - image_ptr = (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, source->whole_image, - row, (JDIMENSION) 1, TRUE); - out_ptr = image_ptr[0]; + out_ptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + source->whole_image, row, (JDIMENSION) 1, TRUE); for (col = source->row_width; col > 0; col--) { /* inline copy of read_byte() for speed */ if ((c = getc(infile)) == EOF) @@ -285,12 +269,12 @@ start_input_bmp (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) bmp_source_ptr source = (bmp_source_ptr) sinfo; U_CHAR bmpfileheader[14]; U_CHAR bmpinfoheader[64]; -#define GET_2B(array,offset) ((unsigned int) UCH(array[offset]) + \ - (((unsigned int) UCH(array[offset+1])) << 8)) -#define GET_4B(array,offset) ((INT32) UCH(array[offset]) + \ - (((INT32) UCH(array[offset+1])) << 8) + \ - (((INT32) UCH(array[offset+2])) << 16) + \ - (((INT32) UCH(array[offset+3])) << 24)) +#define GET_2B(array, offset) ((unsigned int) UCH(array[offset]) + \ + (((unsigned int) UCH(array[offset+1])) << 8)) +#define GET_4B(array, offset) ((INT32) UCH(array[offset]) + \ + (((INT32) UCH(array[offset+1])) << 8) + \ + (((INT32) UCH(array[offset+2])) << 16) + \ + (((INT32) UCH(array[offset+3])) << 24)) INT32 bfOffBits; INT32 headerSize; INT32 biWidth; @@ -306,9 +290,9 @@ start_input_bmp (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) /* Read and verify the bitmap file header */ if (! ReadOK(source->pub.input_file, bmpfileheader, 14)) ERREXIT(cinfo, JERR_INPUT_EOF); - if (GET_2B(bmpfileheader,0) != 0x4D42) /* 'BM' */ + if (GET_2B(bmpfileheader, 0) != 0x4D42) /* 'BM' */ ERREXIT(cinfo, JERR_BMP_NOT); - bfOffBits = GET_4B(bmpfileheader,10); + bfOffBits = GET_4B(bmpfileheader, 10); /* We ignore the remaining fileheader fields */ /* The infoheader might be 12 bytes (OS/2 1.x), 40 bytes (Windows), @@ -316,19 +300,19 @@ start_input_bmp (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) */ if (! ReadOK(source->pub.input_file, bmpinfoheader, 4)) ERREXIT(cinfo, JERR_INPUT_EOF); - headerSize = GET_4B(bmpinfoheader,0); + headerSize = GET_4B(bmpinfoheader, 0); if (headerSize < 12 || headerSize > 64) ERREXIT(cinfo, JERR_BMP_BADHEADER); - if (! ReadOK(source->pub.input_file, bmpinfoheader+4, headerSize-4)) + if (! ReadOK(source->pub.input_file, bmpinfoheader + 4, headerSize - 4)) ERREXIT(cinfo, JERR_INPUT_EOF); switch ((int) headerSize) { case 12: /* Decode OS/2 1.x header (Microsoft calls this a BITMAPCOREHEADER) */ - biWidth = (INT32) GET_2B(bmpinfoheader,4); - biHeight = (INT32) GET_2B(bmpinfoheader,6); - biPlanes = GET_2B(bmpinfoheader,8); - source->bits_per_pixel = (int) GET_2B(bmpinfoheader,10); + biWidth = (INT32) GET_2B(bmpinfoheader, 4); + biHeight = (INT32) GET_2B(bmpinfoheader, 6); + biPlanes = GET_2B(bmpinfoheader, 8); + source->bits_per_pixel = (int) GET_2B(bmpinfoheader, 10); switch (source->bits_per_pixel) { case 8: /* colormapped image */ @@ -342,21 +326,20 @@ start_input_bmp (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) break; default: ERREXIT(cinfo, JERR_BMP_BADDEPTH); - break; } break; case 40: case 64: /* Decode Windows 3.x header (Microsoft calls this a BITMAPINFOHEADER) */ /* or OS/2 2.x header, which has additional fields that we ignore */ - biWidth = GET_4B(bmpinfoheader,4); - biHeight = GET_4B(bmpinfoheader,8); - biPlanes = GET_2B(bmpinfoheader,12); - source->bits_per_pixel = (int) GET_2B(bmpinfoheader,14); - biCompression = GET_4B(bmpinfoheader,16); - biXPelsPerMeter = GET_4B(bmpinfoheader,24); - biYPelsPerMeter = GET_4B(bmpinfoheader,28); - biClrUsed = GET_4B(bmpinfoheader,32); + biWidth = GET_4B(bmpinfoheader, 4); + biHeight = GET_4B(bmpinfoheader, 8); + biPlanes = GET_2B(bmpinfoheader, 12); + source->bits_per_pixel = (int) GET_2B(bmpinfoheader, 14); + biCompression = GET_4B(bmpinfoheader, 16); + biXPelsPerMeter = GET_4B(bmpinfoheader, 24); + biYPelsPerMeter = GET_4B(bmpinfoheader, 28); + biClrUsed = GET_4B(bmpinfoheader, 32); /* biSizeImage, biClrImportant fields are ignored */ switch (source->bits_per_pixel) { @@ -371,7 +354,6 @@ start_input_bmp (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) break; default: ERREXIT(cinfo, JERR_BMP_BADDEPTH); - break; } if (biCompression != 0) ERREXIT(cinfo, JERR_BMP_COMPRESSED); @@ -404,9 +386,8 @@ start_input_bmp (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) else if (biClrUsed > 256) ERREXIT(cinfo, JERR_BMP_BADCMAP); /* Allocate space to store the colormap */ - source->colormap = (*cinfo->mem->alloc_sarray) - ((j_common_ptr) cinfo, JPOOL_IMAGE, - (JDIMENSION) biClrUsed, (JDIMENSION) 3); + source->colormap = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, (JDIMENSION) biClrUsed, (JDIMENSION) 3); source->cmap_length = (int) biClrUsed; /* and read it from the file */ read_colormap(source, (int) biClrUsed, mapentrysize); @@ -442,9 +423,8 @@ start_input_bmp (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) } /* Allocate one-row buffer for returned data */ - source->pub.buffer = (*cinfo->mem->alloc_sarray) - ((j_common_ptr) cinfo, JPOOL_IMAGE, - (JDIMENSION) (biWidth * 3), (JDIMENSION) 1); + source->pub.buffer = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, (JDIMENSION) (biWidth * 3), (JDIMENSION) 1); source->pub.buffer_height = 1; cinfo->in_color_space = JCS_RGB; @@ -476,9 +456,8 @@ jinit_read_bmp (j_compress_ptr cinfo) bmp_source_ptr source; /* Create module interface object */ - source = (bmp_source_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(bmp_source_struct)); + source = (bmp_source_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(bmp_source_struct)); source->cinfo = cinfo; /* make back link for subroutines */ /* Fill in method ptrs, except get_pixel_rows which start_input sets */ source->pub.start_input = start_input_bmp; diff --git a/external/jpeg-9c/rdcolmap.c b/external/jpeg-9d/rdcolmap.c similarity index 100% rename from external/jpeg-9c/rdcolmap.c rename to external/jpeg-9d/rdcolmap.c diff --git a/external/jpeg-9d/rdgif.c b/external/jpeg-9d/rdgif.c new file mode 100644 index 00000000..08803ae2 --- /dev/null +++ b/external/jpeg-9d/rdgif.c @@ -0,0 +1,677 @@ +/* + * rdgif.c + * + * Copyright (C) 1991-1996, Thomas G. Lane. + * Modified 2019 by Guido Vollbeding. + * This file is part of the Independent JPEG Group's software. + * For conditions of distribution and use, see the accompanying README file. + * + * This file contains routines to read input images in GIF format. + * + * These routines may need modification for non-Unix environments or + * specialized applications. As they stand, they assume input from + * an ordinary stdio stream. They further assume that reading begins + * at the start of the file; start_input may need work if the + * user interface has already read some data (e.g., to determine that + * the file is indeed GIF format). + */ + +/* + * This code is loosely based on giftoppm from the PBMPLUS distribution + * of Feb. 1991. That file contains the following copyright notice: + * +-------------------------------------------------------------------+ + * | Copyright 1990, David Koblas. | + * | Permission to use, copy, modify, and distribute this software | + * | and its documentation for any purpose and without fee is hereby | + * | granted, provided that the above copyright notice appear in all | + * | copies and that both that copyright notice and this permission | + * | notice appear in supporting documentation. This software is | + * | provided "as is" without express or implied warranty. | + * +-------------------------------------------------------------------+ + */ + +#include "cdjpeg.h" /* Common decls for cjpeg/djpeg applications */ + +#ifdef GIF_SUPPORTED + + +/* Macros to deal with unsigned chars as efficiently as compiler allows */ + +#ifdef HAVE_UNSIGNED_CHAR +typedef unsigned char U_CHAR; +#define UCH(x) ((int) (x)) +#else /* !HAVE_UNSIGNED_CHAR */ +typedef char U_CHAR; +#ifdef CHAR_IS_UNSIGNED +#define UCH(x) ((int) (x)) +#else +#define UCH(x) ((int) (x) & 0xFF) +#endif +#endif /* HAVE_UNSIGNED_CHAR */ + + +#define ReadOK(file,buffer,len) (JFREAD(file,buffer,len) == ((size_t) (len))) + + +#define MAXCOLORMAPSIZE 256 /* max # of colors in a GIF colormap */ +#define NUMCOLORS 3 /* # of colors */ +#define CM_RED 0 /* color component numbers */ +#define CM_GREEN 1 +#define CM_BLUE 2 + +#define MAX_LZW_BITS 12 /* maximum LZW code size */ +#define LZW_TABLE_SIZE (1< table of prefix symbols */ + UINT8 FAR *symbol_tail; /* => table of suffix bytes */ + UINT8 FAR *symbol_stack; /* => stack for symbol expansions */ + UINT8 FAR *sp; /* stack pointer */ + + /* State for interlaced image processing */ + boolean is_interlaced; /* TRUE if have interlaced image */ + jvirt_sarray_ptr interlaced_image; /* full image in interlaced order */ + JDIMENSION cur_row_number; /* need to know actual row number */ + JDIMENSION pass2_offset; /* # of pixel rows in pass 1 */ + JDIMENSION pass3_offset; /* # of pixel rows in passes 1&2 */ + JDIMENSION pass4_offset; /* # of pixel rows in passes 1,2,3 */ +} gif_source_struct; + +typedef gif_source_struct * gif_source_ptr; + + +/* Forward declarations */ +METHODDEF(JDIMENSION) get_pixel_rows + JPP((j_compress_ptr cinfo, cjpeg_source_ptr sinfo)); +METHODDEF(JDIMENSION) load_interlaced_image + JPP((j_compress_ptr cinfo, cjpeg_source_ptr sinfo)); +METHODDEF(JDIMENSION) get_interlaced_row + JPP((j_compress_ptr cinfo, cjpeg_source_ptr sinfo)); + + +LOCAL(int) +ReadByte (gif_source_ptr sinfo) +/* Read next byte from GIF file */ +{ + register FILE *infile = sinfo->pub.input_file; + register int c; + + if ((c = getc(infile)) == EOF) + ERREXIT(sinfo->cinfo, JERR_INPUT_EOF); + return c; +} + + +LOCAL(int) +GetDataBlock (gif_source_ptr sinfo, U_CHAR *buf) +/* Read a GIF data block, which has a leading count byte */ +/* A zero-length block marks the end of a data block sequence */ +{ + int count; + + count = ReadByte(sinfo); + if (count > 0) { + if (! ReadOK(sinfo->pub.input_file, buf, count)) + ERREXIT(sinfo->cinfo, JERR_INPUT_EOF); + } + return count; +} + + +LOCAL(void) +SkipDataBlocks (gif_source_ptr sinfo) +/* Skip a series of data blocks, until a block terminator is found */ +{ + U_CHAR buf[256]; + + while (GetDataBlock(sinfo, buf) > 0) + /* skip */; +} + + +LOCAL(void) +ReInitLZW (gif_source_ptr sinfo) +/* (Re)initialize LZW state; shared code for startup and Clear processing */ +{ + sinfo->code_size = sinfo->input_code_size + 1; + sinfo->limit_code = sinfo->clear_code << 1; /* 2^code_size */ + sinfo->max_code = sinfo->clear_code + 2; /* first unused code value */ + sinfo->sp = sinfo->symbol_stack; /* init stack to empty */ +} + + +LOCAL(void) +InitLZWCode (gif_source_ptr sinfo) +/* Initialize for a series of LZWReadByte (and hence GetCode) calls */ +{ + /* GetCode initialization */ + sinfo->last_byte = 2; /* make safe to "recopy last two bytes" */ + sinfo->code_buf[0] = 0; + sinfo->code_buf[1] = 0; + sinfo->last_bit = 0; /* nothing in the buffer */ + sinfo->cur_bit = 0; /* force buffer load on first call */ + sinfo->first_time = TRUE; + sinfo->out_of_blocks = FALSE; + + /* LZWReadByte initialization: */ + /* compute special code values (note that these do not change later) */ + sinfo->clear_code = 1 << sinfo->input_code_size; + sinfo->end_code = sinfo->clear_code + 1; + ReInitLZW(sinfo); +} + + +LOCAL(int) +GetCode (gif_source_ptr sinfo) +/* Fetch the next code_size bits from the GIF data */ +/* We assume code_size is less than 16 */ +{ + register INT32 accum; + int offs, count; + + while (sinfo->cur_bit + sinfo->code_size > sinfo->last_bit) { + /* Time to reload the buffer */ + /* First time, share code with Clear case */ + if (sinfo->first_time) { + sinfo->first_time = FALSE; + return sinfo->clear_code; + } + if (sinfo->out_of_blocks) { + WARNMS(sinfo->cinfo, JWRN_GIF_NOMOREDATA); + return sinfo->end_code; /* fake something useful */ + } + /* preserve last two bytes of what we have -- assume code_size <= 16 */ + sinfo->code_buf[0] = sinfo->code_buf[sinfo->last_byte-2]; + sinfo->code_buf[1] = sinfo->code_buf[sinfo->last_byte-1]; + /* Load more bytes; set flag if we reach the terminator block */ + if ((count = GetDataBlock(sinfo, &sinfo->code_buf[2])) == 0) { + sinfo->out_of_blocks = TRUE; + WARNMS(sinfo->cinfo, JWRN_GIF_NOMOREDATA); + return sinfo->end_code; /* fake something useful */ + } + /* Reset counters */ + sinfo->cur_bit = (sinfo->cur_bit - sinfo->last_bit) + 16; + sinfo->last_byte = 2 + count; + sinfo->last_bit = sinfo->last_byte * 8; + } + + /* Form up next 24 bits in accum */ + offs = sinfo->cur_bit >> 3; /* byte containing cur_bit */ + accum = (INT32) UCH(sinfo->code_buf[offs+2]); + accum <<= 8; + accum |= (INT32) UCH(sinfo->code_buf[offs+1]); + accum <<= 8; + accum |= (INT32) UCH(sinfo->code_buf[offs]); + + /* Right-align cur_bit in accum, then mask off desired number of bits */ + accum >>= (sinfo->cur_bit & 7); + sinfo->cur_bit += sinfo->code_size; + return ((int) accum) & ((1 << sinfo->code_size) - 1); +} + + +LOCAL(int) +LZWReadByte (gif_source_ptr sinfo) +/* Read an LZW-compressed byte */ +{ + register int code; /* current working code */ + int incode; /* saves actual input code */ + + /* If any codes are stacked from a previously read symbol, return them */ + if (sinfo->sp > sinfo->symbol_stack) + return (int) *(-- sinfo->sp); + + /* Time to read a new symbol */ + code = GetCode(sinfo); + + if (code == sinfo->clear_code) { + /* Reinit state, swallow any extra Clear codes, and */ + /* return next code, which is expected to be a raw byte. */ + ReInitLZW(sinfo); + do { + code = GetCode(sinfo); + } while (code == sinfo->clear_code); + if (code > sinfo->clear_code) { /* make sure it is a raw byte */ + WARNMS(sinfo->cinfo, JWRN_GIF_BADDATA); + code = 0; /* use something valid */ + } + /* make firstcode, oldcode valid! */ + sinfo->firstcode = sinfo->oldcode = code; + return code; + } + + if (code == sinfo->end_code) { + /* Skip the rest of the image, unless GetCode already read terminator */ + if (! sinfo->out_of_blocks) { + SkipDataBlocks(sinfo); + sinfo->out_of_blocks = TRUE; + } + /* Complain that there's not enough data */ + WARNMS(sinfo->cinfo, JWRN_GIF_ENDCODE); + /* Pad data with 0's */ + return 0; /* fake something usable */ + } + + /* Got normal raw byte or LZW symbol */ + incode = code; /* save for a moment */ + + if (code >= sinfo->max_code) { /* special case for not-yet-defined symbol */ + /* code == max_code is OK; anything bigger is bad data */ + if (code > sinfo->max_code) { + WARNMS(sinfo->cinfo, JWRN_GIF_BADDATA); + incode = 0; /* prevent creation of loops in symbol table */ + } + /* this symbol will be defined as oldcode/firstcode */ + *(sinfo->sp++) = (UINT8) sinfo->firstcode; + code = sinfo->oldcode; + } + + /* If it's a symbol, expand it into the stack */ + while (code >= sinfo->clear_code) { + *(sinfo->sp++) = sinfo->symbol_tail[code]; /* tail is a byte value */ + code = sinfo->symbol_head[code]; /* head is another LZW symbol */ + } + /* At this point code just represents a raw byte */ + sinfo->firstcode = code; /* save for possible future use */ + + /* If there's room in table... */ + if ((code = sinfo->max_code) < LZW_TABLE_SIZE) { + /* Define a new symbol = prev sym + head of this sym's expansion */ + sinfo->symbol_head[code] = (UINT16) sinfo->oldcode; + sinfo->symbol_tail[code] = (UINT8) sinfo->firstcode; + sinfo->max_code++; + /* Is it time to increase code_size? */ + if (sinfo->max_code >= sinfo->limit_code && + sinfo->code_size < MAX_LZW_BITS) { + sinfo->code_size++; + sinfo->limit_code <<= 1; /* keep equal to 2^code_size */ + } + } + + sinfo->oldcode = incode; /* save last input symbol for future use */ + return sinfo->firstcode; /* return first byte of symbol's expansion */ +} + + +LOCAL(void) +ReadColorMap (gif_source_ptr sinfo, int cmaplen, JSAMPARRAY cmap) +/* Read a GIF colormap */ +{ + int i; + + for (i = 0; i < cmaplen; i++) { +#if BITS_IN_JSAMPLE == 8 +#define UPSCALE(x) (x) +#else +#define UPSCALE(x) ((x) << (BITS_IN_JSAMPLE-8)) +#endif + cmap[CM_RED ][i] = (JSAMPLE) UPSCALE(ReadByte(sinfo)); + cmap[CM_GREEN][i] = (JSAMPLE) UPSCALE(ReadByte(sinfo)); + cmap[CM_BLUE ][i] = (JSAMPLE) UPSCALE(ReadByte(sinfo)); + } +} + + +LOCAL(void) +DoExtension (gif_source_ptr sinfo) +/* Process an extension block */ +/* Currently we ignore 'em all */ +{ + int extlabel; + + /* Read extension label byte */ + extlabel = ReadByte(sinfo); + TRACEMS1(sinfo->cinfo, 1, JTRC_GIF_EXTENSION, extlabel); + /* Skip the data block(s) associated with the extension */ + SkipDataBlocks(sinfo); +} + + +/* + * Read the file header; return image size and component count. + */ + +METHODDEF(void) +start_input_gif (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) +{ + gif_source_ptr source = (gif_source_ptr) sinfo; + U_CHAR hdrbuf[10]; /* workspace for reading control blocks */ + unsigned int width, height; /* image dimensions */ + int colormaplen, aspectRatio; + int c; + + /* Read and verify GIF Header */ + if (! ReadOK(source->pub.input_file, hdrbuf, 6)) + ERREXIT(cinfo, JERR_GIF_NOT); + if (hdrbuf[0] != 'G' || hdrbuf[1] != 'I' || hdrbuf[2] != 'F') + ERREXIT(cinfo, JERR_GIF_NOT); + /* Check for expected version numbers. + * If unknown version, give warning and try to process anyway; + * this is per recommendation in GIF89a standard. + */ + if ((hdrbuf[3] != '8' || hdrbuf[4] != '7' || hdrbuf[5] != 'a') && + (hdrbuf[3] != '8' || hdrbuf[4] != '9' || hdrbuf[5] != 'a')) + TRACEMS3(cinfo, 1, JTRC_GIF_BADVERSION, hdrbuf[3], hdrbuf[4], hdrbuf[5]); + + /* Read and decipher Logical Screen Descriptor */ + if (! ReadOK(source->pub.input_file, hdrbuf, 7)) + ERREXIT(cinfo, JERR_INPUT_EOF); + width = LM_to_uint(hdrbuf, 0); + height = LM_to_uint(hdrbuf, 2); + /* we ignore the color resolution, sort flag, and background color index */ + aspectRatio = UCH(hdrbuf[6]); + if (aspectRatio != 0 && aspectRatio != 49) + TRACEMS(cinfo, 1, JTRC_GIF_NONSQUARE); + + /* Allocate space to store the colormap */ + source->colormap = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, (JDIMENSION) MAXCOLORMAPSIZE, (JDIMENSION) NUMCOLORS); + colormaplen = 0; /* indicate initialization */ + + /* Read global colormap if header indicates it is present */ + if (BitSet(hdrbuf[4], COLORMAPFLAG)) { + colormaplen = 2 << (hdrbuf[4] & 0x07); + ReadColorMap(source, colormaplen, source->colormap); + } + + /* Scan until we reach start of desired image. + * We don't currently support skipping images, but could add it easily. + */ + for (;;) { + c = ReadByte(source); + + if (c == ';') /* GIF terminator?? */ + ERREXIT(cinfo, JERR_GIF_IMAGENOTFOUND); + + if (c == '!') { /* Extension */ + DoExtension(source); + continue; + } + + if (c != ',') { /* Not an image separator? */ + WARNMS1(cinfo, JWRN_GIF_CHAR, c); + continue; + } + + /* Read and decipher Local Image Descriptor */ + if (! ReadOK(source->pub.input_file, hdrbuf, 9)) + ERREXIT(cinfo, JERR_INPUT_EOF); + /* we ignore top/left position info, also sort flag */ + width = LM_to_uint(hdrbuf, 4); + height = LM_to_uint(hdrbuf, 6); + source->is_interlaced = (BitSet(hdrbuf[8], INTERLACE) != 0); + + /* Read local colormap if header indicates it is present */ + /* Note: if we wanted to support skipping images, */ + /* we'd need to skip rather than read colormap for ignored images */ + if (BitSet(hdrbuf[8], COLORMAPFLAG)) { + colormaplen = 2 << (hdrbuf[8] & 0x07); + ReadColorMap(source, colormaplen, source->colormap); + } + + source->input_code_size = ReadByte(source); /* get min-code-size byte */ + if (source->input_code_size < 2 || source->input_code_size > 8) + ERREXIT1(cinfo, JERR_GIF_CODESIZE, source->input_code_size); + + /* Reached desired image, so break out of loop */ + /* If we wanted to skip this image, */ + /* we'd call SkipDataBlocks and then continue the loop */ + break; + } + + /* Prepare to read selected image: first initialize LZW decompressor */ + source->symbol_head = (UINT16 FAR *) (*cinfo->mem->alloc_large) + ((j_common_ptr) cinfo, JPOOL_IMAGE, LZW_TABLE_SIZE * SIZEOF(UINT16)); + source->symbol_tail = (UINT8 FAR *) (*cinfo->mem->alloc_large) + ((j_common_ptr) cinfo, JPOOL_IMAGE, LZW_TABLE_SIZE * SIZEOF(UINT8)); + source->symbol_stack = (UINT8 FAR *) (*cinfo->mem->alloc_large) + ((j_common_ptr) cinfo, JPOOL_IMAGE, LZW_TABLE_SIZE * SIZEOF(UINT8)); + InitLZWCode(source); + + /* + * If image is interlaced, we read it into a full-size sample array, + * decompressing as we go; then get_interlaced_row selects rows from the + * sample array in the proper order. + */ + if (source->is_interlaced) { + /* We request the virtual array now, but can't access it until virtual + * arrays have been allocated. Hence, the actual work of reading the + * image is postponed until the first call to get_pixel_rows. + */ + source->interlaced_image = (*cinfo->mem->request_virt_sarray) + ((j_common_ptr) cinfo, JPOOL_IMAGE, FALSE, + (JDIMENSION) width, (JDIMENSION) height, (JDIMENSION) 1); + if (cinfo->progress != NULL) { + cd_progress_ptr progress = (cd_progress_ptr) cinfo->progress; + progress->total_extra_passes++; /* count file input as separate pass */ + } + source->pub.get_pixel_rows = load_interlaced_image; + } else { + source->pub.get_pixel_rows = get_pixel_rows; + } + + /* Create compressor input buffer. */ + source->pub.buffer = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, (JDIMENSION) width * NUMCOLORS, (JDIMENSION) 1); + source->pub.buffer_height = 1; + + /* Pad colormap for safety. */ + for (c = colormaplen; c < source->clear_code; c++) { + source->colormap[CM_RED ][c] = + source->colormap[CM_GREEN][c] = + source->colormap[CM_BLUE ][c] = CENTERJSAMPLE; + } + + /* Return info about the image. */ + cinfo->in_color_space = JCS_RGB; + cinfo->input_components = NUMCOLORS; + cinfo->data_precision = BITS_IN_JSAMPLE; /* we always rescale data to this */ + cinfo->image_width = width; + cinfo->image_height = height; + + TRACEMS3(cinfo, 1, JTRC_GIF, width, height, colormaplen); +} + + +/* + * Read one row of pixels. + * This version is used for noninterlaced GIF images: + * we read directly from the GIF file. + */ + +METHODDEF(JDIMENSION) +get_pixel_rows (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) +{ + gif_source_ptr source = (gif_source_ptr) sinfo; + register int c; + register JSAMPROW ptr; + register JDIMENSION col; + register JSAMPARRAY colormap = source->colormap; + + ptr = source->pub.buffer[0]; + for (col = cinfo->image_width; col > 0; col--) { + c = LZWReadByte(source); + *ptr++ = colormap[CM_RED ][c]; + *ptr++ = colormap[CM_GREEN][c]; + *ptr++ = colormap[CM_BLUE ][c]; + } + return 1; +} + + +/* + * Read one row of pixels. + * This version is used for the first call on get_pixel_rows when + * reading an interlaced GIF file: we read the whole image into memory. + */ + +METHODDEF(JDIMENSION) +load_interlaced_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) +{ + gif_source_ptr source = (gif_source_ptr) sinfo; + register JSAMPROW sptr; + register JDIMENSION col; + JDIMENSION row; + cd_progress_ptr progress = (cd_progress_ptr) cinfo->progress; + + /* Read the interlaced image into the virtual array we've created. */ + for (row = 0; row < cinfo->image_height; row++) { + if (progress != NULL) { + progress->pub.pass_counter = (long) row; + progress->pub.pass_limit = (long) cinfo->image_height; + (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); + } + sptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + source->interlaced_image, row, (JDIMENSION) 1, TRUE); + for (col = cinfo->image_width; col > 0; col--) { + *sptr++ = (JSAMPLE) LZWReadByte(source); + } + } + if (progress != NULL) + progress->completed_extra_passes++; + + /* Replace method pointer so subsequent calls don't come here. */ + source->pub.get_pixel_rows = get_interlaced_row; + /* Initialize for get_interlaced_row, and perform first call on it. */ + source->cur_row_number = 0; + source->pass2_offset = (cinfo->image_height + 7) / 8; + source->pass3_offset = source->pass2_offset + (cinfo->image_height + 3) / 8; + source->pass4_offset = source->pass3_offset + (cinfo->image_height + 1) / 4; + + return get_interlaced_row(cinfo, sinfo); +} + + +/* + * Read one row of pixels. + * This version is used for interlaced GIF images: + * we read from the virtual array. + */ + +METHODDEF(JDIMENSION) +get_interlaced_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) +{ + gif_source_ptr source = (gif_source_ptr) sinfo; + register int c; + register JSAMPROW sptr, ptr; + register JDIMENSION col; + register JSAMPARRAY colormap = source->colormap; + JDIMENSION irow; + + /* Figure out which row of interlaced image is needed, and access it. */ + switch ((int) (source->cur_row_number & 7)) { + case 0: /* first-pass row */ + irow = source->cur_row_number >> 3; + break; + case 4: /* second-pass row */ + irow = (source->cur_row_number >> 3) + source->pass2_offset; + break; + case 2: /* third-pass row */ + case 6: + irow = (source->cur_row_number >> 2) + source->pass3_offset; + break; + default: /* fourth-pass row */ + irow = (source->cur_row_number >> 1) + source->pass4_offset; + } + sptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + source->interlaced_image, irow, (JDIMENSION) 1, FALSE); + /* Scan the row, expand colormap, and output */ + ptr = source->pub.buffer[0]; + for (col = cinfo->image_width; col > 0; col--) { + c = GETJSAMPLE(*sptr++); + *ptr++ = colormap[CM_RED ][c]; + *ptr++ = colormap[CM_GREEN][c]; + *ptr++ = colormap[CM_BLUE ][c]; + } + source->cur_row_number++; /* for next time */ + return 1; +} + + +/* + * Finish up at the end of the file. + */ + +METHODDEF(void) +finish_input_gif (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) +{ + /* no work */ +} + + +/* + * The module selection routine for GIF format input. + */ + +GLOBAL(cjpeg_source_ptr) +jinit_read_gif (j_compress_ptr cinfo) +{ + gif_source_ptr source; + + /* Create module interface object */ + source = (gif_source_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(gif_source_struct)); + source->cinfo = cinfo; /* make back link for subroutines */ + /* Fill in method ptrs, except get_pixel_rows which start_input sets */ + source->pub.start_input = start_input_gif; + source->pub.finish_input = finish_input_gif; + + return &source->pub; +} + +#endif /* GIF_SUPPORTED */ diff --git a/external/jpeg-9c/rdjpgcom.1 b/external/jpeg-9d/rdjpgcom.1 similarity index 100% rename from external/jpeg-9c/rdjpgcom.1 rename to external/jpeg-9d/rdjpgcom.1 diff --git a/external/jpeg-9c/rdjpgcom.c b/external/jpeg-9d/rdjpgcom.c similarity index 100% rename from external/jpeg-9c/rdjpgcom.c rename to external/jpeg-9d/rdjpgcom.c diff --git a/external/jpeg-9c/rdppm.c b/external/jpeg-9d/rdppm.c similarity index 97% rename from external/jpeg-9c/rdppm.c rename to external/jpeg-9d/rdppm.c index 357ce9e3..33e469ac 100644 --- a/external/jpeg-9c/rdppm.c +++ b/external/jpeg-9d/rdppm.c @@ -2,7 +2,7 @@ * rdppm.c * * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2009-2017 by Bill Allombert, Guido Vollbeding. + * Modified 2009-2019 by Bill Allombert, Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -19,11 +19,6 @@ * the file is indeed PPM format). */ -#include "cdjpeg.h" /* Common decls for cjpeg/djpeg applications */ - -#ifdef PPM_SUPPORTED - - /* Portions of this code are based on the PBMPLUS library, which is: ** ** Copyright (C) 1988 by Jef Poskanzer. @@ -36,6 +31,10 @@ ** implied warranty. */ +#include "cdjpeg.h" /* Common decls for cjpeg/djpeg applications */ + +#ifdef PPM_SUPPORTED + /* Macros to deal with unsigned chars as efficiently as compiler allows */ @@ -43,11 +42,10 @@ typedef unsigned char U_CHAR; #define UCH(x) ((int) (x)) #else /* !HAVE_UNSIGNED_CHAR */ -#ifdef CHAR_IS_UNSIGNED typedef char U_CHAR; +#ifdef CHAR_IS_UNSIGNED #define UCH(x) ((int) (x)) #else -typedef char U_CHAR; #define UCH(x) ((int) (x) & 0xFF) #endif #endif /* HAVE_UNSIGNED_CHAR */ @@ -358,7 +356,6 @@ start_input_ppm (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) break; default: ERREXIT(cinfo, JERR_PPM_NOT); - break; } /* fetch the remaining header info */ @@ -449,9 +446,8 @@ start_input_ppm (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) source->pub.buffer_height = 1; } else { /* Need to translate anyway, so make a separate sample buffer. */ - source->pub.buffer = (*cinfo->mem->alloc_sarray) - ((j_common_ptr) cinfo, JPOOL_IMAGE, - (JDIMENSION) w * cinfo->input_components, (JDIMENSION) 1); + source->pub.buffer = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, (JDIMENSION) w * cinfo->input_components, (JDIMENSION) 1); source->pub.buffer_height = 1; } @@ -461,7 +457,7 @@ start_input_ppm (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) /* On 16-bit-int machines we have to be careful of maxval = 65535 */ source->rescale = (JSAMPLE *) (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, - JPOOL_IMAGE, (size_t) (((long) maxval + 1L) * SIZEOF(JSAMPLE))); + JPOOL_IMAGE, ((size_t) maxval + (size_t) 1) * SIZEOF(JSAMPLE)); half_maxval = maxval / 2; for (val = 0; val <= (INT32) maxval; val++) { /* The multiplication here must be done in 32 bits to avoid overflow */ @@ -492,9 +488,8 @@ jinit_read_ppm (j_compress_ptr cinfo) ppm_source_ptr source; /* Create module interface object */ - source = (ppm_source_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(ppm_source_struct)); + source = (ppm_source_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(ppm_source_struct)); /* Fill in method ptrs, except get_pixel_rows which start_input sets */ source->pub.start_input = start_input_ppm; source->pub.finish_input = finish_input_ppm; diff --git a/external/jpeg-9c/rdrle.c b/external/jpeg-9d/rdrle.c similarity index 86% rename from external/jpeg-9c/rdrle.c rename to external/jpeg-9d/rdrle.c index 542bc374..06f2e8aa 100644 --- a/external/jpeg-9c/rdrle.c +++ b/external/jpeg-9d/rdrle.c @@ -2,6 +2,7 @@ * rdrle.c * * Copyright (C) 1991-1996, Thomas G. Lane. + * Modified 2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -68,7 +69,7 @@ typedef struct _rle_source_struct { jvirt_sarray_ptr image; /* virtual array to hold the image */ JDIMENSION row; /* current row # in the virtual array */ rle_hdr header; /* Input file information */ - rle_pixel** rle_row; /* holds a row returned by rle_getrow() */ + rle_pixel **rle_row; /* holds a row returned by rle_getrow() */ } rle_source_struct; @@ -95,19 +96,14 @@ start_input_rle (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) break; case RLE_NOT_RLE: ERREXIT(cinfo, JERR_RLE_NOT); - break; case RLE_NO_SPACE: ERREXIT(cinfo, JERR_RLE_MEM); - break; case RLE_EMPTY: ERREXIT(cinfo, JERR_RLE_EMPTY); - break; case RLE_EOF: ERREXIT(cinfo, JERR_RLE_EOF); - break; default: ERREXIT(cinfo, JERR_RLE_BADERROR); - break; } /* Figure out what we have, set private vars and return values accordingly */ @@ -155,16 +151,15 @@ start_input_rle (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) * (GRAYSCALE scanlines don't need converting) */ if (source->visual != GRAYSCALE) { - source->rle_row = (rle_pixel**) (*cinfo->mem->alloc_sarray) + source->rle_row = (rle_pixel **) (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (JDIMENSION) width, (JDIMENSION) cinfo->input_components); + width, (JDIMENSION) cinfo->input_components); } /* request a virtual array to hold the image */ source->image = (*cinfo->mem->request_virt_sarray) ((j_common_ptr) cinfo, JPOOL_IMAGE, FALSE, - (JDIMENSION) (width * source->header.ncolors), - (JDIMENSION) height, (JDIMENSION) 1); + width * (JDIMENSION) source->header.ncolors, height, (JDIMENSION) 1); #ifdef PROGRESS_REPORT if (progress != NULL) { @@ -242,7 +237,7 @@ load_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) { rle_source_ptr source = (rle_source_ptr) sinfo; JDIMENSION row, col; - JSAMPROW scanline, red_ptr, green_ptr, blue_ptr; + JSAMPROW scanline, red_ptr, green_ptr, blue_ptr; rle_pixel **rle_row; rle_map *colormap; char channel; @@ -250,9 +245,6 @@ load_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) cd_progress_ptr progress = (cd_progress_ptr) cinfo->progress; #endif - colormap = source->header.cmap; - rle_row = source->rle_row; - /* Read the RLE data into our virtual array. * We assume here that (a) rle_pixel is represented the same as JSAMPLE, * and (b) we are not on a machine where FAR pointers differ from regular. @@ -273,12 +265,12 @@ load_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) case PSEUDOCOLOR: for (row = 0; row < cinfo->image_height; row++) { rle_row = (rle_pixel **) (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, source->image, row, (JDIMENSION) 1, TRUE); + ((j_common_ptr) cinfo, source->image, row, (JDIMENSION) 1, TRUE); rle_getrow(&source->header, rle_row); #ifdef PROGRESS_REPORT if (progress != NULL) { - progress->pub.pass_counter++; - (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); + progress->pub.pass_counter++; + (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); } #endif } @@ -286,48 +278,50 @@ load_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) case MAPPEDGRAY: case TRUECOLOR: + rle_row = source->rle_row; + colormap = source->header.cmap; for (row = 0; row < cinfo->image_height; row++) { - scanline = * (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, source->image, row, (JDIMENSION) 1, TRUE); - rle_row = source->rle_row; rle_getrow(&source->header, rle_row); + scanline = * (*cinfo->mem->access_virt_sarray) + ((j_common_ptr) cinfo, source->image, row, (JDIMENSION) 1, TRUE); for (col = 0; col < cinfo->image_width; col++) { - for (channel = 0; channel < source->header.ncolors; channel++) { - *scanline++ = (JSAMPLE) - (colormap[GETJSAMPLE(rle_row[channel][col]) + 256 * channel] >> 8); - } + for (channel = 0; channel < source->header.ncolors; channel++) { + *scanline++ = (JSAMPLE) + (colormap[GETJSAMPLE(rle_row[channel][col]) + 256 * channel] >> 8); + } } #ifdef PROGRESS_REPORT if (progress != NULL) { - progress->pub.pass_counter++; - (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); + progress->pub.pass_counter++; + (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); } #endif } break; case DIRECTCOLOR: + rle_row = source->rle_row; for (row = 0; row < cinfo->image_height; row++) { - scanline = * (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, source->image, row, (JDIMENSION) 1, TRUE); rle_getrow(&source->header, rle_row); + scanline = * (*cinfo->mem->access_virt_sarray) + ((j_common_ptr) cinfo, source->image, row, (JDIMENSION) 1, TRUE); red_ptr = rle_row[0]; green_ptr = rle_row[1]; blue_ptr = rle_row[2]; for (col = cinfo->image_width; col > 0; col--) { - *scanline++ = *red_ptr++; - *scanline++ = *green_ptr++; - *scanline++ = *blue_ptr++; + *scanline++ = *red_ptr++; + *scanline++ = *green_ptr++; + *scanline++ = *blue_ptr++; } #ifdef PROGRESS_REPORT if (progress != NULL) { - progress->pub.pass_counter++; - (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); + progress->pub.pass_counter++; + (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); } #endif } @@ -373,15 +367,14 @@ jinit_read_rle (j_compress_ptr cinfo) rle_source_ptr source; /* Create module interface object */ - source = (rle_source_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(rle_source_struct)); + source = (rle_source_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(rle_source_struct)); /* Fill in method ptrs */ source->pub.start_input = start_input_rle; source->pub.finish_input = finish_input_rle; source->pub.get_pixel_rows = load_image; - return (cjpeg_source_ptr) source; + return &source->pub; } #endif /* RLE_SUPPORTED */ diff --git a/external/jpeg-9c/rdswitch.c b/external/jpeg-9d/rdswitch.c similarity index 98% rename from external/jpeg-9c/rdswitch.c rename to external/jpeg-9d/rdswitch.c index b5aba83c..c0f7fed8 100644 --- a/external/jpeg-9c/rdswitch.c +++ b/external/jpeg-9d/rdswitch.c @@ -2,7 +2,7 @@ * rdswitch.c * * Copyright (C) 1991-1996, Thomas G. Lane. - * Modified 2003-2015 by Guido Vollbeding. + * Modified 2003-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -249,9 +249,8 @@ read_scan_script (j_compress_ptr cinfo, char * filename) * NOTE: for cjpeg's use, JPOOL_IMAGE is the right lifetime for this data, * but if you want to compress multiple images you'd want JPOOL_PERMANENT. */ - scanptr = (jpeg_scan_info *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - scanno * SIZEOF(jpeg_scan_info)); + scanptr = (jpeg_scan_info *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, scanno * SIZEOF(jpeg_scan_info)); MEMCOPY(scanptr, scans, scanno * SIZEOF(jpeg_scan_info)); cinfo->scan_info = scanptr; cinfo->num_scans = scanno; diff --git a/external/jpeg-9c/rdtarga.c b/external/jpeg-9d/rdtarga.c similarity index 94% rename from external/jpeg-9c/rdtarga.c rename to external/jpeg-9d/rdtarga.c index b3a7251c..c72ad73f 100644 --- a/external/jpeg-9c/rdtarga.c +++ b/external/jpeg-9d/rdtarga.c @@ -2,7 +2,7 @@ * rdtarga.c * * Copyright (C) 1991-1996, Thomas G. Lane. - * Modified 2017 by Guido Vollbeding. + * Modified 2017-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -29,11 +29,10 @@ typedef unsigned char U_CHAR; #define UCH(x) ((int) (x)) #else /* !HAVE_UNSIGNED_CHAR */ -#ifdef CHAR_IS_UNSIGNED typedef char U_CHAR; +#ifdef CHAR_IS_UNSIGNED #define UCH(x) ((int) (x)) #else -typedef char U_CHAR; #define UCH(x) ((int) (x) & 0xFF) #endif #endif /* HAVE_UNSIGNED_CHAR */ @@ -125,20 +124,17 @@ METHODDEF(void) read_non_rle_pixel (tga_source_ptr sinfo) /* Read one Targa pixel from the input file; no RLE expansion */ { - register FILE *infile = sinfo->pub.input_file; register int i; for (i = 0; i < sinfo->pixel_size; i++) { - sinfo->tga_pixel[i] = (U_CHAR) getc(infile); + sinfo->tga_pixel[i] = (U_CHAR) read_byte(sinfo); } } - METHODDEF(void) read_rle_pixel (tga_source_ptr sinfo) /* Read one Targa pixel from the input file, expanding RLE data as needed */ { - register FILE *infile = sinfo->pub.input_file; register int i; /* Duplicate previously read pixel? */ @@ -160,7 +156,7 @@ read_rle_pixel (tga_source_ptr sinfo) /* Read next pixel */ for (i = 0; i < sinfo->pixel_size; i++) { - sinfo->tga_pixel[i] = (U_CHAR) getc(infile); + sinfo->tga_pixel[i] = (U_CHAR) read_byte(sinfo); } } @@ -171,7 +167,6 @@ read_rle_pixel (tga_source_ptr sinfo) * We provide several different versions depending on input file format. */ - METHODDEF(JDIMENSION) get_8bit_gray_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) /* This version is for reading 8-bit grayscale pixels */ @@ -288,9 +283,8 @@ get_memory_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) source_row = cinfo->image_height - source->current_row - 1; /* Fetch that row from virtual array */ - source->pub.buffer = (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, source->whole_image, - source_row, (JDIMENSION) 1, FALSE); + source->pub.buffer = (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + source->whole_image, source_row, (JDIMENSION) 1, FALSE); source->current_row++; return 1; @@ -409,7 +403,6 @@ start_input_tga (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) break; default: ERREXIT(cinfo, JERR_TGA_BADPARMS); - break; } TRACEMS2(cinfo, 1, JTRC_TGA, width, height); break; @@ -424,7 +417,6 @@ start_input_tga (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) break; default: ERREXIT(cinfo, JERR_TGA_BADPARMS); - break; } if (is_bottom_up) { @@ -442,9 +434,8 @@ start_input_tga (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) } else { /* Don't need a virtual array, but do need a one-row input buffer. */ source->whole_image = NULL; - source->pub.buffer = (*cinfo->mem->alloc_sarray) - ((j_common_ptr) cinfo, JPOOL_IMAGE, - (JDIMENSION) width * components, (JDIMENSION) 1); + source->pub.buffer = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, (JDIMENSION) width * components, (JDIMENSION) 1); source->pub.buffer_height = 1; source->pub.get_pixel_rows = source->get_pixel_rows; } @@ -456,8 +447,8 @@ start_input_tga (j_compress_ptr cinfo, cjpeg_source_ptr sinfo) if (maplen > 256 || GET_2B(3) != 0) ERREXIT(cinfo, JERR_TGA_BADCMAP); /* Allocate space to store the colormap */ - source->colormap = (*cinfo->mem->alloc_sarray) - ((j_common_ptr) cinfo, JPOOL_IMAGE, (JDIMENSION) maplen, (JDIMENSION) 3); + source->colormap = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, (JDIMENSION) maplen, (JDIMENSION) 3); source->cmap_length = (int) maplen; /* and read it from the file */ read_colormap(source, (int) maplen, UCH(targaheader[7])); @@ -496,9 +487,8 @@ jinit_read_targa (j_compress_ptr cinfo) tga_source_ptr source; /* Create module interface object */ - source = (tga_source_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(tga_source_struct)); + source = (tga_source_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(tga_source_struct)); source->cinfo = cinfo; /* make back link for subroutines */ /* Fill in method ptrs, except get_pixel_rows which start_input sets */ source->pub.start_input = start_input_tga; diff --git a/external/jpeg-9c/structure.txt b/external/jpeg-9d/structure.txt similarity index 100% rename from external/jpeg-9c/structure.txt rename to external/jpeg-9d/structure.txt diff --git a/external/jpeg-9c/testimg.bmp b/external/jpeg-9d/testimg.bmp similarity index 100% rename from external/jpeg-9c/testimg.bmp rename to external/jpeg-9d/testimg.bmp diff --git a/external/jpeg-9d/testimg.gif b/external/jpeg-9d/testimg.gif new file mode 100644 index 0000000000000000000000000000000000000000..f4d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O&C55`m$m_sU} zg86rOL(OXrx*e=K(d9c=mx}2>i`Nj^6kg`BsIgFk%~@~;p4!7~*v4JFq3E#yVx5%V zyJF`$U1f{ruV0bcuR)3Qa^8M>q}N|i0FnCdu>-dk8@1D@hPEJA%k93=>YI3fXO4DV zL(F%+08jWsII~{~bYx0VzSX)_KPp=3e|I-C%(` z;bf&oIxY}1nUK;&)jwCN6eWSU7mnr`9&XsrH4=X~!@51s0W31rTAk2s6~NkmVu3y3 zJ04bUvY=w6_G4JrC5-p9>!6mn^W`D;^aGw_h`S-LC1v6m%(e|Fl3t)IpvAg1@Vd$4 zkf773FrO_sHmyK{2K7vXeUyfknqiQ#Uggzy*RM|o*LKd?Cjd*yz}05Fs@$H%D>c)+ z-@|Wdjk5%uNE?aq3(=f4o(B+UvOC#2=Dxg6W-G~rQZBl<%8RA1IV<)`DK4ypRek?a zd7l^R^E-kJNAwn2+bv^go%8+*;|Y(;9iJZUKD3d1RD^+FRUggrwR)ks;6GQH+64u- z&PIOAieHH_PNe3n?-?xfEwVkyAowYoosP7t^{?=~8LUsr2P|yErqs8Yu?)vz3>9#4 z^YSP|ck_47u56=}^9vk@EN?mb%4*o3`MR|$OYN4IfM>n?mclient_data; + + return (*srcinfo->mem->request_virt_barray) + (srcinfo, pool_id, pre_zero, + blocksperrow, numrows, maxaccess); +} + + +/* Force jpeg_read_coefficients to return + * after requesting and before accessing + * the virtual coefficient arrays. + */ +METHODDEF(int) +drop_consume_input (j_decompress_ptr cinfo) +{ + return JPEG_SUSPENDED; +} + + +METHODDEF(void) +drop_start_input_pass (j_decompress_ptr cinfo) +{ + cinfo->inputctl->consume_input = drop_consume_input; +} + + +LOCAL(void) +drop_request_from_src (j_decompress_ptr dropinfo, j_decompress_ptr srcinfo) +{ + void *save_client_data; + JMETHOD(jvirt_barray_ptr, save_request_virt_barray, + (j_common_ptr cinfo, int pool_id, boolean pre_zero, + JDIMENSION blocksperrow, JDIMENSION numrows, JDIMENSION maxaccess)); + JMETHOD(void, save_start_input_pass, (j_decompress_ptr cinfo)); + + /* Set custom method pointers, save original pointers */ + save_client_data = dropinfo->client_data; + dropinfo->client_data = (void *) srcinfo; + save_request_virt_barray = dropinfo->mem->request_virt_barray; + dropinfo->mem->request_virt_barray = drop_request_virt_barray; + save_start_input_pass = dropinfo->inputctl->start_input_pass; + dropinfo->inputctl->start_input_pass = drop_start_input_pass; + + /* Execute only initialization part. + * Requested coefficient arrays will be realized later by the srcinfo object. + * Next call to the same function will then do the actual data reading. + * NB: since we request the coefficient arrays from another object, + * the inherent realization call is effectively a no-op. + */ + (void) jpeg_read_coefficients(dropinfo); + + /* Reset method pointers */ + dropinfo->client_data = save_client_data; + dropinfo->mem->request_virt_barray = save_request_virt_barray; + dropinfo->inputctl->start_input_pass = save_start_input_pass; + /* Do input initialization for first scan now, + * which also resets the consume_input method. + */ + (*save_start_input_pass)(dropinfo); +} +#endif /* DROP_REQUEST_FROM_SRC */ + + +LOCAL(void) +dequant_comp (j_decompress_ptr cinfo, jpeg_component_info *compptr, + jvirt_barray_ptr coef_array, JQUANT_TBL *qtblptr1) +{ + JDIMENSION blk_x, blk_y; + int offset_y, k; + JQUANT_TBL *qtblptr; + JBLOCKARRAY buffer; + JBLOCKROW block; + JCOEFPTR ptr; + + qtblptr = compptr->quant_table; + for (blk_y = 0; blk_y < compptr->height_in_blocks; + blk_y += compptr->v_samp_factor) { + buffer = (*cinfo->mem->access_virt_barray) + ((j_common_ptr) cinfo, coef_array, blk_y, + (JDIMENSION) compptr->v_samp_factor, TRUE); + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + block = buffer[offset_y]; + for (blk_x = 0; blk_x < compptr->width_in_blocks; blk_x++) { + ptr = block[blk_x]; + for (k = 0; k < DCTSIZE2; k++) + if (qtblptr->quantval[k] != qtblptr1->quantval[k]) + ptr[k] *= qtblptr->quantval[k] / qtblptr1->quantval[k]; + } + } + } +} + + +LOCAL(void) +requant_comp (j_decompress_ptr cinfo, jpeg_component_info *compptr, + jvirt_barray_ptr coef_array, JQUANT_TBL *qtblptr1) +{ + JDIMENSION blk_x, blk_y; + int offset_y, k; + JQUANT_TBL *qtblptr; + JBLOCKARRAY buffer; + JBLOCKROW block; + JCOEFPTR ptr; + JCOEF temp, qval; + + qtblptr = compptr->quant_table; + for (blk_y = 0; blk_y < compptr->height_in_blocks; + blk_y += compptr->v_samp_factor) { + buffer = (*cinfo->mem->access_virt_barray) + ((j_common_ptr) cinfo, coef_array, blk_y, + (JDIMENSION) compptr->v_samp_factor, TRUE); + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + block = buffer[offset_y]; + for (blk_x = 0; blk_x < compptr->width_in_blocks; blk_x++) { + ptr = block[blk_x]; + for (k = 0; k < DCTSIZE2; k++) { + temp = qtblptr->quantval[k]; + qval = qtblptr1->quantval[k]; + if (temp != qval) { + temp *= ptr[k]; + /* The following quantization code is a copy from jcdctmgr.c */ +#ifdef FAST_DIVIDE +#define DIVIDE_BY(a,b) a /= b +#else +#define DIVIDE_BY(a,b) if (a >= b) a /= b; else a = 0 +#endif + if (temp < 0) { + temp = -temp; + temp += qval>>1; /* for rounding */ + DIVIDE_BY(temp, qval); + temp = -temp; + } else { + temp += qval>>1; /* for rounding */ + DIVIDE_BY(temp, qval); + } + ptr[k] = temp; + } + } + } + } + } +} + + +/* Calculate largest common denominator with Euclid's algorithm. + */ +LOCAL(JCOEF) +largest_common_denominator(JCOEF a, JCOEF b) +{ + JCOEF c; + + do { + c = a % b; + a = b; + b = c; + } while (c); + + return a; +} + + +LOCAL(void) +adjust_quant(j_decompress_ptr srcinfo, jvirt_barray_ptr *src_coef_arrays, + j_decompress_ptr dropinfo, jvirt_barray_ptr *drop_coef_arrays, + boolean trim, j_compress_ptr dstinfo) +{ + jpeg_component_info *compptr1, *compptr2; + JQUANT_TBL *qtblptr1, *qtblptr2, *qtblptr3; + int ci, k; + + for (ci = 0; ci < dstinfo->num_components && + ci < dropinfo->num_components; ci++) { + compptr1 = srcinfo->comp_info + ci; + compptr2 = dropinfo->comp_info + ci; + qtblptr1 = compptr1->quant_table; + qtblptr2 = compptr2->quant_table; + for (k = 0; k < DCTSIZE2; k++) { + if (qtblptr1->quantval[k] != qtblptr2->quantval[k]) { + if (trim) + requant_comp(dropinfo, compptr2, drop_coef_arrays[ci], qtblptr1); + else { + qtblptr3 = dstinfo->quant_tbl_ptrs[compptr1->quant_tbl_no]; + for (k = 0; k < DCTSIZE2; k++) + if (qtblptr1->quantval[k] != qtblptr2->quantval[k]) + qtblptr3->quantval[k] = largest_common_denominator + (qtblptr1->quantval[k], qtblptr2->quantval[k]); + dequant_comp(srcinfo, compptr1, src_coef_arrays[ci], qtblptr3); + dequant_comp(dropinfo, compptr2, drop_coef_arrays[ci], qtblptr3); + } + break; + } + } + } +} + + +LOCAL(void) +do_drop (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, + JDIMENSION x_crop_offset, JDIMENSION y_crop_offset, + jvirt_barray_ptr *src_coef_arrays, + j_decompress_ptr dropinfo, jvirt_barray_ptr *drop_coef_arrays, + JDIMENSION drop_width, JDIMENSION drop_height) +/* Drop. If the dropinfo component number is smaller than the destination's, + * we fill in the remaining components with zero. This provides the feature + * of dropping grayscale into (arbitrarily sampled) color images. + */ +{ + JDIMENSION comp_width, comp_height; + JDIMENSION blk_y, x_drop_blocks, y_drop_blocks; + int ci, offset_y; + JBLOCKARRAY src_buffer, dst_buffer; + jpeg_component_info *compptr; + + for (ci = 0; ci < dstinfo->num_components; ci++) { + compptr = dstinfo->comp_info + ci; + comp_width = drop_width * compptr->h_samp_factor; + comp_height = drop_height * compptr->v_samp_factor; + x_drop_blocks = x_crop_offset * compptr->h_samp_factor; + y_drop_blocks = y_crop_offset * compptr->v_samp_factor; + for (blk_y = 0; blk_y < comp_height; blk_y += compptr->v_samp_factor) { + dst_buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, src_coef_arrays[ci], blk_y + y_drop_blocks, + (JDIMENSION) compptr->v_samp_factor, TRUE); + if (ci < dropinfo->num_components) { +#if DROP_REQUEST_FROM_SRC + src_buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, drop_coef_arrays[ci], blk_y, +#else + src_buffer = (*dropinfo->mem->access_virt_barray) + ((j_common_ptr) dropinfo, drop_coef_arrays[ci], blk_y, +#endif + (JDIMENSION) compptr->v_samp_factor, FALSE); + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + jcopy_block_row(src_buffer[offset_y], + dst_buffer[offset_y] + x_drop_blocks, + comp_width); + } + } else { + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + FMEMZERO(dst_buffer[offset_y] + x_drop_blocks, + comp_width * SIZEOF(JBLOCK)); + } + } + } + } +} + + LOCAL(void) do_crop (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, JDIMENSION x_crop_offset, JDIMENSION y_crop_offset, @@ -114,10 +384,10 @@ do_crop (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, LOCAL(void) -do_crop_ext (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, - JDIMENSION x_crop_offset, JDIMENSION y_crop_offset, - jvirt_barray_ptr *src_coef_arrays, - jvirt_barray_ptr *dst_coef_arrays) +do_crop_ext_zero (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, + JDIMENSION x_crop_offset, JDIMENSION y_crop_offset, + jvirt_barray_ptr *src_coef_arrays, + jvirt_barray_ptr *dst_coef_arrays) /* Crop. This is only used when no rotate/flip is requested with the crop. * Extension: If the destination size is larger than the source, we fill in * the extra area with zero (neutral gray). Note we also have to zero partial @@ -148,7 +418,7 @@ do_crop_ext (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, (JDIMENSION) compptr->v_samp_factor, TRUE); if (dstinfo->jpeg_height > srcinfo->output_height) { if (dst_blk_y < y_crop_blocks || - dst_blk_y >= comp_height + y_crop_blocks) { + dst_blk_y >= y_crop_blocks + comp_height) { for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { FMEMZERO(dst_buffer[offset_y], compptr->width_in_blocks * SIZEOF(JBLOCK)); @@ -174,11 +444,11 @@ do_crop_ext (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, jcopy_block_row(src_buffer[offset_y], dst_buffer[offset_y] + x_crop_blocks, comp_width); - if (compptr->width_in_blocks > comp_width + x_crop_blocks) { + if (compptr->width_in_blocks > x_crop_blocks + comp_width) { FMEMZERO(dst_buffer[offset_y] + - comp_width + x_crop_blocks, + x_crop_blocks + comp_width, (compptr->width_in_blocks - - comp_width - x_crop_blocks) * SIZEOF(JBLOCK)); + x_crop_blocks - comp_width) * SIZEOF(JBLOCK)); } } else { jcopy_block_row(src_buffer[offset_y] + x_crop_blocks, @@ -191,6 +461,190 @@ do_crop_ext (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, } +LOCAL(void) +do_crop_ext_flat (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, + JDIMENSION x_crop_offset, JDIMENSION y_crop_offset, + jvirt_barray_ptr *src_coef_arrays, + jvirt_barray_ptr *dst_coef_arrays) +/* Crop. This is only used when no rotate/flip is requested with the crop. + * Extension: The destination width is larger than the source and we fill in + * the extra area with the DC of the adjacent block. Note we also have to + * fill partial iMCUs at the right and bottom edge of the source image area + * in this case. + */ +{ + JDIMENSION MCU_cols, MCU_rows, comp_width, comp_height; + JDIMENSION dst_blk_x, dst_blk_y, x_crop_blocks, y_crop_blocks; + int ci, offset_y; + JCOEF dc; + JBLOCKARRAY src_buffer, dst_buffer; + jpeg_component_info *compptr; + + MCU_cols = srcinfo->output_width / + (dstinfo->max_h_samp_factor * dstinfo->min_DCT_h_scaled_size); + MCU_rows = srcinfo->output_height / + (dstinfo->max_v_samp_factor * dstinfo->min_DCT_v_scaled_size); + + for (ci = 0; ci < dstinfo->num_components; ci++) { + compptr = dstinfo->comp_info + ci; + comp_width = MCU_cols * compptr->h_samp_factor; + comp_height = MCU_rows * compptr->v_samp_factor; + x_crop_blocks = x_crop_offset * compptr->h_samp_factor; + y_crop_blocks = y_crop_offset * compptr->v_samp_factor; + for (dst_blk_y = 0; dst_blk_y < compptr->height_in_blocks; + dst_blk_y += compptr->v_samp_factor) { + dst_buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, dst_coef_arrays[ci], dst_blk_y, + (JDIMENSION) compptr->v_samp_factor, TRUE); + if (dstinfo->jpeg_height > srcinfo->output_height) { + if (dst_blk_y < y_crop_blocks || + dst_blk_y >= y_crop_blocks + comp_height) { + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + FMEMZERO(dst_buffer[offset_y], + compptr->width_in_blocks * SIZEOF(JBLOCK)); + } + continue; + } + src_buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, src_coef_arrays[ci], + dst_blk_y - y_crop_blocks, + (JDIMENSION) compptr->v_samp_factor, FALSE); + } else { + src_buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, src_coef_arrays[ci], + dst_blk_y + y_crop_blocks, + (JDIMENSION) compptr->v_samp_factor, FALSE); + } + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + if (x_crop_blocks > 0) { + FMEMZERO(dst_buffer[offset_y], + x_crop_blocks * SIZEOF(JBLOCK)); + dc = src_buffer[offset_y][0][0]; + for (dst_blk_x = 0; dst_blk_x < x_crop_blocks; dst_blk_x++) { + dst_buffer[offset_y][dst_blk_x][0] = dc; + } + } + jcopy_block_row(src_buffer[offset_y], + dst_buffer[offset_y] + x_crop_blocks, + comp_width); + if (compptr->width_in_blocks > x_crop_blocks + comp_width) { + FMEMZERO(dst_buffer[offset_y] + + x_crop_blocks + comp_width, + (compptr->width_in_blocks - + x_crop_blocks - comp_width) * SIZEOF(JBLOCK)); + dc = src_buffer[offset_y][comp_width - 1][0]; + for (dst_blk_x = x_crop_blocks + comp_width; + dst_blk_x < compptr->width_in_blocks; dst_blk_x++) { + dst_buffer[offset_y][dst_blk_x][0] = dc; + } + } + } + } + } +} + + +LOCAL(void) +do_crop_ext_reflect (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, + JDIMENSION x_crop_offset, JDIMENSION y_crop_offset, + jvirt_barray_ptr *src_coef_arrays, + jvirt_barray_ptr *dst_coef_arrays) +/* Crop. This is only used when no rotate/flip is requested with the crop. + * Extension: The destination width is larger than the source and we fill in + * the extra area with repeated reflections of the source region. Note we + * also have to fill partial iMCUs at the right and bottom edge of the source + * image area in this case. + */ +{ + JDIMENSION MCU_cols, MCU_rows, comp_width, comp_height, src_blk_x; + JDIMENSION dst_blk_x, dst_blk_y, x_crop_blocks, y_crop_blocks; + int ci, k, offset_y; + JBLOCKARRAY src_buffer, dst_buffer; + JBLOCKROW src_row_ptr, dst_row_ptr; + JCOEFPTR src_ptr, dst_ptr; + jpeg_component_info *compptr; + + MCU_cols = srcinfo->output_width / + (dstinfo->max_h_samp_factor * dstinfo->min_DCT_h_scaled_size); + MCU_rows = srcinfo->output_height / + (dstinfo->max_v_samp_factor * dstinfo->min_DCT_v_scaled_size); + + for (ci = 0; ci < dstinfo->num_components; ci++) { + compptr = dstinfo->comp_info + ci; + comp_width = MCU_cols * compptr->h_samp_factor; + comp_height = MCU_rows * compptr->v_samp_factor; + x_crop_blocks = x_crop_offset * compptr->h_samp_factor; + y_crop_blocks = y_crop_offset * compptr->v_samp_factor; + for (dst_blk_y = 0; dst_blk_y < compptr->height_in_blocks; + dst_blk_y += compptr->v_samp_factor) { + dst_buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, dst_coef_arrays[ci], dst_blk_y, + (JDIMENSION) compptr->v_samp_factor, TRUE); + if (dstinfo->jpeg_height > srcinfo->output_height) { + if (dst_blk_y < y_crop_blocks || + dst_blk_y >= y_crop_blocks + comp_height) { + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + FMEMZERO(dst_buffer[offset_y], + compptr->width_in_blocks * SIZEOF(JBLOCK)); + } + continue; + } + src_buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, src_coef_arrays[ci], + dst_blk_y - y_crop_blocks, + (JDIMENSION) compptr->v_samp_factor, FALSE); + } else { + src_buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, src_coef_arrays[ci], + dst_blk_y + y_crop_blocks, + (JDIMENSION) compptr->v_samp_factor, FALSE); + } + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + /* Copy source region */ + jcopy_block_row(src_buffer[offset_y], + dst_buffer[offset_y] + x_crop_blocks, + comp_width); + if (x_crop_blocks > 0) { + /* Reflect to left */ + dst_row_ptr = dst_buffer[offset_y] + x_crop_blocks; + for (dst_blk_x = x_crop_blocks; dst_blk_x > 0;) { + src_row_ptr = dst_row_ptr; /* (re)set axis of reflection */ + for (src_blk_x = comp_width; src_blk_x > 0 && dst_blk_x > 0; + src_blk_x--, dst_blk_x--) { + dst_ptr = *--dst_row_ptr; /* destination goes left */ + src_ptr = *src_row_ptr++; /* source goes right */ + /* this unrolled loop doesn't need to know which row it's on... */ + for (k = 0; k < DCTSIZE2; k += 2) { + *dst_ptr++ = *src_ptr++; /* copy even column */ + *dst_ptr++ = - *src_ptr++; /* copy odd column with sign change */ + } + } + } + } + if (compptr->width_in_blocks > x_crop_blocks + comp_width) { + /* Reflect to right */ + dst_row_ptr = dst_buffer[offset_y] + x_crop_blocks + comp_width; + for (dst_blk_x = compptr->width_in_blocks - x_crop_blocks - comp_width; + dst_blk_x > 0;) { + src_row_ptr = dst_row_ptr; /* (re)set axis of reflection */ + for (src_blk_x = comp_width; src_blk_x > 0 && dst_blk_x > 0; + src_blk_x--, dst_blk_x--) { + dst_ptr = *dst_row_ptr++; /* destination goes right */ + src_ptr = *--src_row_ptr; /* source goes left */ + /* this unrolled loop doesn't need to know which row it's on... */ + for (k = 0; k < DCTSIZE2; k += 2) { + *dst_ptr++ = *src_ptr++; /* copy even column */ + *dst_ptr++ = - *src_ptr++; /* copy odd column with sign change */ + } + } + } + } + } + } + } +} + + LOCAL(void) do_wipe (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, JDIMENSION x_crop_offset, JDIMENSION y_crop_offset, @@ -274,6 +728,78 @@ do_flatten (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, } +LOCAL(void) +do_reflect (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, + JDIMENSION x_crop_offset, + jvirt_barray_ptr *src_coef_arrays, + JDIMENSION drop_width, JDIMENSION drop_height) +/* Reflect - drop content of specified area, similar to wipe, but + * fill with repeated reflections of the outside area, instead of zero. + * NB: y_crop_offset is assumed to be zero. + */ +{ + JDIMENSION x_wipe_blocks, wipe_width; + JDIMENSION y_wipe_blocks, wipe_bottom; + JDIMENSION src_blk_x, dst_blk_x; + int ci, k, offset_y; + JBLOCKARRAY buffer; + JBLOCKROW src_row_ptr, dst_row_ptr; + JCOEFPTR src_ptr, dst_ptr; + jpeg_component_info *compptr; + + for (ci = 0; ci < dstinfo->num_components; ci++) { + compptr = dstinfo->comp_info + ci; + x_wipe_blocks = x_crop_offset * compptr->h_samp_factor; + wipe_width = drop_width * compptr->h_samp_factor; + wipe_bottom = drop_height * compptr->v_samp_factor; + for (y_wipe_blocks = 0; y_wipe_blocks < wipe_bottom; + y_wipe_blocks += compptr->v_samp_factor) { + buffer = (*srcinfo->mem->access_virt_barray) + ((j_common_ptr) srcinfo, src_coef_arrays[ci], y_wipe_blocks, + (JDIMENSION) compptr->v_samp_factor, TRUE); + for (offset_y = 0; offset_y < compptr->v_samp_factor; offset_y++) { + if (x_wipe_blocks > 0) { + /* Reflect from left */ + dst_row_ptr = buffer[offset_y] + x_wipe_blocks; + for (dst_blk_x = wipe_width; dst_blk_x > 0;) { + src_row_ptr = dst_row_ptr; /* (re)set axis of reflection */ + for (src_blk_x = x_wipe_blocks; + src_blk_x > 0 && dst_blk_x > 0; src_blk_x--, dst_blk_x--) { + dst_ptr = *dst_row_ptr++; /* destination goes right */ + src_ptr = *--src_row_ptr; /* source goes left */ + /* this unrolled loop doesn't need to know which row it's on... */ + for (k = 0; k < DCTSIZE2; k += 2) { + *dst_ptr++ = *src_ptr++; /* copy even column */ + *dst_ptr++ = - *src_ptr++; /* copy odd column with sign change */ + } + } + } + } else if (compptr->width_in_blocks > x_wipe_blocks + wipe_width) { + /* Reflect from right */ + dst_row_ptr = buffer[offset_y] + x_wipe_blocks + wipe_width; + for (dst_blk_x = wipe_width; dst_blk_x > 0;) { + src_row_ptr = dst_row_ptr; /* (re)set axis of reflection */ + src_blk_x = compptr->width_in_blocks - x_wipe_blocks - wipe_width; + for (; src_blk_x > 0 && dst_blk_x > 0; src_blk_x--, dst_blk_x--) { + dst_ptr = *--dst_row_ptr; /* destination goes left */ + src_ptr = *src_row_ptr++; /* source goes right */ + /* this unrolled loop doesn't need to know which row it's on... */ + for (k = 0; k < DCTSIZE2; k += 2) { + *dst_ptr++ = *src_ptr++; /* copy even column */ + *dst_ptr++ = - *src_ptr++; /* copy odd column with sign change */ + } + } + } + } else { + FMEMZERO(buffer[offset_y] + x_wipe_blocks, + wipe_width * SIZEOF(JBLOCK)); + } + } + } + } +} + + LOCAL(void) do_flip_h_no_crop (j_decompress_ptr srcinfo, j_compress_ptr dstinfo, JDIMENSION x_crop_offset, @@ -932,7 +1458,7 @@ jt_read_integer (const char ** strptr, JDIMENSION * result) * The routine returns TRUE if the spec string is valid, FALSE if not. * * The crop spec string should have the format - * [f]x[f]{+-}{+-} + * [{fr}]x[{fr}]{+-}{+-} * where width, height, xoffset, and yoffset are unsigned integers. * Each of the elements can be omitted to indicate a default value. * (A weakness of this style is that it is not possible to omit xoffset @@ -957,6 +1483,9 @@ jtransform_parse_crop_spec (jpeg_transform_info *info, const char *spec) if (*spec == 'f' || *spec == 'F') { spec++; info->crop_width_set = JCROP_FORCE; + } else if (*spec == 'r' || *spec == 'R') { + spec++; + info->crop_width_set = JCROP_REFLECT; } else info->crop_width_set = JCROP_POS; } @@ -968,6 +1497,9 @@ jtransform_parse_crop_spec (jpeg_transform_info *info, const char *spec) if (*spec == 'f' || *spec == 'F') { spec++; info->crop_height_set = JCROP_FORCE; + } else if (*spec == 'r' || *spec == 'R') { + spec++; + info->crop_height_set = JCROP_REFLECT; } else info->crop_height_set = JCROP_POS; } @@ -1042,10 +1574,10 @@ jtransform_request_workspace (j_decompress_ptr srcinfo, jvirt_barray_ptr *coef_arrays; boolean need_workspace, transpose_it; jpeg_component_info *compptr; - JDIMENSION xoffset, yoffset; + JDIMENSION xoffset, yoffset, dtemp; JDIMENSION width_in_iMCUs, height_in_iMCUs; JDIMENSION width_in_blocks, height_in_blocks; - int ci, h_samp_factor, v_samp_factor; + int itemp, ci, h_samp_factor, v_samp_factor; /* Determine number of components in output image */ if (info->force_grayscale && @@ -1115,7 +1647,6 @@ jtransform_request_workspace (j_decompress_ptr srcinfo, info->iMCU_sample_height = srcinfo->max_v_samp_factor * srcinfo->min_DCT_v_scaled_size; } - break; } /* If cropping has been requested, compute the crop area's position and @@ -1179,7 +1710,54 @@ jtransform_request_workspace (j_decompress_ptr srcinfo, else yoffset = info->output_height - info->crop_height - info->crop_yoffset; /* Now adjust so that upper left corner falls at an iMCU boundary */ - if (info->transform == JXFORM_WIPE) { + switch (info->transform) { + case JXFORM_DROP: + /* Ensure the effective drop region will not exceed the requested */ + itemp = info->iMCU_sample_width; + dtemp = itemp - 1 - ((xoffset + itemp - 1) % itemp); + xoffset += dtemp; + if (info->crop_width <= dtemp) + info->drop_width = 0; + else if (xoffset + info->crop_width - dtemp == info->output_width) + /* Matching right edge: include partial iMCU */ + info->drop_width = (info->crop_width - dtemp + itemp - 1) / itemp; + else + info->drop_width = (info->crop_width - dtemp) / itemp; + itemp = info->iMCU_sample_height; + dtemp = itemp - 1 - ((yoffset + itemp - 1) % itemp); + yoffset += dtemp; + if (info->crop_height <= dtemp) + info->drop_height = 0; + else if (yoffset + info->crop_height - dtemp == info->output_height) + /* Matching bottom edge: include partial iMCU */ + info->drop_height = (info->crop_height - dtemp + itemp - 1) / itemp; + else + info->drop_height = (info->crop_height - dtemp) / itemp; + /* Check if sampling factors match for dropping */ + if (info->drop_width != 0 && info->drop_height != 0) + for (ci = 0; ci < info->num_components && + ci < info->drop_ptr->num_components; ci++) { + if (info->drop_ptr->comp_info[ci].h_samp_factor * + srcinfo->max_h_samp_factor != + srcinfo->comp_info[ci].h_samp_factor * + info->drop_ptr->max_h_samp_factor) + ERREXIT6(srcinfo, JERR_BAD_DROP_SAMPLING, ci, + info->drop_ptr->comp_info[ci].h_samp_factor, + info->drop_ptr->max_h_samp_factor, + srcinfo->comp_info[ci].h_samp_factor, + srcinfo->max_h_samp_factor, 'h'); + if (info->drop_ptr->comp_info[ci].v_samp_factor * + srcinfo->max_v_samp_factor != + srcinfo->comp_info[ci].v_samp_factor * + info->drop_ptr->max_v_samp_factor) + ERREXIT6(srcinfo, JERR_BAD_DROP_SAMPLING, ci, + info->drop_ptr->comp_info[ci].v_samp_factor, + info->drop_ptr->max_v_samp_factor, + srcinfo->comp_info[ci].v_samp_factor, + srcinfo->max_v_samp_factor, 'v'); + } + break; + case JXFORM_WIPE: /* Ensure the effective wipe region will cover the requested */ info->drop_width = (JDIMENSION) jdiv_round_up ((long) (info->crop_width + (xoffset % info->iMCU_sample_width)), @@ -1187,7 +1765,8 @@ jtransform_request_workspace (j_decompress_ptr srcinfo, info->drop_height = (JDIMENSION) jdiv_round_up ((long) (info->crop_height + (yoffset % info->iMCU_sample_height)), (long) info->iMCU_sample_height); - } else { + break; + default: /* Ensure the effective crop region will cover the requested */ if (info->crop_width_set == JCROP_FORCE || info->crop_width > info->output_width) @@ -1275,6 +1854,11 @@ jtransform_request_workspace (j_decompress_ptr srcinfo, break; case JXFORM_WIPE: break; + case JXFORM_DROP: +#if DROP_REQUEST_FROM_SRC + drop_request_from_src(info->drop_ptr, srcinfo); +#endif + break; } /* Allocate workspace if needed. @@ -1282,15 +1866,13 @@ jtransform_request_workspace (j_decompress_ptr srcinfo, * so that transform routines need not worry about missing edge blocks. */ if (need_workspace) { - coef_arrays = (jvirt_barray_ptr *) - (*srcinfo->mem->alloc_small) ((j_common_ptr) srcinfo, JPOOL_IMAGE, - SIZEOF(jvirt_barray_ptr) * info->num_components); - width_in_iMCUs = (JDIMENSION) - jdiv_round_up((long) info->output_width, - (long) info->iMCU_sample_width); - height_in_iMCUs = (JDIMENSION) - jdiv_round_up((long) info->output_height, - (long) info->iMCU_sample_height); + coef_arrays = (jvirt_barray_ptr *) (*srcinfo->mem->alloc_small) + ((j_common_ptr) srcinfo, JPOOL_IMAGE, + SIZEOF(jvirt_barray_ptr) * info->num_components); + width_in_iMCUs = (JDIMENSION) jdiv_round_up + ((long) info->output_width, (long) info->iMCU_sample_width); + height_in_iMCUs = (JDIMENSION) jdiv_round_up + ((long) info->output_height, (long) info->iMCU_sample_height); for (ci = 0; ci < info->num_components; ci++) { compptr = srcinfo->comp_info + ci; if (info->num_components == 1) { @@ -1574,7 +2156,7 @@ jtransform_adjust_parameters (j_decompress_ptr srcinfo, dstinfo->jpeg_width = info->output_width; dstinfo->jpeg_height = info->output_height; - /* Transpose destination image parameters */ + /* Transpose destination image parameters, adjust quantization */ switch (info->transform) { case JXFORM_TRANSPOSE: case JXFORM_TRANSVERSE: @@ -1582,6 +2164,12 @@ jtransform_adjust_parameters (j_decompress_ptr srcinfo, case JXFORM_ROT_270: transpose_critical_parameters(dstinfo); break; + case JXFORM_DROP: + if (info->drop_width != 0 && info->drop_height != 0) + adjust_quant(srcinfo, src_coef_arrays, + info->drop_ptr, info->drop_coef_arrays, + info->trim, dstinfo); + break; default: break; } @@ -1637,10 +2225,22 @@ jtransform_execute_transform (j_decompress_ptr srcinfo, switch (info->transform) { case JXFORM_NONE: if (info->output_width > srcinfo->output_width || - info->output_height > srcinfo->output_height) - do_crop_ext(srcinfo, dstinfo, info->x_crop_offset, info->y_crop_offset, - src_coef_arrays, dst_coef_arrays); - else if (info->x_crop_offset != 0 || info->y_crop_offset != 0) + info->output_height > srcinfo->output_height) { + if (info->output_width > srcinfo->output_width && + info->crop_width_set == JCROP_REFLECT) + do_crop_ext_reflect(srcinfo, dstinfo, + info->x_crop_offset, info->y_crop_offset, + src_coef_arrays, dst_coef_arrays); + else if (info->output_width > srcinfo->output_width && + info->crop_width_set == JCROP_FORCE) + do_crop_ext_flat(srcinfo, dstinfo, + info->x_crop_offset, info->y_crop_offset, + src_coef_arrays, dst_coef_arrays); + else + do_crop_ext_zero(srcinfo, dstinfo, + info->x_crop_offset, info->y_crop_offset, + src_coef_arrays, dst_coef_arrays); + } else if (info->x_crop_offset != 0 || info->y_crop_offset != 0) do_crop(srcinfo, dstinfo, info->x_crop_offset, info->y_crop_offset, src_coef_arrays, dst_coef_arrays); break; @@ -1677,12 +2277,28 @@ jtransform_execute_transform (j_decompress_ptr srcinfo, src_coef_arrays, dst_coef_arrays); break; case JXFORM_WIPE: - if (info->crop_width_set != JCROP_FORCE) - do_wipe(srcinfo, dstinfo, info->x_crop_offset, info->y_crop_offset, - src_coef_arrays, info->drop_width, info->drop_height); - else + if (info->crop_width_set == JCROP_REFLECT && + info->y_crop_offset == 0 && info->drop_height == + (JDIMENSION) jdiv_round_up + ((long) info->output_height, (long) info->iMCU_sample_height) && + (info->x_crop_offset == 0 || + info->x_crop_offset + info->drop_width == + (JDIMENSION) jdiv_round_up + ((long) info->output_width, (long) info->iMCU_sample_width))) + do_reflect(srcinfo, dstinfo, info->x_crop_offset, + src_coef_arrays, info->drop_width, info->drop_height); + else if (info->crop_width_set == JCROP_FORCE) do_flatten(srcinfo, dstinfo, info->x_crop_offset, info->y_crop_offset, src_coef_arrays, info->drop_width, info->drop_height); + else + do_wipe(srcinfo, dstinfo, info->x_crop_offset, info->y_crop_offset, + src_coef_arrays, info->drop_width, info->drop_height); + break; + case JXFORM_DROP: + if (info->drop_width != 0 && info->drop_height != 0) + do_drop(srcinfo, dstinfo, info->x_crop_offset, info->y_crop_offset, + src_coef_arrays, info->drop_ptr, info->drop_coef_arrays, + info->drop_width, info->drop_height); break; } } diff --git a/external/jpeg-9c/transupp.h b/external/jpeg-9d/transupp.h similarity index 90% rename from external/jpeg-9c/transupp.h rename to external/jpeg-9d/transupp.h index eee69314..a8ba16ad 100644 --- a/external/jpeg-9c/transupp.h +++ b/external/jpeg-9d/transupp.h @@ -1,7 +1,7 @@ /* * transupp.h * - * Copyright (C) 1997-2013, Thomas G. Lane, Guido Vollbeding. + * Copyright (C) 1997-2019, Thomas G. Lane, Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -61,6 +61,11 @@ * * A complementary lossless-wipe option is provided to discard (gray out) data * inside a given image region while losslessly preserving what is outside. + * Another option is lossless-drop, which replaces data at a given image + * position by another image. Both source images must have the same + * subsampling values. It is best if they also have the same quantization, + * otherwise quantization adaption occurs. The trim option can be used with + * the drop option to requantize the drop file to the source file. * * We also provide a lossless-resize option, which is kind of a lossless-crop * operation in the DCT coefficient block domain - it discards higher-order @@ -106,20 +111,22 @@ typedef enum { JXFORM_ROT_90, /* 90-degree clockwise rotation */ JXFORM_ROT_180, /* 180-degree rotation */ JXFORM_ROT_270, /* 270-degree clockwise (or 90 ccw) */ - JXFORM_WIPE /* wipe */ + JXFORM_WIPE, /* wipe */ + JXFORM_DROP /* drop */ } JXFORM_CODE; /* * Codes for crop parameters, which can individually be unspecified, * positive or negative for xoffset or yoffset, - * positive or forced for width or height. + * positive or force or reflect for width or height. */ typedef enum { - JCROP_UNSET, - JCROP_POS, - JCROP_NEG, - JCROP_FORCE + JCROP_UNSET, + JCROP_POS, + JCROP_NEG, + JCROP_FORCE, + JCROP_REFLECT } JCROP_CODE; /* @@ -134,20 +141,24 @@ typedef struct { boolean perfect; /* if TRUE, fail if partial MCUs are requested */ boolean trim; /* if TRUE, trim partial MCUs as needed */ boolean force_grayscale; /* if TRUE, convert color image to grayscale */ - boolean crop; /* if TRUE, crop or wipe source image */ + boolean crop; /* if TRUE, crop or wipe source image, or drop */ /* Crop parameters: application need not set these unless crop is TRUE. * These can be filled in by jtransform_parse_crop_spec(). */ JDIMENSION crop_width; /* Width of selected region */ - JCROP_CODE crop_width_set; /* (forced disables adjustment) */ + JCROP_CODE crop_width_set; /* (force disables adjustment) */ JDIMENSION crop_height; /* Height of selected region */ - JCROP_CODE crop_height_set; /* (forced disables adjustment) */ + JCROP_CODE crop_height_set; /* (force disables adjustment) */ JDIMENSION crop_xoffset; /* X offset of selected region */ JCROP_CODE crop_xoffset_set; /* (negative measures from right edge) */ JDIMENSION crop_yoffset; /* Y offset of selected region */ JCROP_CODE crop_yoffset_set; /* (negative measures from bottom edge) */ + /* Drop parameters: set by caller for drop request */ + j_decompress_ptr drop_ptr; + jvirt_barray_ptr * drop_coef_arrays; + /* Internal workspace: caller should not touch these */ int num_components; /* # of components in workspace */ jvirt_barray_ptr * workspace_coef_arrays; /* workspace for transformations */ diff --git a/external/jpeg-9c/usage.txt b/external/jpeg-9d/usage.txt similarity index 94% rename from external/jpeg-9c/usage.txt rename to external/jpeg-9d/usage.txt index d06e3fc2..b20484bb 100644 --- a/external/jpeg-9c/usage.txt +++ b/external/jpeg-9d/usage.txt @@ -47,7 +47,7 @@ or This syntax works on all systems, so it is useful for scripts. The currently supported image file formats are: PPM (PBMPLUS color format), -PGM (PBMPLUS grayscale format), BMP, Targa, and RLE (Utah Raster Toolkit +PGM (PBMPLUS grayscale format), BMP, GIF, Targa, and RLE (Utah Raster Toolkit format). (RLE is supported only if the URT library is available, which it isn't on most non-Unix systems.) cjpeg recognizes the input image format automatically, with the exception of some Targa-format files. You have to @@ -73,10 +73,10 @@ The basic command line switches for cjpeg are: -grayscale Create monochrome JPEG file from color input. Be sure to use this switch when compressing a grayscale - BMP file, because cjpeg isn't bright enough to notice - whether a BMP file uses only shades of gray. By - saying -grayscale, you'll get a smaller JPEG file that - takes less time to process. + BMP or GIF file, because cjpeg isn't bright enough to + notice whether a BMP or GIF file uses only shades of + gray. By saying -grayscale, you'll get a smaller + JPEG file that takes less time to process. -rgb Create RGB JPEG file. Using this switch suppresses the conversion from RGB @@ -317,10 +317,17 @@ The basic command line switches for djpeg are: is specified, or if the JPEG file is grayscale; otherwise, 24-bit full-color format is emitted. - -gif Select GIF output format. Since GIF does not support - more than 256 colors, -colors 256 is assumed (unless - you specify a smaller number of colors). If you - specify -fast, the default number of colors is 216. + -gif Select GIF output format (LZW compressed). + Since GIF does not support more than 256 colors, + -colors 256 is assumed (unless you specify a smaller + number of colors). If you specify -fast, the default + number of colors is 216. + + -gif0 Select GIF output format (uncompressed). + Since GIF does not support more than 256 colors, + -colors 256 is assumed (unless you specify a smaller + number of colors). If you specify -fast, the default + number of colors is 216. -os2 Select BMP output format (OS/2 1.x flavor). 8-bit colormapped format is emitted if -colors or -grayscale @@ -411,10 +418,6 @@ quality settings to make very small JPEG files; the percentage improvement is often a lot more than it is on larger files. (At present, -optimize mode is always selected when generating progressive JPEG files.) -GIF input files are no longer supported, to avoid the Unisys LZW patent -(now expired). -(Conversion of GIF files to JPEG is usually a bad idea anyway.) - HINTS FOR DJPEG @@ -440,10 +443,6 @@ it may run out of memory even with -maxmemory 0. In that case you can still decompress, with some loss of image quality, by specifying -onepass for one-pass quantization. -To avoid the Unisys LZW patent (now expired), djpeg produces uncompressed GIF -files. These are larger than they should be, but are readable by standard GIF -decoders. - HINTS FOR BOTH PROGRAMS @@ -571,13 +570,33 @@ The image can be losslessly cropped by giving the switch: -crop WxH+X+Y Crop to a rectangular subarea of width W, height H starting at point X,Y. +Crop extension: The width or height parameters can be made larger than the +source image. In this case the extra area is filled in with zero (neutral +gray). A larger width parameter has two more options: Attaching an 'f' +character ("flatten") to the width number will fill in the extra area with +the DC of the adjacent block, instead of gray out. Attaching an 'r' +character ("reflect") to the width number will fill in the extra area with +repeated reflections of the source region, instead of gray out. + A complementary lossless-wipe option is provided to discard (gray out) data inside a given image region while losslessly preserving what is outside: -wipe WxH+X+Y Wipe (gray out) a rectangular subarea of width W, height H starting at point X,Y. -Attaching an 'f' character ("flatten") to the width number will fill -the region with the average of adjacent blocks, instead of gray out. +Attaching an 'f' character ("flatten") to the width number will fill the +region with the average of adjacent blocks, instead of gray out. In case +the wipe region and outside area form two horizontally adjacent rectangles, +attaching an 'r' character ("reflect") to the width number will fill the +region with repeated reflections of the outside area, instead of gray out. + +Another option is lossless-drop, which replaces data at a given image +position by another image: + -drop +X+Y filename Drop another image + +Both source images must have the same subsampling values. It is best if +they also have the same quantization, otherwise quantization adaption occurs. +The trim option can be used with the drop option to requantize the drop file +to the source file. Other not-strictly-lossless transformation switches are: diff --git a/external/jpeg-9c/wizard.txt b/external/jpeg-9d/wizard.txt similarity index 100% rename from external/jpeg-9c/wizard.txt rename to external/jpeg-9d/wizard.txt diff --git a/external/jpeg-9c/wrbmp.c b/external/jpeg-9d/wrbmp.c similarity index 92% rename from external/jpeg-9c/wrbmp.c rename to external/jpeg-9d/wrbmp.c index 28148644..bed699ff 100644 --- a/external/jpeg-9c/wrbmp.c +++ b/external/jpeg-9d/wrbmp.c @@ -2,7 +2,7 @@ * wrbmp.c * * Copyright (C) 1994-1996, Thomas G. Lane. - * Modified 2017 by Guido Vollbeding. + * Modified 2017-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -74,22 +74,19 @@ put_pixel_rows (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, /* This version is for writing 24-bit pixels */ { bmp_dest_ptr dest = (bmp_dest_ptr) dinfo; - JSAMPARRAY image_ptr; register JSAMPROW inptr, outptr; register JDIMENSION col; int pad; /* Access next row in virtual array */ - image_ptr = (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, dest->whole_image, - dest->cur_output_row, (JDIMENSION) 1, TRUE); + outptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + dest->whole_image, dest->cur_output_row, (JDIMENSION) 1, TRUE); dest->cur_output_row++; /* Transfer data. Note destination values must be in BGR order * (even though Microsoft's own documents say the opposite). */ inptr = dest->pub.buffer[0]; - outptr = image_ptr[0]; for (col = cinfo->output_width; col > 0; col--) { outptr[2] = *inptr++; /* can omit GETJSAMPLE() safely */ outptr[1] = *inptr++; @@ -109,20 +106,17 @@ put_gray_rows (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, /* This version is for grayscale OR quantized color output */ { bmp_dest_ptr dest = (bmp_dest_ptr) dinfo; - JSAMPARRAY image_ptr; register JSAMPROW inptr, outptr; register JDIMENSION col; int pad; /* Access next row in virtual array */ - image_ptr = (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, dest->whole_image, - dest->cur_output_row, (JDIMENSION) 1, TRUE); + outptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + dest->whole_image, dest->cur_output_row, (JDIMENSION) 1, TRUE); dest->cur_output_row++; /* Transfer data. */ inptr = dest->pub.buffer[0]; - outptr = image_ptr[0]; for (col = cinfo->output_width; col > 0; col--) { *outptr++ = *inptr++; /* can omit GETJSAMPLE() safely */ } @@ -160,10 +154,10 @@ write_bmp_header (j_decompress_ptr cinfo, bmp_dest_ptr dest) { char bmpfileheader[14]; char bmpinfoheader[40]; -#define PUT_2B(array,offset,value) \ +#define PUT_2B(array, offset, value) \ (array[offset] = (char) ((value) & 0xFF), \ array[offset+1] = (char) (((value) >> 8) & 0xFF)) -#define PUT_4B(array,offset,value) \ +#define PUT_4B(array, offset, value) \ (array[offset] = (char) ((value) & 0xFF), \ array[offset+1] = (char) (((value) >> 8) & 0xFF), \ array[offset+2] = (char) (((value) >> 16) & 0xFF), \ @@ -328,13 +322,13 @@ write_colormap (j_decompress_ptr cinfo, bmp_dest_ptr dest, putc(0, outfile); } } - /* Pad colormap with zeros to ensure specified number of colormap entries */ + /* Pad colormap to ensure specified number of colormap entries */ if (i > map_colors) ERREXIT1(cinfo, JERR_TOO_MANY_COLORS, i); for (; i < map_colors; i++) { - putc(0, outfile); - putc(0, outfile); - putc(0, outfile); + putc(CENTERJSAMPLE, outfile); + putc(CENTERJSAMPLE, outfile); + putc(CENTERJSAMPLE, outfile); if (map_entry_size == 4) putc(0, outfile); } @@ -346,7 +340,6 @@ finish_output_bmp (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) { bmp_dest_ptr dest = (bmp_dest_ptr) dinfo; register FILE * outfile = dest->pub.output_file; - JSAMPARRAY image_ptr; register JSAMPROW data_ptr; JDIMENSION row; register JDIMENSION col; @@ -365,9 +358,8 @@ finish_output_bmp (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) progress->pub.pass_limit = (long) cinfo->output_height; (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); } - image_ptr = (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, dest->whole_image, row-1, (JDIMENSION) 1, FALSE); - data_ptr = image_ptr[0]; + data_ptr = * (*cinfo->mem->access_virt_sarray) ((j_common_ptr) cinfo, + dest->whole_image, row - 1, (JDIMENSION) 1, FALSE); for (col = dest->row_width; col > 0; col--) { putc(GETJSAMPLE(*data_ptr), outfile); data_ptr++; @@ -394,21 +386,23 @@ jinit_write_bmp (j_decompress_ptr cinfo, boolean is_os2) JDIMENSION row_width; /* Create module interface object, fill in method pointers */ - dest = (bmp_dest_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(bmp_dest_struct)); + dest = (bmp_dest_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(bmp_dest_struct)); dest->pub.start_output = start_output_bmp; dest->pub.finish_output = finish_output_bmp; dest->is_os2 = is_os2; - if (cinfo->out_color_space == JCS_GRAYSCALE) { + switch (cinfo->out_color_space) { + case JCS_GRAYSCALE: dest->pub.put_pixel_rows = put_gray_rows; - } else if (cinfo->out_color_space == JCS_RGB) { + break; + case JCS_RGB: if (cinfo->quantize_colors) dest->pub.put_pixel_rows = put_gray_rows; else dest->pub.put_pixel_rows = put_pixel_rows; - } else { + break; + default: ERREXIT(cinfo, JERR_BMP_COLORSPACE); } diff --git a/external/jpeg-9c/wrgif.c b/external/jpeg-9d/wrgif.c similarity index 57% rename from external/jpeg-9c/wrgif.c rename to external/jpeg-9d/wrgif.c index 843a1036..9d472de1 100644 --- a/external/jpeg-9c/wrgif.c +++ b/external/jpeg-9d/wrgif.c @@ -1,19 +1,13 @@ /* * wrgif.c * - * Copyright (C) 1991-1997, Thomas G. Lane. - * Modified 2015-2017 by Guido Vollbeding. + * Copyright (C) 1991-1996, Thomas G. Lane. + * Modified 2015-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * * This file contains routines to write output images in GIF format. * - ************************************************************************** - * NOTE: to avoid entanglements with Unisys' patent on LZW compression, * - * this code has been modified to output "uncompressed GIF" files. * - * There is no trace of the LZW algorithm in this file. * - ************************************************************************** - * * These routines may need modification for non-Unix environments or * specialized applications. As they stand, they assume output to * an ordinary stdio stream. @@ -31,11 +25,6 @@ * copyright notice and this permission notice appear in supporting * documentation. This software is provided "as is" without express or * implied warranty. - * - * We are also required to state that - * "The Graphics Interchange Format(c) is the Copyright property of - * CompuServe Incorporated. GIF(sm) is a Service Mark property of - * CompuServe Incorporated." */ #include "cdjpeg.h" /* Common decls for cjpeg/djpeg applications */ @@ -43,6 +32,40 @@ #ifdef GIF_SUPPORTED +#define MAX_LZW_BITS 12 /* maximum LZW code size (4096 symbols) */ + +typedef INT16 code_int; /* must hold -1 .. 2**MAX_LZW_BITS */ + +#define LZW_TABLE_SIZE ((code_int) 1 << MAX_LZW_BITS) + +#define HSIZE 5003 /* hash table size for 80% occupancy */ + +typedef int hash_int; /* must hold -2*HSIZE..2*HSIZE */ + +#define MAXCODE(n_bits) (((code_int) 1 << (n_bits)) - 1) + + +/* + * The LZW hash table consists of two parallel arrays: + * hash_code[i] code of symbol in slot i, or 0 if empty slot + * hash_value[i] symbol's value; undefined if empty slot + * where slot values (i) range from 0 to HSIZE-1. The symbol value is + * its prefix symbol's code concatenated with its suffix character. + * + * Algorithm: use open addressing double hashing (no chaining) on the + * prefix code / suffix character combination. We do a variant of Knuth's + * algorithm D (vol. 3, sec. 6.4) along with G. Knott's relatively-prime + * secondary probe. + * + * The hash_value[] table is allocated from FAR heap space since it would + * use up rather a lot of the near data space in a PC. + */ + +typedef INT32 hash_entry; /* must hold (code_int<<8) | byte */ + +#define HASH_ENTRY(prefix, suffix) ((((hash_entry) (prefix)) << 8) | (suffix)) + + /* Private version of data destination object */ typedef struct { @@ -52,14 +75,24 @@ typedef struct { /* State for packing variable-width codes into a bitstream */ int n_bits; /* current number of bits/code */ - int maxcode; /* maximum code, given n_bits */ + code_int maxcode; /* maximum code, given n_bits */ + int init_bits; /* initial n_bits ... restored after clear */ INT32 cur_accum; /* holds bits not yet output */ int cur_bits; /* # of bits in cur_accum */ + /* LZW string construction */ + code_int waiting_code; /* symbol not yet output; may be extendable */ + boolean first_byte; /* if TRUE, waiting_code is not valid */ + /* State for GIF code assignment */ - int ClearCode; /* clear code (doesn't change) */ - int EOFCode; /* EOF code (ditto) */ - int code_counter; /* counts output symbols */ + code_int ClearCode; /* clear code (doesn't change) */ + code_int EOFCode; /* EOF code (ditto) */ + code_int free_code; /* LZW: first not-yet-used symbol code */ + code_int code_counter; /* not LZW: counts output symbols */ + + /* LZW hash table */ + code_int *hash_code; /* => hash table of symbol codes */ + hash_entry FAR *hash_value; /* => hash table of symbol values */ /* GIF data packet construction buffer */ int bytesinpkt; /* # of bytes in current packet */ @@ -69,9 +102,6 @@ typedef struct { typedef gif_dest_struct * gif_dest_ptr; -/* Largest value that will fit in N bits */ -#define MAXCODE(n_bits) ((1 << (n_bits)) - 1) - /* * Routines to package finished data bytes into GIF data blocks. @@ -93,7 +123,7 @@ flush_packet (gif_dest_ptr dinfo) /* Add a character to current packet; flush to disk if necessary */ -#define CHAR_OUT(dinfo,c) \ +#define CHAR_OUT(dinfo, c) \ { (dinfo)->packetbuf[++(dinfo)->bytesinpkt] = (char) (c); \ if ((dinfo)->bytesinpkt >= 255) \ flush_packet(dinfo); \ @@ -103,7 +133,7 @@ flush_packet (gif_dest_ptr dinfo) /* Routine to convert variable-width codes into a byte stream */ LOCAL(void) -output (gif_dest_ptr dinfo, int code) +output (gif_dest_ptr dinfo, code_int code) /* Emit a code of n_bits bits */ /* Uses cur_accum and cur_bits to reblock into 8-bit bytes */ { @@ -115,74 +145,76 @@ output (gif_dest_ptr dinfo, int code) dinfo->cur_accum >>= 8; dinfo->cur_bits -= 8; } + + /* + * If the next entry is going to be too big for the code size, + * then increase it, if possible. We do this here to ensure + * that it's done in sync with the decoder's codesize increases. + */ + if (dinfo->free_code > dinfo->maxcode) { + dinfo->n_bits++; + if (dinfo->n_bits == MAX_LZW_BITS) + dinfo->maxcode = LZW_TABLE_SIZE; /* free_code will never exceed this */ + else + dinfo->maxcode = MAXCODE(dinfo->n_bits); + } } -/* The pseudo-compression algorithm. - * - * In this module we simply output each pixel value as a separate symbol; - * thus, no compression occurs. In fact, there is expansion of one bit per - * pixel, because we use a symbol width one bit wider than the pixel width. - * - * GIF ordinarily uses variable-width symbols, and the decoder will expect - * to ratchet up the symbol width after a fixed number of symbols. - * To simplify the logic and keep the expansion penalty down, we emit a - * GIF Clear code to reset the decoder just before the width would ratchet up. - * Thus, all the symbols in the output file will have the same bit width. - * Note that emitting the Clear codes at the right times is a mere matter of - * counting output symbols and is in no way dependent on the LZW patent. - * - * With a small basic pixel width (low color count), Clear codes will be - * needed very frequently, causing the file to expand even more. So this - * simplistic approach wouldn't work too well on bilevel images, for example. - * But for output of JPEG conversions the pixel width will usually be 8 bits - * (129 to 256 colors), so the overhead added by Clear symbols is only about - * one symbol in every 256. - */ +/* Compression initialization & termination */ + + +LOCAL(void) +clear_hash (gif_dest_ptr dinfo) +/* Fill the hash table with empty entries */ +{ + /* It's sufficient to zero hash_code[] */ + MEMZERO(dinfo->hash_code, HSIZE * SIZEOF(code_int)); +} + + +LOCAL(void) +clear_block (gif_dest_ptr dinfo) +/* Reset compressor and issue a Clear code */ +{ + clear_hash(dinfo); /* delete all the symbols */ + dinfo->free_code = dinfo->ClearCode + 2; + output(dinfo, dinfo->ClearCode); /* inform decoder */ + dinfo->n_bits = dinfo->init_bits; /* reset code size */ + dinfo->maxcode = MAXCODE(dinfo->n_bits); +} + LOCAL(void) compress_init (gif_dest_ptr dinfo, int i_bits) -/* Initialize pseudo-compressor */ +/* Initialize compressor */ { /* init all the state variables */ - dinfo->n_bits = i_bits; + dinfo->n_bits = dinfo->init_bits = i_bits; dinfo->maxcode = MAXCODE(dinfo->n_bits); - dinfo->ClearCode = (1 << (i_bits - 1)); + dinfo->ClearCode = ((code_int) 1 << (i_bits - 1)); dinfo->EOFCode = dinfo->ClearCode + 1; - dinfo->code_counter = dinfo->ClearCode + 2; + dinfo->code_counter = dinfo->free_code = dinfo->ClearCode + 2; + dinfo->first_byte = TRUE; /* no waiting symbol yet */ /* init output buffering vars */ dinfo->bytesinpkt = 0; dinfo->cur_accum = 0; dinfo->cur_bits = 0; + /* clear hash table */ + if (dinfo->hash_code != NULL) + clear_hash(dinfo); /* GIF specifies an initial Clear code */ output(dinfo, dinfo->ClearCode); } -LOCAL(void) -compress_pixel (gif_dest_ptr dinfo, int c) -/* Accept and "compress" one pixel value. - * The given value must be less than n_bits wide. - */ -{ - /* Output the given pixel value as a symbol. */ - output(dinfo, c); - /* Issue Clear codes often enough to keep the reader from ratcheting up - * its symbol size. - */ - if (dinfo->code_counter < dinfo->maxcode) { - dinfo->code_counter++; - } else { - output(dinfo, dinfo->ClearCode); - dinfo->code_counter = dinfo->ClearCode + 2; /* reset the counter */ - } -} - - LOCAL(void) compress_term (gif_dest_ptr dinfo) /* Clean up at end */ { + /* Flush out the buffered LZW code */ + if (! dinfo->first_byte) + output(dinfo, dinfo->waiting_code); /* Send an EOF code */ output(dinfo, dinfo->EOFCode); /* Flush the bit-packing buffer */ @@ -219,7 +251,7 @@ put_3bytes (gif_dest_ptr dinfo, int val) LOCAL(void) emit_header (gif_dest_ptr dinfo, int num_colors, JSAMPARRAY colormap) /* Output the GIF file header, including color map */ -/* If colormap==NULL, synthesize a grayscale colormap */ +/* If colormap == NULL, synthesize a grayscale colormap */ { int BitsPerPixel, ColorMapSize, InitCodeSize, FlagByte; int cshift = dinfo->cinfo->data_precision - 8; @@ -250,15 +282,15 @@ emit_header (gif_dest_ptr dinfo, int num_colors, JSAMPARRAY colormap) put_word(dinfo, (unsigned int) dinfo->cinfo->output_width); put_word(dinfo, (unsigned int) dinfo->cinfo->output_height); FlagByte = 0x80; /* Yes, there is a global color table */ - FlagByte |= (BitsPerPixel-1) << 4; /* color resolution */ - FlagByte |= (BitsPerPixel-1); /* size of global color table */ + FlagByte |= (BitsPerPixel - 1) << 4; /* color resolution */ + FlagByte |= (BitsPerPixel - 1); /* size of global color table */ putc(FlagByte, dinfo->pub.output_file); putc(0, dinfo->pub.output_file); /* Background color index */ putc(0, dinfo->pub.output_file); /* Reserved (aspect ratio in GIF89) */ /* Write the Global Color Map */ /* If the color map is more than 8 bits precision, */ /* we reduce it to 8 bits by shifting */ - for (i=0; i < ColorMapSize; i++) { + for (i = 0; i < ColorMapSize; i++) { if (i < num_colors) { if (colormap != NULL) { if (dinfo->cinfo->out_color_space == JCS_RGB) { @@ -272,11 +304,11 @@ emit_header (gif_dest_ptr dinfo, int num_colors, JSAMPARRAY colormap) } } else { /* Create a grayscale map of num_colors values, range 0..255 */ - put_3bytes(dinfo, (i * 255 + (num_colors-1)/2) / (num_colors-1)); + put_3bytes(dinfo, (i * 255 + (num_colors - 1) / 2) / (num_colors - 1)); } } else { /* fill out the map to a power of 2 */ - put_3bytes(dinfo, 0); + put_3bytes(dinfo, CENTERJSAMPLE >> cshift); } } /* Write image separator and Image Descriptor */ @@ -290,8 +322,8 @@ emit_header (gif_dest_ptr dinfo, int num_colors, JSAMPARRAY colormap) /* Write Initial Code Size byte */ putc(InitCodeSize, dinfo->pub.output_file); - /* Initialize for "compression" of image data */ - compress_init(dinfo, InitCodeSize+1); + /* Initialize for compression of image data */ + compress_init(dinfo, InitCodeSize + 1); } @@ -316,17 +348,139 @@ start_output_gif (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) * In this module rows_supplied will always be 1. */ + +/* + * The LZW algorithm proper + */ + +METHODDEF(void) +put_LZW_pixel_rows (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, + JDIMENSION rows_supplied) +{ + gif_dest_ptr dest = (gif_dest_ptr) dinfo; + register JSAMPROW ptr; + register JDIMENSION col; + code_int c; + register hash_int i; + register hash_int disp; + register hash_entry probe_value; + + ptr = dest->pub.buffer[0]; + for (col = cinfo->output_width; col > 0; col--) { + /* Accept and compress one 8-bit byte */ + c = (code_int) GETJSAMPLE(*ptr++); + + if (dest->first_byte) { /* need to initialize waiting_code */ + dest->waiting_code = c; + dest->first_byte = FALSE; + continue; + } + + /* Probe hash table to see if a symbol exists for + * waiting_code followed by c. + * If so, replace waiting_code by that symbol and continue. + */ + i = ((hash_int) c << (MAX_LZW_BITS-8)) + dest->waiting_code; + /* i is less than twice 2**MAX_LZW_BITS, therefore less than twice HSIZE */ + if (i >= HSIZE) + i -= HSIZE; + + probe_value = HASH_ENTRY(dest->waiting_code, c); + + if (dest->hash_code[i] == 0) { + /* hit empty slot; desired symbol not in table */ + output(dest, dest->waiting_code); + if (dest->free_code < LZW_TABLE_SIZE) { + dest->hash_code[i] = dest->free_code++; /* add symbol to hashtable */ + dest->hash_value[i] = probe_value; + } else + clear_block(dest); + dest->waiting_code = c; + continue; + } + if (dest->hash_value[i] == probe_value) { + dest->waiting_code = dest->hash_code[i]; + continue; + } + + if (i == 0) /* secondary hash (after G. Knott) */ + disp = 1; + else + disp = HSIZE - i; + for (;;) { + i -= disp; + if (i < 0) + i += HSIZE; + if (dest->hash_code[i] == 0) { + /* hit empty slot; desired symbol not in table */ + output(dest, dest->waiting_code); + if (dest->free_code < LZW_TABLE_SIZE) { + dest->hash_code[i] = dest->free_code++; /* add symbol to hashtable */ + dest->hash_value[i] = probe_value; + } else + clear_block(dest); + dest->waiting_code = c; + break; + } + if (dest->hash_value[i] == probe_value) { + dest->waiting_code = dest->hash_code[i]; + break; + } + } + } +} + + +/* + * The pseudo-compression algorithm. + * + * In this version we simply output each pixel value as a separate symbol; + * thus, no compression occurs. In fact, there is expansion of one bit per + * pixel, because we use a symbol width one bit wider than the pixel width. + * + * GIF ordinarily uses variable-width symbols, and the decoder will expect + * to ratchet up the symbol width after a fixed number of symbols. + * To simplify the logic and keep the expansion penalty down, we emit a + * GIF Clear code to reset the decoder just before the width would ratchet up. + * Thus, all the symbols in the output file will have the same bit width. + * Note that emitting the Clear codes at the right times is a mere matter of + * counting output symbols and is in no way dependent on the LZW algorithm. + * + * With a small basic pixel width (low color count), Clear codes will be + * needed very frequently, causing the file to expand even more. So this + * simplistic approach wouldn't work too well on bilevel images, for example. + * But for output of JPEG conversions the pixel width will usually be 8 bits + * (129 to 256 colors), so the overhead added by Clear symbols is only about + * one symbol in every 256. + */ + METHODDEF(void) -put_pixel_rows (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, - JDIMENSION rows_supplied) +put_raw_pixel_rows (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, + JDIMENSION rows_supplied) { gif_dest_ptr dest = (gif_dest_ptr) dinfo; register JSAMPROW ptr; register JDIMENSION col; + code_int c; ptr = dest->pub.buffer[0]; for (col = cinfo->output_width; col > 0; col--) { - compress_pixel(dest, GETJSAMPLE(*ptr++)); + c = (code_int) GETJSAMPLE(*ptr++); + /* Accept and output one pixel value. + * The given value must be less than n_bits wide. + */ + + /* Output the given pixel value as a symbol. */ + output(dest, c); + /* Issue Clear codes often enough to keep the reader from ratcheting up + * its symbol size. + */ + if (dest->code_counter < dest->maxcode) { + dest->code_counter++; + } else { + output(dest, dest->ClearCode); + dest->code_counter = dest->ClearCode + 2; /* reset the counter */ + } } } @@ -340,7 +494,7 @@ finish_output_gif (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) { gif_dest_ptr dest = (gif_dest_ptr) dinfo; - /* Flush "compression" mechanism */ + /* Flush compression mechanism */ compress_term(dest); /* Write a zero-length data block to end the series */ putc(0, dest->pub.output_file); @@ -358,17 +512,15 @@ finish_output_gif (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) */ GLOBAL(djpeg_dest_ptr) -jinit_write_gif (j_decompress_ptr cinfo) +jinit_write_gif (j_decompress_ptr cinfo, boolean is_lzw) { gif_dest_ptr dest; /* Create module interface object, fill in method pointers */ - dest = (gif_dest_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(gif_dest_struct)); + dest = (gif_dest_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(gif_dest_struct)); dest->cinfo = cinfo; /* make back link for subroutines */ dest->pub.start_output = start_output_gif; - dest->pub.put_pixel_rows = put_pixel_rows; dest->pub.finish_output = finish_output_gif; if (cinfo->out_color_space != JCS_GRAYSCALE && @@ -394,6 +546,20 @@ jinit_write_gif (j_decompress_ptr cinfo) ((j_common_ptr) cinfo, JPOOL_IMAGE, cinfo->output_width, (JDIMENSION) 1); dest->pub.buffer_height = 1; + if (is_lzw) { + dest->pub.put_pixel_rows = put_LZW_pixel_rows; + /* Allocate space for hash table */ + dest->hash_code = (code_int *) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, HSIZE * SIZEOF(code_int)); + dest->hash_value = (hash_entry FAR *) (*cinfo->mem->alloc_large) + ((j_common_ptr) cinfo, JPOOL_IMAGE, HSIZE * SIZEOF(hash_entry)); + } else { + dest->pub.put_pixel_rows = put_raw_pixel_rows; + /* Mark tables unused */ + dest->hash_code = NULL; + dest->hash_value = NULL; + } + return &dest->pub; } diff --git a/external/jpeg-9c/wrjpgcom.1 b/external/jpeg-9d/wrjpgcom.1 similarity index 100% rename from external/jpeg-9c/wrjpgcom.1 rename to external/jpeg-9d/wrjpgcom.1 diff --git a/external/jpeg-9c/wrjpgcom.c b/external/jpeg-9d/wrjpgcom.c similarity index 100% rename from external/jpeg-9c/wrjpgcom.c rename to external/jpeg-9d/wrjpgcom.c diff --git a/external/jpeg-9c/wrppm.c b/external/jpeg-9d/wrppm.c similarity index 94% rename from external/jpeg-9c/wrppm.c rename to external/jpeg-9d/wrppm.c index e2f27cf2..eb8bdf40 100644 --- a/external/jpeg-9c/wrppm.c +++ b/external/jpeg-9d/wrppm.c @@ -2,7 +2,7 @@ * wrppm.c * * Copyright (C) 1991-1996, Thomas G. Lane. - * Modified 2009-2017 by Guido Vollbeding. + * Modified 2009-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -149,7 +149,6 @@ put_demapped_rgb (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, (void) JFWRITE(dest->pub.output_file, dest->iobuffer, dest->buffer_width); } - METHODDEF(void) put_demapped_gray (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, JDIMENSION rows_supplied) @@ -157,13 +156,13 @@ put_demapped_gray (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, ppm_dest_ptr dest = (ppm_dest_ptr) dinfo; register char * bufferptr; register JSAMPROW ptr; - register JSAMPROW color_map = cinfo->colormap[0]; + register JSAMPROW color_map0 = cinfo->colormap[0]; register JDIMENSION col; ptr = dest->pub.buffer[0]; bufferptr = dest->iobuffer; for (col = cinfo->output_width; col > 0; col--) { - PUTPPMSAMPLE(bufferptr, GETJSAMPLE(color_map[GETJSAMPLE(*ptr++)])); + PUTPPMSAMPLE(bufferptr, GETJSAMPLE(color_map0[GETJSAMPLE(*ptr++)])); } (void) JFWRITE(dest->pub.output_file, dest->iobuffer, dest->buffer_width); } @@ -176,19 +175,17 @@ put_demapped_gray (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, METHODDEF(void) start_output_ppm (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) { - ppm_dest_ptr dest = (ppm_dest_ptr) dinfo; - /* Emit file header */ switch (cinfo->out_color_space) { case JCS_GRAYSCALE: /* emit header for raw PGM format */ - fprintf(dest->pub.output_file, "P5\n%ld %ld\n%d\n", + fprintf(dinfo->output_file, "P5\n%ld %ld\n%d\n", (long) cinfo->output_width, (long) cinfo->output_height, PPM_MAXVAL); break; case JCS_RGB: /* emit header for raw PPM format */ - fprintf(dest->pub.output_file, "P6\n%ld %ld\n%d\n", + fprintf(dinfo->output_file, "P6\n%ld %ld\n%d\n", (long) cinfo->output_width, (long) cinfo->output_height, PPM_MAXVAL); break; @@ -222,9 +219,8 @@ jinit_write_ppm (j_decompress_ptr cinfo) ppm_dest_ptr dest; /* Create module interface object, fill in method pointers */ - dest = (ppm_dest_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(ppm_dest_struct)); + dest = (ppm_dest_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(ppm_dest_struct)); dest->pub.start_output = start_output_ppm; dest->pub.finish_output = finish_output_ppm; diff --git a/external/jpeg-9c/wrrle.c b/external/jpeg-9d/wrrle.c similarity index 86% rename from external/jpeg-9c/wrrle.c rename to external/jpeg-9d/wrrle.c index 403e2606..dc2fadb8 100644 --- a/external/jpeg-9c/wrrle.c +++ b/external/jpeg-9d/wrrle.c @@ -2,7 +2,7 @@ * wrrle.c * * Copyright (C) 1991-1996, Thomas G. Lane. - * Modified 2017 by Guido Vollbeding. + * Modified 2017-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -62,6 +62,7 @@ typedef struct { typedef rle_dest_struct * rle_dest_ptr; + /* Forward declarations */ METHODDEF(void) rle_put_pixel_rows JPP((j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, @@ -79,7 +80,7 @@ start_output_rle (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) { rle_dest_ptr dest = (rle_dest_ptr) dinfo; size_t cmapsize; - int i, ci; + int ci, i; #ifdef PROGRESS_REPORT cd_progress_ptr progress = (cd_progress_ptr) cinfo->progress; #endif @@ -123,8 +124,8 @@ start_output_rle (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) /* Shifting would need adjustment for JSAMPLEs wider than 8 bits. */ for (ci = 0; ci < cinfo->out_color_components; ci++) { for (i = 0; i < cinfo->actual_number_of_colors; i++) { - dest->colormap[ci * CMAPLENGTH + i] = - GETJSAMPLE(cinfo->colormap[ci][i]) << 8; + dest->colormap[ci * CMAPLENGTH + i] = + GETJSAMPLE(cinfo->colormap[ci][i]) << 8; } } } @@ -163,6 +164,7 @@ rle_put_pixel_rows (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, } } + /* * Finish up at the end of the file. * @@ -174,7 +176,7 @@ finish_output_rle (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) { rle_dest_ptr dest = (rle_dest_ptr) dinfo; rle_hdr header; /* Output file information */ - rle_pixel **rle_row, *red, *green, *blue; + rle_pixel **rle_row, *red_ptr, *green_ptr, *blue_ptr; JSAMPROW output_row; char cmapcomment[80]; int row, col; @@ -221,37 +223,37 @@ finish_output_rle (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) #endif if (cinfo->output_components == 1) { - for (row = cinfo->output_height-1; row >= 0; row--) { + for (row = cinfo->output_height - 1; row >= 0; row--) { rle_row = (rle_pixel **) (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, dest->image, + ((j_common_ptr) cinfo, dest->image, (JDIMENSION) row, (JDIMENSION) 1, FALSE); rle_putrow(rle_row, (int) cinfo->output_width, &header); #ifdef PROGRESS_REPORT if (progress != NULL) { - progress->pub.pass_counter++; - (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); + progress->pub.pass_counter++; + (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); } #endif } } else { - for (row = cinfo->output_height-1; row >= 0; row--) { - rle_row = (rle_pixel **) dest->rle_row; + for (row = cinfo->output_height - 1; row >= 0; row--) { output_row = * (*cinfo->mem->access_virt_sarray) - ((j_common_ptr) cinfo, dest->image, + ((j_common_ptr) cinfo, dest->image, (JDIMENSION) row, (JDIMENSION) 1, FALSE); - red = rle_row[0]; - green = rle_row[1]; - blue = rle_row[2]; + rle_row = dest->rle_row; + red_ptr = rle_row[0]; + green_ptr = rle_row[1]; + blue_ptr = rle_row[2]; for (col = cinfo->output_width; col > 0; col--) { - *red++ = GETJSAMPLE(*output_row++); - *green++ = GETJSAMPLE(*output_row++); - *blue++ = GETJSAMPLE(*output_row++); + *red_ptr++ = GETJSAMPLE(*output_row++); + *green_ptr++ = GETJSAMPLE(*output_row++); + *blue_ptr++ = GETJSAMPLE(*output_row++); } rle_putrow(rle_row, (int) cinfo->output_width, &header); #ifdef PROGRESS_REPORT if (progress != NULL) { - progress->pub.pass_counter++; - (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); + progress->pub.pass_counter++; + (*progress->pub.progress_monitor) ((j_common_ptr) cinfo); } #endif } @@ -280,9 +282,8 @@ jinit_write_rle (j_decompress_ptr cinfo) rle_dest_ptr dest; /* Create module interface object, fill in method pointers */ - dest = (rle_dest_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(rle_dest_struct)); + dest = (rle_dest_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(rle_dest_struct)); dest->pub.start_output = start_output_rle; dest->pub.finish_output = finish_output_rle; @@ -290,14 +291,13 @@ jinit_write_rle (j_decompress_ptr cinfo) jpeg_calc_output_dimensions(cinfo); /* Allocate a work array for output to the RLE library. */ - dest->rle_row = (*cinfo->mem->alloc_sarray) - ((j_common_ptr) cinfo, JPOOL_IMAGE, - cinfo->output_width, (JDIMENSION) cinfo->output_components); + dest->rle_row = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, cinfo->output_width, (JDIMENSION) cinfo->output_components); /* Allocate a virtual array to hold the image. */ dest->image = (*cinfo->mem->request_virt_sarray) ((j_common_ptr) cinfo, JPOOL_IMAGE, FALSE, - (JDIMENSION) (cinfo->output_width * cinfo->output_components), + cinfo->output_width * (JDIMENSION) cinfo->output_components, cinfo->output_height, (JDIMENSION) 1); return &dest->pub; diff --git a/external/jpeg-9c/wrtarga.c b/external/jpeg-9d/wrtarga.c similarity index 89% rename from external/jpeg-9c/wrtarga.c rename to external/jpeg-9d/wrtarga.c index 276a42ce..8ded5183 100644 --- a/external/jpeg-9c/wrtarga.c +++ b/external/jpeg-9d/wrtarga.c @@ -2,7 +2,7 @@ * wrtarga.c * * Copyright (C) 1991-1996, Thomas G. Lane. - * Modified 2015-2017 by Guido Vollbeding. + * Modified 2015-2019 by Guido Vollbeding. * This file is part of the Independent JPEG Group's software. * For conditions of distribution and use, see the accompanying README file. * @@ -167,19 +167,20 @@ put_demapped_gray (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo, METHODDEF(void) start_output_tga (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) { - tga_dest_ptr dest = (tga_dest_ptr) dinfo; int num_colors, i; FILE *outfile; - if (cinfo->out_color_space == JCS_GRAYSCALE) { + switch (cinfo->out_color_space) { + case JCS_GRAYSCALE: /* Targa doesn't have a mapped grayscale format, so we will */ /* demap quantized gray output. Never emit a colormap. */ write_header(cinfo, dinfo, 0); if (cinfo->quantize_colors) - dest->pub.put_pixel_rows = put_demapped_gray; + dinfo->put_pixel_rows = put_demapped_gray; else - dest->pub.put_pixel_rows = put_gray_rows; - } else if (cinfo->out_color_space == JCS_RGB) { + dinfo->put_pixel_rows = put_gray_rows; + break; + case JCS_RGB: if (cinfo->quantize_colors) { /* We only support 8-bit colormap indexes, so only 256 colors */ num_colors = cinfo->actual_number_of_colors; @@ -187,18 +188,19 @@ start_output_tga (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo) ERREXIT1(cinfo, JERR_TOO_MANY_COLORS, num_colors); write_header(cinfo, dinfo, num_colors); /* Write the colormap. Note Targa uses BGR byte order */ - outfile = dest->pub.output_file; + outfile = dinfo->output_file; for (i = 0; i < num_colors; i++) { putc(GETJSAMPLE(cinfo->colormap[2][i]), outfile); putc(GETJSAMPLE(cinfo->colormap[1][i]), outfile); putc(GETJSAMPLE(cinfo->colormap[0][i]), outfile); } - dest->pub.put_pixel_rows = put_gray_rows; + dinfo->put_pixel_rows = put_gray_rows; } else { write_header(cinfo, dinfo, 0); - dest->pub.put_pixel_rows = put_pixel_rows; + dinfo->put_pixel_rows = put_pixel_rows; } - } else { + break; + default: ERREXIT(cinfo, JERR_TGA_COLORSPACE); } } @@ -228,9 +230,8 @@ jinit_write_targa (j_decompress_ptr cinfo) tga_dest_ptr dest; /* Create module interface object, fill in method pointers */ - dest = (tga_dest_ptr) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - SIZEOF(tga_dest_struct)); + dest = (tga_dest_ptr) (*cinfo->mem->alloc_small) + ((j_common_ptr) cinfo, JPOOL_IMAGE, SIZEOF(tga_dest_struct)); dest->pub.start_output = start_output_tga; dest->pub.finish_output = finish_output_tga; @@ -239,13 +240,12 @@ jinit_write_targa (j_decompress_ptr cinfo) /* Create I/O buffer. Note we make this near on a PC. */ dest->buffer_width = cinfo->output_width * cinfo->output_components; - dest->iobuffer = (char *) - (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE, - (size_t) (dest->buffer_width * SIZEOF(char))); + dest->iobuffer = (char *) (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, + JPOOL_IMAGE, (size_t) dest->buffer_width * SIZEOF(char)); /* Create decompressor output buffer. */ - dest->pub.buffer = (*cinfo->mem->alloc_sarray) - ((j_common_ptr) cinfo, JPOOL_IMAGE, dest->buffer_width, (JDIMENSION) 1); + dest->pub.buffer = (*cinfo->mem->alloc_sarray) ((j_common_ptr) cinfo, + JPOOL_IMAGE, dest->buffer_width, (JDIMENSION) 1); dest->pub.buffer_height = 1; return &dest->pub;