Bug 707389 - Review Request: libwebp - Library and tools for the WebP graphics format
Summary: Review Request: libwebp - Library and tools for the WebP graphics format
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Scott Tsai
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-05-24 21:45 UTC by Rahul Sundaram
Modified: 2015-04-22 05:08 UTC (History)
8 users (show)

Fixed In Version: libwebp-0.4.3-3.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-02-02 04:42:23 UTC
Type: ---
Embargoed:
scottt.tw: fedora-review+
gwync: fedora-cvs+


Attachments (Terms of Use)
libwebp_jni_example.java (764 bytes, text/x-java)
2012-01-16 00:25 UTC, Scott Tsai
no flags Details

Description Rahul Sundaram 2011-05-24 21:45:19 UTC
Spec URL: http://sundaram.fedorapeople.org/packages/libwebp.spec
SRPM URL: http://sundaram.fedorapeople.org/packages/libwebp-0.1.2-1.fc15.src.rpm
Description:
WebP is an image format that does lossy compression of digital
photographic images. WebP consists of a codec based on VP8, and a
container based on RIFF. Webmasters, web developers and browser
developers can use WebP to compress, archive and distribute digital
images more efficiently.

Comment 1 Veeti Paananen 2011-07-21 16:19:35 UTC
rpmlint:

[veeti@veeti-pc result]$ rpmlint *.rpm
libwebp.src: W: spelling-error %description -l en_US WebP -> Web P, Web, Webb
libwebp.src: W: spelling-error %description -l en_US lossy -> loss, glossy, flossy
libwebp.src: W: spelling-error %description -l en_US codec -> codex, code, codes
libwebp.x86_64: W: spelling-error %description -l en_US WebP -> Web P, Web, Webb
libwebp.x86_64: W: spelling-error %description -l en_US lossy -> loss, glossy, flossy
libwebp.x86_64: W: spelling-error %description -l en_US codec -> codex, code, codes
libwebp.x86_64: W: incoherent-version-in-changelog 1.0.2-1 ['0.1.2-1.fc15', '0.1.2-1']
libwebp-devel.x86_64: W: spelling-error %description -l en_US WebP -> Web P, Web, Webb
libwebp-devel.x86_64: W: spelling-error %description -l en_US lossy -> loss, glossy, flossy
libwebp-devel.x86_64: W: spelling-error %description -l en_US codec -> codex, code, codes
libwebp-devel.x86_64: W: no-documentation
libwebp-tools.x86_64: W: spelling-error %description -l en_US WebP -> Web P, Web, Webb
libwebp-tools.x86_64: W: spelling-error %description -l en_US lossy -> loss, glossy, flossy
libwebp-tools.x86_64: W: spelling-error %description -l en_US codec -> codex, code, codes
5 packages and 0 specfiles checked; 0 errors, 14 warnings.

-----------------------

Some "informal comments":

- As mentioned by rpmlint, the changelog has an invalid version number.

- The build requirement for automake is unnecessary.

- The build requirements should probably be listed one per line.

- The devel package's base requirement should be fully versioned ("Requires: %{name}%{?_isa} = %{version}-%{release}").

- The tools package should also require the base package.

- You should enclose all the macros like %buildroot, etc. in curly braces ( %{buildroot} ).

- libjpeg-devel and libpng-devel are probably needed for using libwebp-devel, so those should be explicit requirements. (?)

- The files for the base package should be listed first. The -n %{name} part would then be unnecessary.

- The files should be selected more verbosely:

- Since the development headers are all contained in one folder, replace the "%_includedir/*" line with "%{_includedir}/webp/".

- Since there is only one pkgconfig file, just list it as "libwebp.pc".

- The tools package should use something like "%{_bindir}/*webp".

Comment 2 Scott Tsai 2012-01-16 00:25:39 UTC
Created attachment 555405 [details]
libwebp_jni_example.java

Comment 3 Scott Tsai 2012-01-16 00:54:32 UTC
I've made a copy of the SPEC with all my recommendations applied here: http://scottt.tw/fedora/libwebp.spec for your convenience.

1. Please update to libwebp-0.1.3

Upstream released libwebp-0.1.3 in September 2011.
I've verified that simply bumping the version in the SPEC file works with the new tarball:
http://code.google.com/p/webp/downloads/detail?name=libwebp-0.1.3.tar.gz&can=2&q=

0.1.3 contains an ABI compatibility break and soname change from 0.1.2
(libwebp.so.0.0.0 -> libwebp.so.2.0.0)
Thus packaging 0.1.3 directly avoids a soname change in the future.

2. Package the SWIG generated Java bindings:
	@@ -6,8 +6,11 @@ URL:		http://webmproject.org/
	 Summary:	Library and tools for the WebP graphics format
	 # Additional IPR is licensed as well. See PATENTS file for details
	 License:	BSD
	-Source:	http://webp.googlecode.com/files/%{name}-%{version}.tar.gz
	-BuildRequires:	libjpeg-devel libpng-devel libtool 
	+Source0:	http://webp.googlecode.com/files/%{name}-%{version}.tar.gz
	+Source1:	libwebp_jni_example.java	
	+BuildRequires:	libjpeg-devel libpng-devel libtool swig
	+BuildRequires:	java-devel
	+BuildRequires:	jpackage-utils
	 
	 %description
	 WebP is an image format that does lossy compression of digital
	@@ -39,6 +42,16 @@ container based on RIFF. Webmasters, web developers and browser
	 developers can use WebP to compress, archive and distribute digital
	 images more efficiently.
	 
	+%package java
	+Group:		Development/Libraries
	+Summary:	Java bindings for libwebp, a library for the WebP format
	+Requires:	%{name}%{?_isa} = %{version}-%{release}
	+Requires:	java
	+Requires:	jpackage-utils
	+
	+%description java
	+Java bindings for libwebp.
	+
	 %prep
	 %setup -q
	 
	@@ -48,10 +61,35 @@ mkdir -p m4
	 %configure --disable-static
	 make %{?_smp_mflags}
	 
	+# swig generated Java bindings
	+cp %{SOURCE1} .
	+cd swig
	+rm -rf libwebp.jar libwebp_java_wrap.c
	+mkdir -p java/com/google/webp
	+swig -ignoremissing -I../src -java \
	+	-package com.google.webp  \
	+	-outdir java/com/google/webp \
	+	-o libwebp_java_wrap.c libwebp.i
	+
	+gcc %{optflags} -shared -fPIC -fno-strict-aliasing \
	+	-I/usr/lib/jvm/java/include \
	+	-I/usr/lib/jvm/java/include/linux \
	+	-I../src \
	+	-L../src/.libs -lwebp libwebp_java_wrap.c \
	+	-o libwebp_jni.so
	+
	+cd java
	+javac com/google/webp/libwebp.java
	+jar cvf ../libwebp.jar com/google/webp/*.class
	+
	 %install
	 make install DESTDIR=%{buildroot}
	 find "%{buildroot}/%{_libdir}" -type f -name "*.la" -delete
	 
	+# swig generated Java bindings
	+mkdir -p %{buildroot}/%{_libdir}/%{name}-java
	+cp swig/*.jar swig/*.so %{buildroot}/%{_libdir}/%{name}-java/
	+
	 %post -n %{name} -p /sbin/ldconfig
	 
	 %postun -n %{name} -p /sbin/ldconfig
	@@ -69,6 +107,10 @@ find "%{buildroot}/%{_libdir}" -type f -name "*.la" -delete
	 %{_includedir}/*
	 %{_libdir}/pkgconfig/*
	 
	+%files java
	+%doc libwebp_jni_example.java
	+%{_libdir}/%{name}-java/

The libwebp_jni_example.java file is attached to this bug.

3. Fix the dist tag:
	-Release:       1%{dist}
	+Release:       1%{?dist}

4. Fix the version number in the chanagelog:
	-* Wed May 25 2011 Rahul Sundaram <sundaram> - 1.0.2-1
	+* Wed May 25 2011 Rahul Sundaram <sundaram> - 0.1.3-1
As pointed out by Veeti.

5. Drop autoconf, automake from BuildRequires as pointed out by Veeti.

libtool already requires both autoconf and automake.
	-BuildRequires: libjpeg-devel, libpng-devel autoconf automake libtool 
	+BuildRequires: libjpeg-devel libpng-devel libtool 

6. Fix libwebp-devel's Require line as pointed out by Veeti:
	-Requires:      %{name} = %version
	+Requires:      %{name}%{?_isa} = %{version}-%{release}
See: http://fedoraproject.org/wiki/Packaging:Guidelines#Requiring_Base_Package

7. Enclose RPM macros with curly braces as pointed out by Veeti:
	-make install DESTDIR=%buildroot
	-find "%buildroot/%_libdir" -type f -name "*.la" -delete
	+make install DESTDIR=%{buildroot}
	+find "%{buildroot}/%{_libdir}" -type f -name "*.la" -delete

	-%post -n %name -p /sbin/ldconfig
	+%post -n %{name} -p /sbin/ldconfig

	-%postun -n %name -p /sbin/ldconfig
	+%postun -n %{name} -p /sbin/ldconfig

	 %files tools
	-%_bindir/*
	-%_mandir/man*/*
	+%{_bindir}/*
	+%{_mandir}/man*/*

	 %files -n %{name}
	 %doc README PATENTS COPYING NEWS AUTHORS
	-%_libdir/%{name}*.so.*
	+%{_libdir}/%{name}*.so.*

	 %files devel
	-%_libdir/%{name}*.so
	-%_includedir/*
	-%_libdir/pkgconfig/*
	+%{_libdir}/%{name}*.so
	+%{_includedir}/*
	+%{_libdir}/pkgconfig/*


Package Review
==============

Key:
- = N/A
x = Pass
! = Fail
? = Not evaluated



==== C/C++ ====
[x]: MUST Header files in -devel subpackage, if present.
[x]: MUST ldconfig called in %post and %postun if required.
[x]: MUST Package does not contain any libtool archives (.la)
[x]: MUST Package does not contain kernel modules.
[x]: MUST Package contains no static executables.
[x]: MUST Rpath absent or only used for internal libs.
[x]: MUST Package is not relocatable.
[x]: MUST Development .so files in -devel subpackage, if present.


==== Generic ====
[x]: MUST Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
     Guidelines.
[x]: MUST Package successfully compiles and builds into binary rpms on at
     least one supported primary architecture.
[x]: MUST All build dependencies are listed in BuildRequires, except for any
     that are listed in the exceptions section of Packaging Guidelines.
[x]: MUST Buildroot is not present
     Note: Unless packager wants to package for EPEL5 this is fine
[x]: MUST Package contains no bundled libraries.
[x]: MUST Changelog in prescribed format.
[x]: MUST Package has no %clean section with rm -rf %{buildroot} (or
     $RPM_BUILD_ROOT)
     Note: Clean would be needed if support for EPEL is required
[x]: MUST Sources contain only permissible code or content.
[x]: MUST Each %files section contains %defattr if rpm < 4.4
     Note: Note: defattr macros not found. They would be needed for EPEL5
[x]: MUST Macros in Summary, %description expandable at SRPM build time.
[x]: MUST Package requires other packages for directories it uses.
[x]: MUST Package uses nothing in %doc for runtime.
[x]: MUST Package is not known to require ExcludeArch.
[x]: MUST Permissions on files are set properly.
[x]: MUST Package does not contain duplicates in %files.
[x]: MUST Spec file lacks Packager, Vendor, PreReq tags.
[x]: MUST Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
     Note: rm -rf would be needed if support for EPEL5 is required
[x]: MUST If (and only if) the source package includes the text of the
     license(s) in its own file, then that file, containing the text of the
     license(s) for the package is included in %doc.
[x]: MUST License field in the package spec file matches the actual license.
[x]: MUST License file installed when any subpackage combination is installed.
[x]: MUST Package consistently uses macros (instead of hard-coded directory
     names).
[x]: MUST Package meets the Packaging Guidelines.
[x]: MUST Package is named according to the Package Naming Guidelines.
[x]: MUST Package does not generates any conflict.
[x]: MUST Package obeys FHS, except libexecdir and /usr/target.
[x]: MUST Package must own all directories that it creates.
[x]: MUST Package does not own files or directories owned by other packages.
[x]: MUST Package installs properly.
[-]: MUST Package requires pkgconfig, if .pc files are present. (EPEL5)
     Note: Only applicable for EL-5
The pkgconfig dependency is automatically picked up for Fedora.
This is fine.

[-]: MUST Requires correct, justified where necessary.
[-]: MUST Rpmlint output is silent.
All rpmlint output are justified.

These are not really spelling errors.
	rpmlint libwebp-0.1.3-1.fc17.x86_64.rpm

	libwebp.x86_64: W: spelling-error %description -l en_US WebP -> Web P, Web, Webb
	libwebp.x86_64: W: spelling-error %description -l en_US lossy -> loss, glossy, flossy
	libwebp.x86_64: W: spelling-error %description -l en_US codec -> codex, code, codes
	1 packages and 0 specfiles checked; 0 errors, 4 warnings.


	rpmlint libwebp-0.1.3-1.fc17.src.rpm

	libwebp.src: W: spelling-error %description -l en_US WebP -> Web P, Web, Webb
	libwebp.src: W: spelling-error %description -l en_US lossy -> loss, glossy, flossy
	libwebp.src: W: spelling-error %description -l en_US codec -> codex, code, codes
	1 packages and 0 specfiles checked; 0 errors, 3 warnings.


	rpmlint libwebp-devel-0.1.3-1.fc17.x86_64.rpm

	libwebp-devel.x86_64: W: spelling-error %description -l en_US WebP -> Web P, Web, Webb
	libwebp-devel.x86_64: W: spelling-error %description -l en_US lossy -> loss, glossy, flossy
	libwebp-devel.x86_64: W: spelling-error %description -l en_US codec -> codex, code, codes

No documentation in libwebp-devel is fine.
	libwebp-devel.x86_64: W: no-documentation
	1 packages and 0 specfiles checked; 0 errors, 4 warnings.


These are not really spelling errors.
	rpmlint libwebp-tools-0.1.3-1.fc17.x86_64.rpm

	libwebp-tools.x86_64: W: spelling-error %description -l en_US WebP -> Web P, Web, Webb
	libwebp-tools.x86_64: W: spelling-error %description -l en_US lossy -> loss, glossy, flossy
	libwebp-tools.x86_64: W: spelling-error %description -l en_US codec -> codex, code, codes
	1 packages and 0 specfiles checked; 0 errors, 3 warnings.


[x]: MUST Sources used to build the package match the upstream source, as
     provided in the spec URL.
/home/scottt/work/libwebp/fedora/libwebp-0.1.3.tar.gz :
  MD5SUM this package     : 254d4670e14e9ed881f0536b006ab336
  MD5SUM upstream package : 254d4670e14e9ed881f0536b006ab336

[x]: MUST Spec file is legible and written in American English.
[x]: MUST Spec file name must match the spec package %{name}, in the format
     %{name}.spec.
[-]: MUST Package contains a SysV-style init script if in need of one.
[x]: MUST File names are valid UTF-8.
[x]: SHOULD Reviewer should test that the package builds in mock.
[x]: SHOULD If the source package does not include license text(s) as a
     separate file from upstream, the packager SHOULD query upstream to
     include it.
[x]: SHOULD Dist tag is present.
[x]: SHOULD No file requires outside of /etc, /bin, /sbin, /usr/bin,
     /usr/sbin.
[x]: SHOULD Final provides and requires are sane (rpm -q --provides and rpm -q
     --requires).
[x]: SHOULD Package functions as described.
[x]: SHOULD Package does not include license text files separate from
     upstream.
[x]: SHOULD The placement of pkgconfig(.pc) files are correct.
[x]: SHOULD Scriptlets must be sane, if used.
[x]: SHOULD SourceX is a working URL.
[-]: SHOULD Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.
[x]: SHOULD Package should compile and build into binary rpms on all supported
     architectures.

http://koji.fedoraproject.org/koji/taskinfo?taskID=3704717

[-]: SHOULD %check is present and all tests pass.
[x]: SHOULD Packages should try to preserve timestamps of original installed
     files.
[x]: SHOULD Spec use %global instead of %define.

I'll approve this package once points one through seven above are addressed.

Comment 4 John Ellson 2012-01-19 19:00:21 UTC
If this library could be released for f16 & f17, I could use it for the next release of graphviz.   Upstream coding is completed and tested.

Comment 5 Peter Lemenkov 2012-01-30 20:03:13 UTC
Hello. 
Folks, what's the current status of this ticket?

Comment 6 Scott Tsai 2012-01-30 21:47:34 UTC
(In reply to comment #5)
Peter, I'm waiting for Rahul to respond to comment 3. I then plan to approve this.

Comment 7 Peter Lemenkov 2012-02-01 17:43:08 UTC
(In reply to comment #6)
> (In reply to comment #5)
> Peter, I'm waiting for Rahul to respond to comment 3. I then plan to approve
> this.

Ok, understood.

Scott, if anything went wrong, then we would flip roles - I'm willing to review it if you take over this package. I really want to see this in Fedora.

Comment 8 Scott Tsai 2012-02-01 18:31:15 UTC
(In reply to comment #7)
Peter, I've mailed Rahul privately, asking if he has time to look at this or if he'd object to me taking over package submission.

Comment 9 Rahul Sundaram 2012-02-02 00:12:07 UTC
Sorry for the delay folks.  I submitted this review many months back and forgot about it entirely.  Thanks to Scott Tsai for the spec file changes and dropping me a reminder offlist. 

http://sundaram.fedorapeople.org/packages/libwebp.spec
http://sundaram.fedorapeople.org/packages/libwebp-0.1.3-1.fc16.src.rpm

Comment 10 Scott Tsai 2012-02-02 00:22:34 UTC
Successful koji build: http://koji.fedoraproject.org/koji/taskinfo?taskID=3753938

APPROVED.

Comment 11 Rahul Sundaram 2012-02-02 00:48:12 UTC
Thanks.  Looks like it is going to be a dependency for a few packages and if anyone wants to be a co-maintainer, feel free to apply.  I don't expect it to be a big burden. 


New Package SCM Request
=======================
Package Name: libwebp
Short Description: Library and tools for the WebP graphics format
Owners: sundaram
Branches: f17 f16
InitialCC:

Comment 12 Gwyn Ciesla 2012-02-02 02:52:40 UTC
Git done (by process-git-requests).

f17==devel, at least for a week for so yet. . .

Comment 13 Rahul Sundaram 2012-02-02 04:42:23 UTC
@John Ellson,  I have built for Rawhide and Fedora 16 as well.  Do let me know if you need any further help from me.   

https://admin.fedoraproject.org/updates/libwebp-0.1.3-1.fc16

Closing this review request.

Comment 14 John Ellson 2012-02-02 15:39:07 UTC
Just FYI.    At http://www.graphviz.org/ there are new development snapshot rpms of graphviz for fc17 that now include a libwebp plugin (graphviz-webp).   

Thanks for packaging libwebp.   Now its up to me to get a stable release of graphviz posted.

Comment 15 Sandro Mani 2015-03-26 19:38:33 UTC
Package Change Request
======================
Package Name: libwebp
New Branches: el6 epel7
Owners: smani
InitialCC:

Comment 16 Orion Poplawski 2015-03-26 19:47:34 UTC
Note that libwebp is in RHEL7 proper, so no epel branch should be made.  But thanks!

Comment 17 Sandro Mani 2015-03-26 22:12:30 UTC
Oh, ok, thanks for pointing out!

Package Change Request
======================
Package Name: libwebp
New Branches: el6
Owners: smani
InitialCC:

Comment 18 Gwyn Ciesla 2015-03-27 12:30:34 UTC
Git done (by process-git-requests).

Comment 19 Fedora Update System 2015-03-27 18:38:26 UTC
libwebp-0.4.3-1.el6 has been submitted as an update for Fedora EPEL 6.
https://admin.fedoraproject.org/updates/libwebp-0.4.3-1.el6

Comment 20 Fedora Update System 2015-03-27 19:00:52 UTC
libwebp-0.4.3-2.el6 has been submitted as an update for Fedora EPEL 6.
https://admin.fedoraproject.org/updates/libwebp-0.4.3-2.el6

Comment 21 Fedora Update System 2015-04-02 07:38:18 UTC
libwebp-0.4.3-3.el6 has been submitted as an update for Fedora EPEL 6.
https://admin.fedoraproject.org/updates/libwebp-0.4.3-3.el6

Comment 22 Fedora Update System 2015-04-22 05:08:20 UTC
libwebp-0.4.3-3.el6 has been pushed to the Fedora EPEL 6 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.