Accepting request 280697 from graphics
1 OBS-URL: https://build.opensuse.org/request/show/280697 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/libjpeg-turbo?expand=0&rev=28
This commit is contained in:
commit
9339d56a98
@ -10,60 +10,53 @@ enough to prevent race conditions.
|
||||
|
||||
--- wrjpgcom.c.orig
|
||||
+++ wrjpgcom.c
|
||||
@@ -35,15 +35,15 @@ extern void * malloc ();
|
||||
@@ -37,11 +37,11 @@
|
||||
#endif
|
||||
|
||||
#ifdef DONT_USE_B_MODE /* define mode parameters for fopen() */
|
||||
-#define READ_BINARY "r"
|
||||
-#define WRITE_BINARY "w"
|
||||
+#define READ_BINARY "re"
|
||||
+#define WRITE_BINARY "we"
|
||||
#ifdef DONT_USE_B_MODE /* define mode parameters for fopen() */
|
||||
-#define READ_BINARY "r"
|
||||
-#define WRITE_BINARY "w"
|
||||
+#define READ_BINARY "re"
|
||||
+#define WRITE_BINARY "we"
|
||||
#else
|
||||
#ifdef VMS /* VMS is very nonstandard */
|
||||
#define READ_BINARY "rb", "ctx=stm"
|
||||
#define WRITE_BINARY "wb", "ctx=stm"
|
||||
#else /* standard ANSI-compliant case */
|
||||
-#define READ_BINARY "rb"
|
||||
-#define WRITE_BINARY "wb"
|
||||
+#define READ_BINARY "rbe"
|
||||
+#define WRITE_BINARY "wbe"
|
||||
#endif
|
||||
-#define READ_BINARY "rb"
|
||||
-#define WRITE_BINARY "wb"
|
||||
+#define READ_BINARY "rbe"
|
||||
+#define WRITE_BINARY "wbe"
|
||||
#endif
|
||||
|
||||
@@ -439,7 +439,7 @@ main (int argc, char **argv)
|
||||
#ifndef EXIT_FAILURE /* define exit() codes if not provided */
|
||||
@@ -432,7 +432,7 @@
|
||||
keep_COM = 0;
|
||||
} else if (keymatch(arg, "cfile", 2)) {
|
||||
if (++argn >= argc) usage();
|
||||
- if ((comment_file = fopen(argv[argn], "r")) == NULL) {
|
||||
+ if ((comment_file = fopen(argv[argn], READ_BINARY)) == NULL) {
|
||||
fprintf(stderr, "%s: can't open %s\n", progname, argv[argn]);
|
||||
exit(EXIT_FAILURE);
|
||||
fprintf(stderr, "%s: can't open %s\n", progname, argv[argn]);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
--- cdjpeg.h.orig
|
||||
+++ cdjpeg.h
|
||||
@@ -156,15 +156,15 @@ EXTERN(FILE *) write_stdout JPP((void));
|
||||
@@ -126,11 +126,11 @@
|
||||
/* miscellaneous useful macros */
|
||||
|
||||
#ifdef DONT_USE_B_MODE /* define mode parameters for fopen() */
|
||||
-#define READ_BINARY "r"
|
||||
-#define WRITE_BINARY "w"
|
||||
+#define READ_BINARY "re"
|
||||
+#define WRITE_BINARY "we"
|
||||
#ifdef DONT_USE_B_MODE /* define mode parameters for fopen() */
|
||||
-#define READ_BINARY "r"
|
||||
-#define WRITE_BINARY "w"
|
||||
+#define READ_BINARY "re"
|
||||
+#define WRITE_BINARY "we"
|
||||
#else
|
||||
#ifdef VMS /* VMS is very nonstandard */
|
||||
#define READ_BINARY "rb", "ctx=stm"
|
||||
#define WRITE_BINARY "wb", "ctx=stm"
|
||||
#else /* standard ANSI-compliant case */
|
||||
-#define READ_BINARY "rb"
|
||||
-#define WRITE_BINARY "wb"
|
||||
+#define READ_BINARY "rbe"
|
||||
+#define WRITE_BINARY "wbe"
|
||||
#endif
|
||||
-#define READ_BINARY "rb"
|
||||
-#define WRITE_BINARY "wb"
|
||||
+#define READ_BINARY "rbe"
|
||||
+#define WRITE_BINARY "wbe"
|
||||
#endif
|
||||
|
||||
#ifndef EXIT_FAILURE /* define exit() codes if not provided */
|
||||
|
||||
--- rdswitch.c.orig
|
||||
+++ rdswitch.c
|
||||
@@ -92,7 +92,7 @@ read_quant_tables (j_compress_ptr cinfo,
|
||||
@@ -93,7 +93,7 @@
|
||||
long val;
|
||||
unsigned int table[DCTSIZE2];
|
||||
|
||||
@ -72,12 +65,12 @@ enough to prevent race conditions.
|
||||
fprintf(stderr, "Can't open table file %s\n", filename);
|
||||
return FALSE;
|
||||
}
|
||||
@@ -190,7 +190,7 @@ read_scan_script (j_compress_ptr cinfo,
|
||||
#define MAX_SCANS 100 /* quite arbitrary limit */
|
||||
@@ -191,7 +191,7 @@
|
||||
#define MAX_SCANS 100 /* quite arbitrary limit */
|
||||
jpeg_scan_info scans[MAX_SCANS];
|
||||
|
||||
- if ((fp = fopen(filename, "r")) == NULL) {
|
||||
+ if ((fp = fopen(filename, READ_BINARY)) == NULL) {
|
||||
+ if ((fp = fopen(filename, READ_BINARY)) == NULL) {
|
||||
fprintf(stderr, "Can't open scan definition file %s\n", filename);
|
||||
return FALSE;
|
||||
}
|
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:c132907417ddc40ed552fe53d6b91d5fecbb14a356a60ddc7ea50d6be9666fb9
|
||||
size 1390282
|
@ -1,9 +1,9 @@
|
||||
--- jmorecfg.h
|
||||
+++ jmorecfg.h
|
||||
@@ -158,7 +158,7 @@
|
||||
@@ -148,7 +148,7 @@
|
||||
/* INT32 must hold at least signed 32-bit values. */
|
||||
|
||||
#ifndef XMD_H /* X11/xmd.h correctly defines INT32 */
|
||||
#ifndef XMD_H /* X11/xmd.h correctly defines INT32 */
|
||||
-typedef long INT32;
|
||||
+typedef int INT32;
|
||||
#endif
|
3
libjpeg-turbo-1.4.0.tar.gz
Normal file
3
libjpeg-turbo-1.4.0.tar.gz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:d93ad8546b510244f863b39b4c0da0fa4c0d53a77b61a8a3880f258c232bbbee
|
||||
size 1524645
|
@ -1,13 +0,0 @@
|
||||
Index: jchuff.c
|
||||
===================================================================
|
||||
--- jchuff.c.orig 2012-06-30 01:52:08.000000000 +0200
|
||||
+++ jchuff.c 2014-11-24 13:52:20.214638106 +0100
|
||||
@@ -392,7 +392,7 @@
|
||||
#endif
|
||||
|
||||
|
||||
-#define BUFSIZE (DCTSIZE2 * 2)
|
||||
+#define BUFSIZE (DCTSIZE2 * 4)
|
||||
|
||||
#define LOAD_BUFFER() { \
|
||||
if (state->free_in_buffer < BUFSIZE) { \
|
@ -1,3 +1,67 @@
|
||||
-------------------------------------------------------------------
|
||||
Sat Jan 10 00:39:57 UTC 2015 - p.drouand@gmail.com
|
||||
|
||||
- Update to version 1.4.0
|
||||
+ Fixed a build issue on OS X PowerPC platforms (md5cmp failed to build
|
||||
because OS X does not provide the le32toh() and htole32() functions.)
|
||||
+ The non-SIMD RGB565 color conversion code did not work correctly on big
|
||||
endian machines. This has been fixed.
|
||||
+ Fixed an issue in tjPlaneSizeYUV() whereby it would erroneously return 1
|
||||
instead of -1 if componentID was > 0 and subsamp was TJSAMP_GRAY.
|
||||
+ Fixed an issue in tjBufSizeYUV2() wherby it would erroneously return 0
|
||||
instead of -1 if width was < 1.
|
||||
+ The Huffman encoder now uses clz and bsr instructions for bit counting on
|
||||
ARM64 platforms (see 1.4 beta1 [5].)
|
||||
+ The close() method in the TJCompressor and TJDecompressor Java classes is
|
||||
now idempotent. Previously, that method would call the native tjDestroy()
|
||||
function even if the TurboJPEG instance had already been destroyed. This
|
||||
caused an exception to be thrown during finalization, if the close() method had
|
||||
already been called. The exception was caught, but it was still an expensive
|
||||
operation.
|
||||
+ The TurboJPEG API previously generated an error ("Could not determine
|
||||
subsampling type for JPEG image") when attempting to decompress grayscale JPEG
|
||||
images that were compressed with a sampling factor other than 1 (for instance,
|
||||
with 'cjpeg -grayscale -sample 2x2'). Subsampling technically has no meaning
|
||||
with grayscale JPEGs, and thus the horizontal and vertical sampling factors
|
||||
for such images are ignored by the decompressor. However, the TurboJPEG API
|
||||
was being too rigid and was expecting the sampling factors to be equal to 1
|
||||
before it treated the image as a grayscale JPEG.
|
||||
+ cjpeg, djpeg, and jpegtran now accept an argument of -version, which will
|
||||
print the library version and exit.
|
||||
+ Referring to 1.4 beta1 [15], another extremely rare circumstance was
|
||||
discovered under which the Huffman encoder's local buffer can be overrun
|
||||
when a buffered destination manager is being used and an
|
||||
extremely-high-frequency block (basically junk image data) is being encoded.
|
||||
Even though the Huffman local buffer was increased from 128 bytes to 136 bytes
|
||||
to address the previous issue, the new issue caused even the larger buffer to
|
||||
be overrun. Further analysis reveals that, in the absolute worst case (such as
|
||||
setting alternating AC coefficients to 32767 and -32768 in the JPEG scanning
|
||||
order), the Huffman encoder can produce encoded blocks that approach double the
|
||||
size of the unencoded blocks. Thus, the Huffman local buffer was increased to
|
||||
256 bytes, which should prevent any such issue from re-occurring in the future.
|
||||
+ The new tjPlaneSizeYUV(), tjPlaneWidth(), and tjPlaneHeight() functions
|
||||
were not actually usable on any platform except OS X and Windows, because
|
||||
those functions were not included in the libturbojpeg mapfile. This has been
|
||||
fixed.
|
||||
+ Restored the JPP(), JMETHOD(), and FAR macros in the libjpeg-turbo header
|
||||
files. The JPP() and JMETHOD() macros were originally implemented in libjpeg
|
||||
as a way of supporting non-ANSI compilers that lacked support for prototype
|
||||
parameters. libjpeg-turbo has never supported such compilers, but some
|
||||
software packages still use the macros to define their own prototypes.
|
||||
Similarly, libjpeg-turbo has never supported MS-DOS and other platforms that
|
||||
have far symbols, but some software packages still use the FAR macro. A pretty
|
||||
good argument can be made that this is a bad practice on the part of the
|
||||
software in question, but since this affects more than one package, it's just
|
||||
easier to fix it here.
|
||||
+ Fixed issues that were preventing the ARM 64-bit SIMD code from compiling
|
||||
for iOS, and included an ARMv8 architecture in all of the binaries installed by
|
||||
the "official" libjpeg-turbo SDK for OS X.
|
||||
- Adapt patches to upstream changes
|
||||
libjpeg-ocloexec.patch > libjpeg-1.4.0-ocloexec.patch
|
||||
libjpeg-turbo-1.3.0-int32.patch > libjpeg-turbo-1.4.0-int32.patch
|
||||
- Remove libjpeg-turbo-CVE-2014-9092.patch; fixed on upstream release
|
||||
- Bump tminor to 1
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Nov 27 09:50:00 UTC 2014 - pgajdos@suse.com
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package libjpeg-turbo
|
||||
#
|
||||
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -16,13 +16,13 @@
|
||||
#
|
||||
|
||||
|
||||
%define srcver 1.3.1
|
||||
%define srcver 1.4.0
|
||||
%define major 8
|
||||
%define minor 0
|
||||
%define micro 2
|
||||
%define libver %{major}.%{minor}.%{micro}
|
||||
%define tmajor 0
|
||||
%define tminor 0
|
||||
%define tminor 1
|
||||
%define tmicro 0
|
||||
%define tlibver %{tmajor}.%{tminor}.%{tmicro}
|
||||
|
||||
@ -35,10 +35,9 @@ Group: Productivity/Graphics/Convertors
|
||||
Url: http://sourceforge.net/projects/libjpeg-turbo
|
||||
Source0: http://downloads.sourceforge.net/project/%{name}/%{version}/libjpeg-turbo-%{version}.tar.gz
|
||||
Source1: baselibs.conf
|
||||
Patch0: libjpeg-turbo-1.3.0-int32.patch
|
||||
Patch0: libjpeg-turbo-1.4.0-int32.patch
|
||||
Patch1: libjpeg-turbo-1.3.0-tiff-ojpeg.patch
|
||||
Patch2: libjpeg-ocloexec.patch
|
||||
Patch3: libjpeg-turbo-CVE-2014-9092.patch
|
||||
Patch2: libjpeg-1.4.0-ocloexec.patch
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: libtool
|
||||
BuildRequires: yasm
|
||||
@ -107,7 +106,6 @@ files using the libjpeg library.
|
||||
%patch0
|
||||
%patch1
|
||||
%patch2
|
||||
%patch3
|
||||
|
||||
%build
|
||||
autoreconf -fiv
|
||||
|
@ -1,3 +1,67 @@
|
||||
-------------------------------------------------------------------
|
||||
Sat Jan 10 00:39:57 UTC 2015 - p.drouand@gmail.com
|
||||
|
||||
- Update to version 1.4.0
|
||||
+ Fixed a build issue on OS X PowerPC platforms (md5cmp failed to build
|
||||
because OS X does not provide the le32toh() and htole32() functions.)
|
||||
+ The non-SIMD RGB565 color conversion code did not work correctly on big
|
||||
endian machines. This has been fixed.
|
||||
+ Fixed an issue in tjPlaneSizeYUV() whereby it would erroneously return 1
|
||||
instead of -1 if componentID was > 0 and subsamp was TJSAMP_GRAY.
|
||||
+ Fixed an issue in tjBufSizeYUV2() wherby it would erroneously return 0
|
||||
instead of -1 if width was < 1.
|
||||
+ The Huffman encoder now uses clz and bsr instructions for bit counting on
|
||||
ARM64 platforms (see 1.4 beta1 [5].)
|
||||
+ The close() method in the TJCompressor and TJDecompressor Java classes is
|
||||
now idempotent. Previously, that method would call the native tjDestroy()
|
||||
function even if the TurboJPEG instance had already been destroyed. This
|
||||
caused an exception to be thrown during finalization, if the close() method had
|
||||
already been called. The exception was caught, but it was still an expensive
|
||||
operation.
|
||||
+ The TurboJPEG API previously generated an error ("Could not determine
|
||||
subsampling type for JPEG image") when attempting to decompress grayscale JPEG
|
||||
images that were compressed with a sampling factor other than 1 (for instance,
|
||||
with 'cjpeg -grayscale -sample 2x2'). Subsampling technically has no meaning
|
||||
with grayscale JPEGs, and thus the horizontal and vertical sampling factors
|
||||
for such images are ignored by the decompressor. However, the TurboJPEG API
|
||||
was being too rigid and was expecting the sampling factors to be equal to 1
|
||||
before it treated the image as a grayscale JPEG.
|
||||
+ cjpeg, djpeg, and jpegtran now accept an argument of -version, which will
|
||||
print the library version and exit.
|
||||
+ Referring to 1.4 beta1 [15], another extremely rare circumstance was
|
||||
discovered under which the Huffman encoder's local buffer can be overrun
|
||||
when a buffered destination manager is being used and an
|
||||
extremely-high-frequency block (basically junk image data) is being encoded.
|
||||
Even though the Huffman local buffer was increased from 128 bytes to 136 bytes
|
||||
to address the previous issue, the new issue caused even the larger buffer to
|
||||
be overrun. Further analysis reveals that, in the absolute worst case (such as
|
||||
setting alternating AC coefficients to 32767 and -32768 in the JPEG scanning
|
||||
order), the Huffman encoder can produce encoded blocks that approach double the
|
||||
size of the unencoded blocks. Thus, the Huffman local buffer was increased to
|
||||
256 bytes, which should prevent any such issue from re-occurring in the future.
|
||||
+ The new tjPlaneSizeYUV(), tjPlaneWidth(), and tjPlaneHeight() functions
|
||||
were not actually usable on any platform except OS X and Windows, because
|
||||
those functions were not included in the libturbojpeg mapfile. This has been
|
||||
fixed.
|
||||
+ Restored the JPP(), JMETHOD(), and FAR macros in the libjpeg-turbo header
|
||||
files. The JPP() and JMETHOD() macros were originally implemented in libjpeg
|
||||
as a way of supporting non-ANSI compilers that lacked support for prototype
|
||||
parameters. libjpeg-turbo has never supported such compilers, but some
|
||||
software packages still use the macros to define their own prototypes.
|
||||
Similarly, libjpeg-turbo has never supported MS-DOS and other platforms that
|
||||
have far symbols, but some software packages still use the FAR macro. A pretty
|
||||
good argument can be made that this is a bad practice on the part of the
|
||||
software in question, but since this affects more than one package, it's just
|
||||
easier to fix it here.
|
||||
+ Fixed issues that were preventing the ARM 64-bit SIMD code from compiling
|
||||
for iOS, and included an ARMv8 architecture in all of the binaries installed by
|
||||
the "official" libjpeg-turbo SDK for OS X.
|
||||
- Adapt patches to upstream changes
|
||||
libjpeg-ocloexec.patch > libjpeg-1.4.0-ocloexec.patch
|
||||
libjpeg-turbo-1.3.0-int32.patch > libjpeg-turbo-1.4.0-int32.patch
|
||||
- Remove libjpeg-turbo-CVE-2014-9092.patch; fixed on upstream release
|
||||
- Bump tminor to 1
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Nov 27 09:49:28 UTC 2014 - pgajdos@suse.com
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package libjpeg62-turbo
|
||||
#
|
||||
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -19,7 +19,7 @@
|
||||
%define major 62
|
||||
%define minor 1
|
||||
%define micro 0
|
||||
%define srcver 1.3.1
|
||||
%define srcver 1.4.0
|
||||
%define libver %{major}.%{minor}.%{micro}
|
||||
|
||||
Name: libjpeg62-turbo
|
||||
@ -31,10 +31,9 @@ Group: Productivity/Graphics/Convertors
|
||||
Url: http://sourceforge.net/projects/libjpeg-turbo
|
||||
Source0: http://downloads.sourceforge.net/project/libjpeg-turbo/%{version}/libjpeg-turbo-%{version}.tar.gz
|
||||
Source1: baselibs.conf
|
||||
Patch0: libjpeg-turbo-1.3.0-int32.patch
|
||||
Patch0: libjpeg-turbo-1.4.0-int32.patch
|
||||
Patch1: libjpeg-turbo-1.3.0-tiff-ojpeg.patch
|
||||
Patch2: libjpeg-ocloexec.patch
|
||||
Patch3: libjpeg-turbo-CVE-2014-9092.patch
|
||||
Patch2: libjpeg-1.4.0-ocloexec.patch
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: libtool
|
||||
BuildRequires: yasm
|
||||
@ -88,7 +87,6 @@ files using the libjpeg library.
|
||||
%patch0
|
||||
%patch1
|
||||
%patch2
|
||||
%patch3
|
||||
|
||||
%build
|
||||
autoreconf -fiv
|
||||
|
Loading…
x
Reference in New Issue
Block a user