update to 2.14.0

This commit is contained in:
zhanzhimin 2021-02-02 19:22:09 +08:00
parent 2fa7082726
commit fddbcd779e
5 changed files with 39 additions and 5 deletions

Binary file not shown.

BIN
libimagequant-2.14.0.tar.gz Normal file

Binary file not shown.

View File

@ -1,12 +1,13 @@
Name: libimagequant
Version: 2.12.5
Release: 2
Version: 2.14.0
Release: 1
Summary: Palette quantization library
License: GPLv3+ and MIT
URL: https://github.com/ImageOptim/libimagequant
Source0: %{url}/archive/%{version}/%{name}-%{version}.tar.gz
Patch0000: libimagequant_solibperm.patch
Patch0001: libimagequant_omp.patch
%description
The portable C library can convert RGBA images into
@ -45,6 +46,9 @@ rm -f %{buildroot}%{_libdir}/%{name}.a
%{_libdir}/pkgconfig/imagequant.pc
%changelog
* Tue Feb 02 2021 zhanzhimin <zhanzhimin@huawei.com> - 2.14.0-1
- update to 2.14.0
* Thu Nov 14 2019 wangye<wangye54@huawei.com> - 2.12.5-2
- Package init

21
libimagequant_omp.patch Normal file
View File

@ -0,0 +1,21 @@
diff -rupN libimagequant-2.14.0/libimagequant.c libimagequant-2.14.0-new/libimagequant.c
---
libimagequant.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libimagequant.c b/libimagequant.c
index 4f0b48f..047c042 100644
--- a/libimagequant.c
+++ b/libimagequant.c
@@ -1279,7 +1279,7 @@ LIQ_NONNULL static float remap_to_palette(liq_image *const input_image, unsigned
#if __GNUC__ >= 9 || __clang__
#pragma omp parallel for if (rows*cols > 3000) \
- schedule(static) default(none) shared(acolormap,average_color,cols,input_image,map,n,output_pixels,rows,transparent_index) reduction(+:remapping_error)
+ schedule(static) default(none) shared(acolormap,average_color,cols,input_image,map,n,output_pixels,rows,transparent_index,background) reduction(+:remapping_error)
#else
#pragma omp parallel for if (rows*cols > 3000) \
schedule(static) default(none) shared(acolormap) shared(average_color) reduction(+:remapping_error)
--
2.23.0

View File

@ -1,6 +1,12 @@
diff -rupN libimagequant-2.12.5/Makefile libimagequant-2.12.5-new/Makefile
--- libimagequant-2.12.5/Makefile 2019-07-27 14:50:23.000000000 +0200
+++ libimagequant-2.12.5-new/Makefile 2019-07-29 16:46:54.585923523 +0200
diff -rupN --no-dereference libimagequant-2.14.0/Makefile libimagequant-2.14.0-new/Makefile
---
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
index dca4115..b499f5a 100644
--- a/Makefile
+++ b/Makefile
@@ -114,7 +114,7 @@ install: all $(PKGCONFIG)
install -d $(DESTDIR)$(PKGCONFIGDIR)
install -d $(DESTDIR)$(INCLUDEDIR)
@ -10,3 +16,6 @@ diff -rupN libimagequant-2.12.5/Makefile libimagequant-2.12.5-new/Makefile
ln -sf $(SHAREDLIBVER) $(DESTDIR)$(LIBDIR)/$(SHAREDLIB)
install -m 644 $(PKGCONFIG) $(DESTDIR)$(PKGCONFIGDIR)/$(PKGCONFIG)
install -m 644 libimagequant.h $(DESTDIR)$(INCLUDEDIR)/libimagequant.h
--
2.23.0