0887cd
%global _hardened_build 1
0887cd
0887cd
Name:          libwebp
0887cd
Version:       1.2.0
0887cd
Release:       3%{?dist}
0887cd
URL:           http://webmproject.org/
0887cd
Summary:       Library and tools for the WebP graphics format
0887cd
# Additional IPR is licensed as well. See PATENTS file for details
0887cd
License:       BSD
0887cd
Source0:       http://downloads.webmproject.org/releases/webp/%{name}-%{version}.tar.gz
0887cd
Source1:       libwebp_jni_example.java
0887cd
Patch0:        libwebp-freeglut.patch
0887cd
0887cd
BuildRequires: libjpeg-devel
0887cd
BuildRequires: libpng-devel
0887cd
BuildRequires: giflib-devel
0887cd
BuildRequires: libtiff-devel
0887cd
BuildRequires: java-devel
0887cd
BuildRequires: jpackage-utils
0887cd
BuildRequires: swig
0887cd
BuildRequires: autoconf automake libtool
0887cd
BuildRequires: freeglut-devel
0887cd
BuildRequires: make
0887cd
0887cd
%description
0887cd
WebP is an image format that does lossy compression of digital
0887cd
photographic images. WebP consists of a codec based on VP8, and a
0887cd
container based on RIFF. Webmasters, web developers and browser
0887cd
developers can use WebP to compress, archive and distribute digital
0887cd
images more efficiently.
0887cd
0887cd
0887cd
%package tools
0887cd
Summary:       The WebP command line tools
0887cd
0887cd
%description tools
0887cd
WebP is an image format that does lossy compression of digital
0887cd
photographic images. WebP consists of a codec based on VP8, and a
0887cd
container based on RIFF. Webmasters, web developers and browser
0887cd
developers can use WebP to compress, archive and distribute digital
0887cd
images more efficiently.
0887cd
0887cd
0887cd
%package devel
0887cd
Summary:       Development files for libwebp, a library for the WebP format
0887cd
Requires:      %{name}%{?_isa} = %{version}-%{release}
0887cd
0887cd
%description devel
0887cd
WebP is an image format that does lossy compression of digital
0887cd
photographic images. WebP consists of a codec based on VP8, and a
0887cd
container based on RIFF. Webmasters, web developers and browser
0887cd
developers can use WebP to compress, archive and distribute digital
0887cd
images more efficiently.
0887cd
0887cd
0887cd
%package java
0887cd
Summary:       Java bindings for libwebp, a library for the WebP format
0887cd
Requires:      %{name}%{?_isa} = %{version}-%{release}
0887cd
Requires:      java-headless
0887cd
Requires:      jpackage-utils
0887cd
0887cd
%description java
0887cd
Java bindings for libwebp.
0887cd
0887cd
0887cd
%prep
0887cd
%autosetup -p1
0887cd
0887cd
0887cd
%build
0887cd
autoreconf -vif
0887cd
%ifarch aarch64
0887cd
export CFLAGS="%{optflags} -frename-registers"
0887cd
%endif
0887cd
# Neon disabled due to resulting CFLAGS conflict resulting in
0887cd
# inlining failed in call to always_inline '[...]': target specific option mismatch
0887cd
%configure --disable-static --enable-libwebpmux \
0887cd
           --enable-libwebpdemux --enable-libwebpdecoder \
0887cd
           --disable-neon
0887cd
%make_build V=1
0887cd
make -C examples vwebp
0887cd
0887cd
# swig generated Java bindings
0887cd
cp %{SOURCE1} .
0887cd
cd swig
0887cd
rm -rf libwebp.jar libwebp_java_wrap.c
0887cd
mkdir -p java/com/google/webp
0887cd
swig -ignoremissing -I../src -java \
0887cd
    -package com.google.webp  \
0887cd
    -outdir java/com/google/webp \
0887cd
    -o libwebp_java_wrap.c libwebp.swig
0887cd
0887cd
gcc %{__global_ldflags} %{optflags} -shared \
0887cd
    -I/usr/lib/jvm/java/include \
0887cd
    -I/usr/lib/jvm/java/include/linux \
0887cd
    -I../src \
0887cd
    -L../src/.libs -lwebp libwebp_java_wrap.c \
0887cd
    -o libwebp_jni.so
0887cd
0887cd
cd java
0887cd
javac com/google/webp/libwebp.java
0887cd
jar cvf ../libwebp.jar com/google/webp/*.class
0887cd
0887cd
0887cd
%install
0887cd
%make_install
0887cd
find "%{buildroot}/%{_libdir}" -type f -name "*.la" -delete
0887cd
0887cd
# swig generated Java bindings
0887cd
mkdir -p %{buildroot}/%{_libdir}/%{name}-java
0887cd
cp swig/*.jar swig/*.so %{buildroot}/%{_libdir}/%{name}-java/
0887cd
0887cd
0887cd
%ldconfig_scriptlets
0887cd
0887cd
0887cd
%files tools
0887cd
%{_bindir}/cwebp
0887cd
%{_bindir}/dwebp
0887cd
%{_bindir}/gif2webp
0887cd
%{_bindir}/img2webp
0887cd
%{_bindir}/webpinfo
0887cd
%{_bindir}/webpmux
0887cd
%{_bindir}/vwebp
0887cd
%{_mandir}/man*/*
0887cd
0887cd
%files -n %{name}
0887cd
%doc README PATENTS NEWS AUTHORS
0887cd
%license COPYING
0887cd
%{_libdir}/%{name}.so.7*
0887cd
%{_libdir}/%{name}decoder.so.3*
0887cd
%{_libdir}/%{name}demux.so.2*
0887cd
%{_libdir}/%{name}mux.so.3*
0887cd
0887cd
%files devel
0887cd
%{_libdir}/%{name}*.so
0887cd
%{_includedir}/*
0887cd
%{_libdir}/pkgconfig/*
0887cd
0887cd
%files java
0887cd
%doc libwebp_jni_example.java
0887cd
%{_libdir}/%{name}-java/
0887cd
0887cd
0887cd
%changelog
0887cd
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 1.2.0-3
0887cd
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
0887cd
  Related: rhbz#1991688
0887cd
0887cd
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 1.2.0-2
0887cd
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
0887cd
0887cd
* Mon Feb 01 2021 Sandro Mani <manisandro@gmail.com> - 1.2.0-1
0887cd
- Update to 1.2.0
0887cd
0887cd
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-6
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
0887cd
0887cd
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-5
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
0887cd
0887cd
* Sat Jul 11 2020 Jiri Vanek <jvanek@redhat.com> - 1.1.0-4
0887cd
- Rebuilt for JDK-11, see https://fedoraproject.org/wiki/Changes/Java11
0887cd
0887cd
* Mon May 18 2020 Sandro Mani <manisandro@gmail.com> - 1.1.0-3
0887cd
- Don't manually and incorrectly install vwebp, Makefile already does it correctly (#1836640)
0887cd
0887cd
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.0-2
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
0887cd
0887cd
* Tue Jan 07 2020 Sandro Mani <manisandro@gmail.com> - 1.1.0-1
0887cd
- Update to 1.1.0
0887cd
0887cd
* Tue Sep 17 2019 Gwyn Ciesla <gwync@protonmail.com> - 1.0.3-3
0887cd
- Rebuilt for new freeglut
0887cd
0887cd
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.3-2
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
0887cd
0887cd
* Mon Jul 15 2019 Sandro Mani <manisandro@gmail.com> - 1.0.3-1
0887cd
- Update to 1.0.3
0887cd
0887cd
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.2-2
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
0887cd
0887cd
* Tue Jan 22 2019 Sandro Mani <manisandro@gmail.com> - 1.0.2-1
0887cd
- Update to 1.0.2
0887cd
0887cd
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.0-2
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
0887cd
0887cd
* Thu Apr 26 2018 Sandro Mani <manisandro@gmail.com> - 1.0.0-1
0887cd
- Update to 1.0.0
0887cd
0887cd
* Tue Feb 27 2018 Sandro Mani <manisandro@gmail.com> - 0.6.1-8
0887cd
- Fix LDFLAGS not passed when building libwebp_jni.so (#1548718)
0887cd
0887cd
* Mon Feb 26 2018 Sandro Mani <manisandro@gmail.com> - 0.6.1-7
0887cd
- More big-endian fixes
0887cd
0887cd
* Fri Feb 16 2018 Sandro Mani <manisandro@gmail.com> - 0.6.1-6
0887cd
- Backport another big-endian fix
0887cd
0887cd
* Fri Feb 16 2018 Sandro Mani <manisandro@gmail.com> - 0.6.1-5
0887cd
- Backport upstream big-endian fix
0887cd
0887cd
* Tue Feb 13 2018 Sandro Mani <manisandro@gmail.com> - 0.6.1-4
0887cd
- Rebuild (giflib)
0887cd
0887cd
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.1-3
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
0887cd
0887cd
* Sat Feb 03 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.6.1-2
0887cd
- Switch to %%ldconfig_scriptlets
0887cd
0887cd
* Thu Nov 30 2017 Sandro Mani <manisandro@gmail.com> - 0.6.1-1
0887cd
- Update to 0.6.1
0887cd
0887cd
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.0-4
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
0887cd
0887cd
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.0-3
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
0887cd
0887cd
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.0-2
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
0887cd
0887cd
* Wed Feb 01 2017 Sandro Mani <manisandro@gmail.com> - 0.6.0-1
0887cd
- Update to 0.6.0
0887cd
0887cd
* Thu Dec 22 2016 Sandro Mani <manisandro@gmail.com> - 0.5.2-1
0887cd
- Update to 0.5.2
0887cd
0887cd
* Sat Oct 29 2016 Sandro Mani <manisandro@gmail.com> - 0.5.1-2
0887cd
- Backport e2affacc35f1df6cc3b1a9fa0ceff5ce2d0cce83 (CVE-2016-9085, rhbz#1389338)
0887cd
0887cd
* Fri Aug 12 2016 Sandro Mani <manisandro@gmail.com> - 0.5.1-1
0887cd
- upstream release 0.5.1
0887cd
0887cd
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.0-2
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
0887cd
0887cd
* Mon Dec 28 2015 Sandro Mani <manisandro@gmail.com> - 0.5.0-1
0887cd
- upstream release 0.5.0
0887cd
0887cd
* Fri Oct 30 2015 Sandro Mani <manisandro@gmail.com> - 0.4.4-1
0887cd
- upstream release 0.4.4
0887cd
0887cd
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.3-3
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
0887cd
0887cd
* Fri Mar 27 2015 Sandro Mani <manisandro@gmail.com> - 0.4.3-2
0887cd
- Add BuildRequires: freeglut-devel to build vwebp
0887cd
0887cd
* Thu Mar 12 2015 Sandro Mani <manisandro@gmail.com> - 0.4.3-1
0887cd
- upstream release 0.4.3
0887cd
0887cd
* Fri Oct 17 2014 Sandro Mani <manisandro@gmail.com> - 0.4.2-1
0887cd
- upstream release 0.4.2
0887cd
0887cd
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-3
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
0887cd
0887cd
* Wed Aug 13 2014 Peter Robinson <pbrobinson@fedoraproject.org> 0.4.1-2
0887cd
- Use frename-registers cflag to fix FTBFS on aarch64
0887cd
0887cd
* Tue Aug 05 2014 Sandro Mani <manisandro@gmail.com> - 0.4.1-1
0887cd
- upstream release 0.4.1
0887cd
0887cd
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.0-4
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
0887cd
0887cd
* Tue Apr 08 2014 Jaromir Capik <jcapik@redhat.com> - 0.4.0-3
0887cd
- Fixing endian checks (#962091)
0887cd
- Fixing FTPBS caused by rpath presence
0887cd
0887cd
* Fri Mar 28 2014 Michael Simacek <msimacek@redhat.com> - 0.4.0-2
0887cd
- Use Requires: java-headless rebuild (#1067528)
0887cd
0887cd
* Thu Jan 02 2014 Sandro Mani <manisandro@gmail.com> - 0.4.0-1
0887cd
- upstream release 0.4.0
0887cd
0887cd
* Wed Oct 02 2013 Sandro Mani <manisandro@gmail.com> - 0.3.1-2
0887cd
- enable webpdemux
0887cd
0887cd
* Sun Aug 04 2013 Sandro Mani <manisandro@gmail.com> - 0.3.1-1
0887cd
- upstream release 0.3.1
0887cd
0887cd
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.0-2
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
0887cd
0887cd
* Mon May 13 2013 Rahul Sundaram <sundaram@fedoraproject.org> - 0.3.0-1
0887cd
- upstream release 0.3.0
0887cd
- enable gif2webp
0887cd
- add build requires on giflib-devel and libtiff-devel
0887cd
- use make_install and hardened macros
0887cd
- list binaries explicitly
0887cd
0887cd
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.2.1-3
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
0887cd
0887cd
* Fri Jan 18 2013 Adam Tkac <atkac redhat com> - 0.2.1-2
0887cd
- rebuild due to "jpeg8-ABI" feature drop
0887cd
0887cd
* Thu Dec 27 2012 Rahul Sundaram <sundaram@fedoraproject.org> - 0.2.1-1
0887cd
- new upstream release 0.2.1
0887cd
0887cd
* Fri Dec 21 2012 Adam Tkac <atkac redhat com> - 0.1.3-3
0887cd
- rebuild against new libjpeg
0887cd
0887cd
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.3-2
0887cd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
0887cd
0887cd
* Thu Feb 02 2012 Rahul Sundaram <sundaram@fedoraproject.org> - 0.1.3-1
0887cd
- Several spec improvements by Scott Tsai <scottt.tw@gmail.com>
0887cd
0887cd
* Wed May 25 2011 Rahul Sundaram <sundaram@fedoraproject.org> - 0.1.2-1
0887cd
- Initial spec. Based on openSUSE one