[PATCH 1/2] gnu: libjxr: Build and install shared library.

  • Done
  • quality assurance status badge
Details
2 participants
  • Kei Kebreau
  • Marius Bakke
Owner
unassigned
Submitted by
Kei Kebreau
Severity
normal
K
K
Kei Kebreau wrote on 8 Jan 2019 01:32
(address . guix-patches@gnu.org)(name . Kei Kebreau)(address . kkebreau@posteo.net)
20190108003202.20331-1-kkebreau@posteo.net
* gnu/packages/image.scm (libjxr)[arguments]: Add -fPIC to CFLAGS for shared
library support. Add 'build-shared-library' phase and modify 'install' phase
to install the shared libraries.
---
gnu/packages/image.scm | 90 ++++++++++++++++++++++++++++--------------
1 file changed, 60 insertions(+), 30 deletions(-)

Toggle diff (103 lines)
diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index 8771eb8ae..e78ef5618 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -370,36 +370,66 @@ lossless JPEG manipulations such as rotation, scaling or cropping:
(patches (search-patches "libjxr-fix-function-signature.patch"
"libjxr-fix-typos.patch"))))
(build-system gnu-build-system)
- (arguments '(#:make-flags '("CC=gcc")
- #:tests? #f ; no check target
- #:phases
- (modify-phases %standard-phases
- (delete 'configure) ; no configure script
- ;; The upstream makefile does not include an install phase.
- (replace 'install
- (lambda* (#:key outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (bin (string-append out "/bin"))
- (lib (string-append out "/lib"))
- (include (string-append out "/include/jxrlib")))
- (for-each (lambda (file)
- (install-file file include)
- (delete-file file))
- (append
- '("jxrgluelib/JXRGlue.h"
- "jxrgluelib/JXRMeta.h"
- "jxrtestlib/JXRTest.h"
- "image/sys/windowsmediaphoto.h")
- (find-files "common/include" "\\.h$")))
- (for-each (lambda (file)
- (install-file file lib)
- (delete-file file))
- (find-files "." "\\.a$"))
- (for-each (lambda (file)
- (install-file file bin)
- (delete-file file))
- '("JxrDecApp" "JxrEncApp")))
- #t)))))
+ (arguments
+ '(#:make-flags
+ (list "CC=gcc"
+ ;; A substitute* procedure call would be enough to add the -fPIC
+ ;; flag if there was no file decoding error.
+ ;; The makefile is a "Non-ISO extended-ASCII text, with CRLF line
+ ;; terminators" according to the file(1) utility.
+ (string-append "CFLAGS=-I. -Icommon/include -Iimage/sys -fPIC "
+ "-D__ANSI__ -DDISABLE_PERF_MEASUREMENT -w -O "))
+ #:tests? #f ; no check target
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure) ; no configure script
+ (add-after 'build 'build-shared-library
+ (lambda _
+ ;; The Makefile uses optimization level 1, so the same
+ ;; level is used here for consistency.
+ (invoke "gcc" "-shared" "-fPIC" "-O"
+ ;; Common files.
+ "adapthuff.o" "image.o" "strcodec.o" "strPredQuant.o"
+ "strTransform.o" "perfTimerANSI.o"
+ ;; Decoding files.
+ "decode.o" "postprocess.o" "segdec.o" "strdec.o"
+ "strInvTransform.o" "strPredQuantDec.o" "JXRTranscode.o"
+ ;; Encoding files.
+ "encode.o" "segenc.o" "strenc.o" "strFwdTransform.o"
+ "strPredQuantEnc.o"
+ "-o" "libjpegxr.so")
+ (invoke "gcc" "-shared" "-fPIC" "-O"
+ ;; Glue files.
+ "JXRGlue.o" "JXRMeta.o" "JXRGluePFC.o" "JXRGlueJxr.o"
+ ;; Test files.
+ "JXRTest.o" "JXRTestBmp.o" "JXRTestHdr.o" "JXRTestPnm.o"
+ "JXRTestTif.o" "JXRTestYUV.o"
+ "-o" "libjxrglue.so")))
+ ;; The upstream makefile does not include an install phase.
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (bin (string-append out "/bin"))
+ (lib (string-append out "/lib"))
+ (include (string-append out "/include/jxrlib")))
+ (for-each (lambda (file)
+ (install-file file include)
+ (delete-file file))
+ (append
+ '("jxrgluelib/JXRGlue.h"
+ "jxrgluelib/JXRMeta.h"
+ "jxrtestlib/JXRTest.h"
+ "image/sys/windowsmediaphoto.h")
+ (find-files "common/include" "\\.h$")))
+ (for-each (lambda (file)
+ (install-file file lib)
+ (delete-file file))
+ (find-files "." "\\.(a|so)$"))
+ (for-each (lambda (file)
+ (install-file file bin)
+ (delete-file file))
+ '("JxrDecApp" "JxrEncApp")))
+ #t)))))
(synopsis "Implementation of the JPEG XR standard")
(description "JPEG XR is an approved ISO/IEC International standard (its
official designation is ISO/IEC 29199-2). This library is an implementation of that standard.")
--
2.20.1
K
K
Kei Kebreau wrote on 8 Jan 2019 01:36
[PATCH 2/2] gnu: freeimage: Update to 3.18.0.
(address . 34013@debbugs.gnu.org)(name . Kei Kebreau)(address . kkebreau@posteo.net)
20190108003649.20829-1-kkebreau@posteo.net
* gnu/packages/image.scm (freeimage): Update to 3.18.0.
[source]: Modify snippet to remove the bundled libjxr. Remove obsolete
patches.
[arguments]: Add libjxr include directory to #:make-flags.
[inputs]: Add libjxr and substitute libjpeg-turbo for libjpeg.
* gnu/packages/patches/freeimage-CVE-2015-0852.patch,
gnu/packages/patches/freeimage-CVE-2016-5684.patch,
gnu/packages/patches/freeimage-fix-build-with-gcc-5.patch: Delete files.
* gnu/local.mk (dist_patch_DATA): Unregister patches.
* gnu/packages/patches/freeimage-unbundle.patch: Update patch.
---
gnu/local.mk | 3 -
gnu/packages/image.scm | 20 +-
.../patches/freeimage-CVE-2015-0852.patch | 129 --
.../patches/freeimage-CVE-2016-5684.patch | 34 -
.../freeimage-fix-build-with-gcc-5.patch | 1453 -----------------
gnu/packages/patches/freeimage-unbundle.patch | 366 ++++-
6 files changed, 298 insertions(+), 1707 deletions(-)
delete mode 100644 gnu/packages/patches/freeimage-CVE-2015-0852.patch
delete mode 100644 gnu/packages/patches/freeimage-CVE-2016-5684.patch
delete mode 100644 gnu/packages/patches/freeimage-fix-build-with-gcc-5.patch

Toggle diff (95 lines)
diff --git a/gnu/local.mk b/gnu/local.mk
index bc54b61c2..c083ae281 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -704,9 +704,6 @@ dist_patch_DATA = \
%D%/packages/patches/flint-ldconfig.patch \
%D%/packages/patches/foomatic-filters-CVE-2015-8327.patch \
%D%/packages/patches/foomatic-filters-CVE-2015-8560.patch \
- %D%/packages/patches/freeimage-CVE-2015-0852.patch \
- %D%/packages/patches/freeimage-CVE-2016-5684.patch \
- %D%/packages/patches/freeimage-fix-build-with-gcc-5.patch \
%D%/packages/patches/freeimage-unbundle.patch \
%D%/packages/patches/fuse-overlapping-headers.patch \
%D%/packages/patches/gawk-shell.patch \
diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index e78ef5618..100566d92 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -807,7 +807,7 @@ supplies a generic doubly-linked list and some string functions.")
(define-public freeimage
(package
(name "freeimage")
- (version "3.17.0")
+ (version "3.18.0")
(source (origin
(method url-fetch)
(uri (string-append
@@ -817,7 +817,7 @@ supplies a generic doubly-linked list and some string functions.")
".zip"))
(sha256
(base32
- "12bz57asdcfsz3zr9i9nska0fb6h3z2aizy412qjqkixkginbz7v"))
+ "1z9qwi9mlq69d5jipr3v2jika2g0kszqdzilggm99nls5xl7j4zl"))
(modules '((guix build utils)))
(snippet
'(begin
@@ -825,12 +825,8 @@ supplies a generic doubly-linked list and some string functions.")
(lambda (dir)
(delete-file-recursively (string-append "Source/" dir)))
'("LibJPEG" "LibOpenJPEG" "LibPNG" "LibRawLite"
- ;; "LibJXR"
- "LibWebP" "OpenEXR" "ZLib"))))
- (patches (search-patches "freeimage-unbundle.patch"
- "freeimage-CVE-2015-0852.patch"
- "freeimage-CVE-2016-5684.patch"
- "freeimage-fix-build-with-gcc-5.patch"))))
+ "LibJXR" "LibWebP" "OpenEXR" "ZLib"))))
+ (patches (search-patches "freeimage-unbundle.patch"))))
(build-system gnu-build-system)
(arguments
'(#:phases
@@ -861,15 +857,15 @@ supplies a generic doubly-linked list and some string functions.")
;; We need '-fpermissive' for Source/FreeImage.h.
;; libjxr doesn't have a pkg-config file.
(string-append "CFLAGS+=-O2 -fPIC -fvisibility=hidden -fpermissive "
- ;"-I" (assoc-ref %build-inputs "libjxr") "/include/jxrlib"
- ))
+ "-I" (assoc-ref %build-inputs "libjxr")
+ "/include/jxrlib"))
#:tests? #f)) ; no check target
(native-inputs
`(("pkg-config" ,pkg-config)
("unzip" ,unzip)))
(inputs
- `(("libjpeg" ,libjpeg)
- ;("libjxr" ,libjxr)
+ `(("libjpeg" ,libjpeg-turbo)
+ ("libjxr" ,libjxr)
("libpng" ,libpng)
("libraw" ,libraw)
("libtiff" ,libtiff)
diff --git a/gnu/packages/patches/freeimage-CVE-2015-0852.patch b/gnu/packages/patches/freeimage-CVE-2015-0852.patch
deleted file mode 100644
index 34d538e92..000000000
--- a/gnu/packages/patches/freeimage-CVE-2015-0852.patch
+++ /dev/null
@@ -1,129 +0,0 @@
-Copied from Debian.
-
-Description: fix integer overflow
-Origin: upstream
- http://freeimage.cvs.sourceforge.net/viewvc/freeimage/FreeImage/Source/FreeImage/PluginPCX.cpp?view=patch&r1=1.17&r2=1.18&pathrev=MAIN
- http://freeimage.cvs.sourceforge.net/viewvc/freeimage/FreeImage/Source/FreeImage/PluginPCX.cpp?view=patch&r1=1.18&r2=1.19&pathrev=MAIN
-Bug-Debian: https://bugs.debian.org/797165
-Last-Update: 2015-09-14
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
-Index: freeimage/Source/FreeImage/PluginPCX.cpp
-===================================================================
---- freeimage.orig/Source/FreeImage/PluginPCX.cpp
-+++ freeimage/Source/FreeImage/PluginPCX.cpp
-@@ -347,12 +347,14 @@ Load(FreeImageIO *io, fi_handle handle,
-
- try {
- // check PCX identifier
--
-- long start_pos = io->tell_proc(handle);
-- BOOL validated = pcx_validate(io, handle);
-- io->seek_proc(handle, start_pos, SEEK_SET);
-- if(!validated) {
-- throw FI_MSG_ERROR_MAGIC_NUMBER;
-+ // (note: should have been already validated using FreeImage_GetFileType but check again)
-+ {
-+ long start_pos = io->tell_proc(handle);
-+ BOOL validated = pcx_validate(io, handle);
-+ io->seek_proc(handle, start_pos, SEEK_SET);
-+ if(!validated) {
-+ throw FI_MSG_ERROR_MAGIC_NUMBER;
-+ }
- }
-
- // process the header
-@@ -366,20 +368,38 @@ Load(FreeImageIO *io, fi_handle handle,
- SwapHeader(&header);
- #endif
-
-- // allocate a new DIB
-+ // process the window
-+ const WORD *window = header.window; // left, upper, right,lower pixel coord.
-+ const int left = window[0];
-+ const int top = window[1];
-+ const int right = window[2];
-+ const int bottom = window[3];
-
-- unsigned width = header.window[2] - header.window[0] + 1;
-- unsigned height = header.window[3] - header.window[1] + 1;
-- unsigned bitcount = header.bpp * header.planes;
--
-- if (bitcount == 24) {
-- dib = FreeImage_AllocateHeader(header_only, width, height, bitcount, FI_RGBA_RED_MASK, FI_RGBA_GREEN_MASK, FI_RGBA_BLUE_MASK);
-- } else {
-- dib = FreeImage_AllocateHeader(header_only, width, height, bitcount);
-+ // check image size
-+ if((left >= right) || (top >= bottom)) {
-+ throw FI_MSG_ERROR_PARSING;
- }
-
-- // if the dib couldn't be allocated, throw an error
-+ const unsigned width = right - left + 1;
-+ const unsigned height = bottom - top + 1;
-+ const unsigned bitcount = header.bpp * header.planes;
-+
-+ // allocate a new DIB
-+ switch(bitcount) {
-+ case 1:
-+ case 4:
-+ case 8:
-+ dib = FreeImage_AllocateHeader(header_only, width, height, bitcount);
-+ break;
-+ case 24:
-+ dib = FreeImage_AllocateHeader(header_only, width, height, bitcount, FI_RGBA_RED_MASK, FI_RGBA_GREEN_MASK, FI_RGBA_BLUE_MASK);
-+ break;
-+ default:
-+ throw FI_MSG_ERROR_DIB_MEMORY;
-+ break;
-+ }
-
-+ // if the dib couldn't be allocated, throw an error
- if (!dib) {
- throw FI_MSG_ERROR_DIB_MEMORY;
- }
-@@ -426,19 +446,23 @@ Load(FreeImageIO *io, fi_handle handle,
-
- if (palette_id == 0x0C) {
- BYTE *cmap = (BYTE*)malloc(768 * sizeof(BYTE));
-- io->read_proc(cmap, 768, 1, handle);
-
-- pal = FreeImage_GetPalette(dib);
-- BYTE *pColormap = &cmap[0];
-+ if(cmap) {
-+ io->read_proc(cmap, 768, 1, handle);
-
-- for(int i = 0; i < 256; i++) {
-- pal[i].rgbRed = pColormap[0];
-- pal[i].rgbGreen = pColormap[1];
-- pal[i].rgbBlue = pColormap[2];
-- pColormap += 3;
-+ pal = FreeImage_GetPalette(dib);
-+ BYTE *pColormap = &cmap[0];
-+
-+ for(int i = 0; i < 256; i++) {
-+ pal[i].rgbRed = pColormap[0];
-+ pal[i].rgbGreen = pColormap[1];
-+ pal[i].rgbBlue = pColormap[2];
-+ pColormap += 3;
-+ }
-+
-+ free(cmap);
- }
-
-- free(cmap);
- }
-
- // wrong palette ID, perhaps a gray scale is needed ?
-@@ -466,9 +490,9 @@ Load(FreeImageIO *io, fi_handle handle,
- // calculate the line length for the PCX and the DIB
-
- // length of raster line in bytes
-- unsigned linelength = header.bytes_per_line * header.planes;
-+ const unsigned linelength = header.bytes_per_line * header.planes;
- // length of DIB line (rounded to DWORD) in bytes
-- unsigned pitch = FreeImage_GetPitch(dib);
-+ const unsigned pitch = FreeImage_GetPitch(dib);
-
- // run-length encoding ?
-
Toggle diff (188 lines)
diff --git a/gnu/packages/patches/freeimage-CVE-2016-5684.patch b/gnu/packages/patches/freeimage-CVE-2016-5684.patch
deleted file mode 100644
index 2fc02d7b0..000000000
--- a/gnu/packages/patches/freeimage-CVE-2016-5684.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From: Debian Science Maintainers
- <debian-science-maintainers@lists.alioth.debian.org>
-Date: Mon, 10 Oct 2016 08:22:44 +0100
-Subject: CVE-2016-5684
-
----
- Source/FreeImage/PluginXPM.cpp | 7 ++++++-
- 1 file changed, 6 insertions(+), 1 deletion(-)
-
-diff --git a/Source/FreeImage/PluginXPM.cpp b/Source/FreeImage/PluginXPM.cpp
-index a698321..cc7bd07 100644
---- a/Source/FreeImage/PluginXPM.cpp
-+++ b/Source/FreeImage/PluginXPM.cpp
-@@ -181,6 +181,11 @@ Load(FreeImageIO *io, fi_handle handle, int page, int flags, void *data) {
- }
- free(str);
-
-+ // check info string
-+ if((width <= 0) || (height <= 0) || (colors <= 0) || (cpp <= 0)) {
-+ throw "Improperly formed info string";
-+ }
-+
- if (colors > 256) {
- dib = FreeImage_AllocateHeader(header_only, width, height, 24, FI_RGBA_RED_MASK, FI_RGBA_GREEN_MASK, FI_RGBA_BLUE_MASK);
- } else {
-@@ -193,7 +198,7 @@ Load(FreeImageIO *io, fi_handle handle, int page, int flags, void *data) {
- FILE_RGBA rgba;
-
- str = ReadString(io, handle);
-- if(!str)
-+ if(!str || (strlen(str) < (size_t)cpp))
- throw "Error reading color strings";
-
- std::string chrs(str,cpp); //create a string for the color chars using the first cpp chars
diff --git a/gnu/packages/patches/freeimage-fix-build-with-gcc-5.patch b/gnu/packages/patches/freeimage-fix-build-with-gcc-5.patch
deleted file mode 100644
index 2c9f2c335..000000000
--- a/gnu/packages/patches/freeimage-fix-build-with-gcc-5.patch
+++ /dev/null
@@ -1,1453 +0,0 @@
-The original patch was downloaded from here:
-https://chromium-review.googlesource.com/c/297211
-
-The paths, file names, and line endings have been adapted.
-
-From eebaf97f5a1cb713d81d311308d8a48c124e5aef Mon Sep 17 00:00:00 2001
-From: James Zern <jzern@google.com>
-Date: Wed, 02 Sep 2015 23:21:13 -0700
-Subject: [PATCH] dsp/mips: add whitespace around stringizing operator
-
-fixes compile with gcc 5.1
-BUG=259
-
-Change-Id: Ideb39c6290ab8569b1b6cc835bea11c822d0286c
----
-
-diff --git a/Source/LibWebP/src/dsp/dsp.dec_mips_dsp_r2.c b/Source/LibWebP/src/dsp/dsp.dec_mips_dsp_r2.c
-index 6590f43..40e4d82 100644
---- a/Source/LibWebP/src/dsp/dsp.dec_mips_dsp_r2.c
-+++ b/Source/LibWebP/src/dsp/dsp.dec_mips_dsp_r2.c
-@@ -548,10 +548,10 @@
- // TEMP3 = SRC[D + D1 * BPS]
- #define LOAD_4_BYTES(TEMP0, TEMP1, TEMP2, TEMP3, \
- A, A1, B, B1, C, C1, D, D1, SRC) \
-- "lbu %["#TEMP0"], "#A"+"#A1"*"XSTR(BPS)"(%["#SRC"]) \n\t" \
-- "lbu %["#TEMP1"], "#B"+"#B1"*"XSTR(BPS)"(%["#SRC"]) \n\t" \
-- "lbu %["#TEMP2"], "#C"+"#C1"*"XSTR(BPS)"(%["#SRC"]) \n\t" \
-- "lbu %["#TEMP3"], "#D"+"#D1"*"XSTR(BPS)"(%["#SRC"]) \n\t" \
-+ "lbu %[" #TEMP0 "], " #A "+" #A1 "*"XSTR(BPS)"(%[" #SRC "]) \n\t" \
-+ "lbu %[" #TEMP1 "], " #B "+" #B1 "*"XSTR(BPS)"(%[" #SRC "]) \n\t" \
-+ "lbu %[" #TEMP2 "], " #C "+" #C1 "*"XSTR(BPS)"(%[" #SRC "]) \n\t" \
-+ "lbu %[" #TEMP3 "], " #D "+" #D1 "*"XSTR(BPS)"(%[" #SRC "]) \n\t" \
-
- static void SimpleHFilter16(uint8_t* p, int stride, int thresh) {
- int i;
-@@ -623,8 +623,8 @@
- // DST[A * BPS] = TEMP0
- // DST[B + C * BPS] = TEMP1
- #define STORE_8_BYTES(TEMP0, TEMP1, A, B, C, DST) \
-- "usw %["#TEMP0"], "#A"*"XSTR(BPS)"(%["#DST"]) \n\t" \
-- "usw %["#TEMP1"], "#B"+"#C"*"XSTR(BPS)"(%["#DST"]) \n\t"
-+ "usw %[" #TEMP0 "], " #A "*"XSTR(BPS)"(%[" #DST "]) \n\t" \
-+ "usw %[" #TEMP1 "], " #B "+" #C "*"XSTR(BPS)"(%[" #DST "]) \n\t"
-
- static void VE4(uint8_t* dst) { // vertical
- const uint8_t* top = dst - BPS;
-@@ -725,8 +725,8 @@
- // TEMP0 = SRC[A * BPS]
- // TEMP1 = SRC[B + C * BPS]
- #define LOAD_8_BYTES(TEMP0, TEMP1, A, B, C, SRC) \
-- "ulw %["#TEMP0"], "#A"*"XSTR(BPS)"(%["#SRC"]) \n\t" \
-- "ulw %["#TEMP1"], "#B"+"#C"*"XSTR(BPS)"(%["#SRC"]) \n\t"
-+ "ulw %[" #TEMP0 "], " #A "*"XSTR(BPS)"(%[" #SRC "]) \n\t" \
-+ "ulw %[" #TEMP1 "], " #B "+" #C "*"XSTR(BPS)"(%[" #SRC "]) \n\t"
-
- static void LD4(uint8_t* dst) { // Down-Left
- int temp0, temp1, temp2, temp3, temp4;
-@@ -873,24 +873,24 @@
- #define CLIPPING(SIZE) \
- "preceu.ph.qbl %[temp2], %[temp0] \n\t" \
- "preceu.ph.qbr %[temp0], %[temp0] \n\t" \
--".if "#SIZE" == 8 \n\t" \
-+".if " #SIZE " == 8 \n\t" \
- "preceu.ph.qbl %[temp3], %[temp1] \n\t" \
- "preceu.ph.qbr %[temp1], %[temp1] \n\t" \
- ".endif \n\t" \
- "addu.ph %[temp2], %[temp2], %[dst_1] \n\t" \
- "addu.ph %[temp0], %[temp0], %[dst_1] \n\t" \
--".if "#SIZE" == 8 \n\t" \
-+".if " #SIZE " == 8 \n\t" \
- "addu.ph %[temp3], %[temp3], %[dst_1] \n\t" \
- "addu.ph %[temp1], %[temp1], %[dst_1] \n\t" \
- ".endif \n\t" \
- "shll_s.ph %[temp2], %[temp2], 7 \n\t" \
- "shll_s.ph %[temp0], %[temp0], 7 \n\t" \
--".if "#SIZE" == 8 \n\t" \
-+".if " #SIZE " == 8 \n\t" \
- "shll_s.ph %[temp3], %[temp3], 7 \n\t" \
- "shll_s.ph %[temp1], %[temp1], 7 \n\t" \
- ".endif \n\t" \
- "precrqu_s.qb.ph %[temp0], %[temp2], %[temp0] \n\t" \
--".if "#SIZE" == 8 \n\t" \
-+".if " #SIZE " == 8 \n\t" \
- "precrqu_s.qb.ph %[temp1], %[temp3], %[temp1] \n\t" \
- ".endif \n\t"
-
-@@ -899,7 +899,7 @@
- int dst_1 = ((int)(DST)[-1] << 16) + (DST)[-1]; \
- int temp0, temp1, temp2, temp3; \
- __asm__ volatile ( \
-- ".if "#SIZE" < 8 \n\t" \
-+ ".if " #SIZE " < 8 \n\t" \
- "ulw %[temp0], 0(%[top]) \n\t" \
- "subu.ph %[dst_1], %[dst_1], %[top_1] \n\t" \
- CLIPPING(4) \
-@@ -911,7 +911,7 @@
- CLIPPING(8) \
- "usw %[temp0], 0(%[dst]) \n\t" \
- "usw %[temp1], 4(%[dst]) \n\t" \
-- ".if "#SIZE" == 16 \n\t" \
-+ ".if " #SIZE " == 16 \n\t" \
- "ulw %[temp0], 8(%[top]) \n\t" \
- "ulw %[temp1], 12(%[top]) \n\t" \
- CLIPPING(8) \
-diff --git a/Source/LibWebP/src/dsp/dsp.enc_mips32.c b/Source/LibWebP/src/dsp/dsp.enc_mips32.c
-index c5837f1..b50e08b 100644
---- a/Source/LibWebP/src/dsp/dsp.enc_mips32.c
-+++ b/Source/LibWebP/src/dsp/dsp.enc_mips32.c
-@@ -31,26 +31,26 @@
- // TEMP0..TEMP3 - registers for corresponding tmp elements
- // TEMP4..TEMP5 - temporary registers
- #define VERTICAL_PASS(A, B, C, D, TEMP4, TEMP0, TEMP1, TEMP2, TEMP3) \
-- "lh %[temp16], "#A"(%[temp20]) \n\t" \
-- "lh %[temp18], "#B"(%[temp20]) \n\t" \
-- "lh %[temp17], "#C"(%[temp20]) \n\t" \
-- "lh %[temp19], "#D"(%[temp20]) \n\t" \
-- "addu %["#TEMP4"], %[temp16], %[temp18] \n\t" \
-- "subu %[temp16], %[temp16], %[temp18] \n\t" \
-- "mul %["#TEMP0"], %[temp17], %[kC2] \n\t" \
-- "mul %[temp18], %[temp19], %[kC1] \n\t" \
-- "mul %[temp17], %[temp17], %[kC1] \n\t" \
-- "mul %[temp19], %[temp19], %[kC2] \n\t" \
-- "sra %["#TEMP0"], %["#TEMP0"], 16 \n\n" \
-- "sra %[temp18], %[temp18], 16 \n\n" \
-- "sra %[temp17], %[temp17], 16 \n\n" \
-- "sra %[temp19], %[temp19], 16 \n\n" \
-- "subu %["#TEMP2"], %["#TEMP0"], %[temp18] \n\t" \
-- "addu %["#TEMP3"], %[temp17], %[temp19] \n\t" \
-- "addu %["#TEMP0"], %["#TEMP4"], %["#TEMP3"] \n\t" \
-- "addu %["#TEMP1"], %[temp16], %["#TEMP2"] \n\t" \
-- "subu %["#TEMP2"], %[temp16], %["#TEMP2"] \n\t" \
-- "subu %["#TEMP3"], %["#TEMP4"], %["#TEMP3"] \n\t"
-+ "lh %[temp16], " #A "(%[temp20]) \n\t" \
-+ "lh %[temp18], " #B "(%[temp20]) \n\t" \
-+ "lh %[temp17], " #C "(%[temp20]) \n\t" \
-+ "lh %[temp19], " #D "(%[temp20]) \n\t" \
-+ "addu %[" #TEMP4 "], %[temp16], %[temp18] \n\t" \
-+ "subu %[temp16], %[temp16], %[temp18] \n\t" \
-+ "mul %[" #TEMP0 "], %[temp17], %[kC2] \n\t" \
-+ "mul %[temp18], %[temp19], %[kC1] \n\t" \
-+ "mul %[temp17], %[temp17], %[kC1] \n\t" \
-+ "mul %[temp19],
This message was truncated. Download the full message here.
M
M
Marius Bakke wrote on 25 Sep 2019 17:48
87k19w9y20.fsf@devup.no
Kei Kebreau <kkebreau@posteo.net> writes:

Toggle quote (11 lines)
> * gnu/packages/image.scm (freeimage): Update to 3.18.0.
> [source]: Modify snippet to remove the bundled libjxr. Remove obsolete
> patches.
> [arguments]: Add libjxr include directory to #:make-flags.
> [inputs]: Add libjxr and substitute libjpeg-turbo for libjpeg.
> * gnu/packages/patches/freeimage-CVE-2015-0852.patch,
> gnu/packages/patches/freeimage-CVE-2016-5684.patch,
> gnu/packages/patches/freeimage-fix-build-with-gcc-5.patch: Delete files.
> * gnu/local.mk (dist_patch_DATA): Unregister patches.
> * gnu/packages/patches/freeimage-unbundle.patch: Update patch.

Pushed in 8dc3c2a7d5, thanks! I had to manually modify the unbundling
patch to make it apply. Hope I did not mess anything up :-)

As an added bonus, all freeimage dependents are now working again \o/
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAl2LjFcACgkQoqBt8qM6
VPpwRAf/aeBq8j13OMMNC4hwhMC8Z0fgiSeJQe74b1drIeGNWwmq3Uxg1Y0lZalE
KpvGL83c9wSs+JvqGg3ZVGoLqkYrSexYXh1gwc9clNjZkMK5NNnsAkIFV2CTCAak
Q50aZ9xGYmeI2j2B90KCZMP2o7Re5HI9k000ng2Etf0Wn0ccL0H2A2KUd7aZbqKx
3axRYURlWI2zj35Fgz/iHu6/cYAZCww9GgrtYl4kV+p2iLwahEHFrl8hMb3eNZHa
VtNtBgqu1+pf/jmwP1W1oDqelJBgutMozMNa2uClj/wUv1Qh1L2V8vFvgGUvt64x
V3XMwY0eORs3XiSxaMWxiP3R6+taKg==
=8WhB
-----END PGP SIGNATURE-----

Closed
?