Bug 1285338 - Review Request: openh264 - H.264 codec library
Review Request: openh264 - H.264 codec library
Product: Fedora
Classification: Fedora
Component: Package Review (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Antonio Trande
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2015-11-25 07:24 EST by Kalev Lember
Modified: 2015-11-30 13:08 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2015-11-30 13:08:06 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
anto.trande: fedora‑review+

Attachments (Terms of Use)

  None (edit)
Description Kalev Lember 2015-11-25 07:24:55 EST
Spec URL: https://kalev.fedorapeople.org/openh264.spec
SRPM URL: https://kalev.fedorapeople.org/openh264-1.5.2-0.1.git21e44bd.fc24.src.rpm

This is the patent-encumbered open source H.264 codec from http://www.openh264.org/. We are going to import the sources in Fedora git, but not do any publicly visible builds. The resulting binaries are going to be distributed by Cisco instead. Please see https://fedorahosted.org/fesco/ticket/1496 for the background.

Fedora Account System Username: kalev



This is a special package where we are not allowed to distribute the resulting binaries. Please do not do scratch builds in koji with this package. If you accidentally do so, please contact #fedora-releng immediately to have the builds manually deleted from koji.
Comment 1 Antonio Trande 2015-11-25 08:17:59 EST
Just two questions: 

will this codec available and freely usable in Fedora?
How i can use it in fork project like Icecat?
Comment 2 Kalev Lember 2015-11-25 08:24:27 EST
The plan is to have Cisco ship a repo with the binaries and on Fedora side, we'd just include a .repo file that points to the Cisco hosted content.

As for Icecat support, I suspect it would be trivial to support it. Needs someone to try this though :)
Comment 3 Kalev Lember 2015-11-25 08:30:52 EST
I also have gstreamer openh264 codec packaging here, if anyone is interested in trying it: https://kalev.fedorapeople.org/gstreamer1-plugin-openh264.spec + gstreamer1-plugin-openh264-1.6.1-1.fc24.src.rpm

Let's do one thing at a time though and get the base library and the Mozilla support in first and then see what to do with gstreamer support. It could be that due to the way the openh264 library is going to get built, we might not be able to build anything against it and we'd instead have to work this around by merging the openh264 and gstreamer1-plugin-openh264 packages together into one srpm. I'll discuss with releng to see which way is feasible.
Comment 4 Antonio Trande 2015-11-25 11:40:14 EST
- Library is not full RELRO
  Not all compiler/linker flags are passed

$ checksec --file ./libopenh264.so.1
Partial RELRO - Canary found - NX enabled - DSO - No RPATH - No RUNPATH   ./libopenh264.so.1

- incoherent-version-in-changelog 1.5.0-1 ['1.5.2-0.1.git21e44bd.fc24', '1.5.2-0.1.git21e44bd']

- 'non-standard-executable-perm' is a false positive

- shlib-with-non-pic-code /usr/lib/libopenh264.so.1
  This is related to the first point, i think.

- Please, fix the error

non-standard-executable-perm /usr/lib/mozilla/plugins/gmp-gmpopenh264/system-installed/libgmpopenh264.so.1 775

Package Review

[x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated
[ ] = Manual review needed

- Package installs properly.
  Note: Installation errors (see attachment)
  See: https://fedoraproject.org/wiki/Packaging:Guidelines
- Permissions on files are set properly.
  Note: See rpmlint output
  See: http://fedoraproject.org/wiki/Packaging/Guidelines#FilePermissions

===== MUST items =====

[x]: Package does not contain kernel modules.
[x]: Package contains no static executables.
[x]: Development (unversioned) .so files in -devel subpackage, if present.
     Note: Unversioned so-files in private %_libdir subdirectory (see
     attachment). Verify they are not in ld path.
[x]: Header files in -devel subpackage, if present.
[x]: ldconfig called in %post and %postun if required.
[x]: Package does not contain any libtool archives (.la)
[x]: Rpath absent or only used for internal libs.

[x]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "Apache (v2.0)", "BSD (2 clause)", "*No copyright* MPL (v2.0)",
     "Unknown or generated", "BSD (3 clause)". 349 files have unknown
     license. Detailed output of licensecheck in
[x]: License file installed when any subpackage combination is installed.
[x]: Package must own all directories that it creates.
     Note: Directories without known owners: /etc/profile.d,
     /usr/lib/mozilla, /usr/lib/mozilla/plugins

*Directories owned by mozilla-filesystem

[!]: %build honors applicable compiler flags or justifies otherwise.
[x]: Package contains no bundled libraries without FPC exception.
[!]: Changelog in prescribed format.
[x]: Sources contain only permissible code or content.
[-]: Package contains desktop file if it is a GUI application.
[x]: Development files must be in a -devel package
[x]: Package uses nothing in %doc for runtime.
[x]: Package consistently uses macros (instead of hard-coded directory
[x]: Package is named according to the Package Naming Guidelines.
[x]: Package does not generate any conflict.
[x]: Package obeys FHS, except libexecdir and /usr/target.
[-]: If the package is a rename of another package, proper Obsoletes and
     Provides are present.
[x]: Requires correct, justified where necessary.
[x]: Spec file is legible and written in American English.
[-]: Package contains systemd file(s) if in need.
[x]: Useful -debuginfo package or justification otherwise.
[x]: Package is not known to require an ExcludeArch tag.
[-]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 10240 bytes in 1 files.
[!]: Package complies to the Packaging Guidelines
[x]: Package successfully compiles and builds into binary rpms on at least
     one supported primary architecture.
[x]: Rpmlint is run on all rpms the build produces.
     Note: There are rpmlint messages (see attachment).
[x]: 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 %license.
[x]: Package requires other packages for directories it uses.
[x]: Package does not own files or directories owned by other packages.
[x]: All build dependencies are listed in BuildRequires, except for any
     that are listed in the exceptions section of Packaging Guidelines.
[x]: Package uses either %{buildroot} or $RPM_BUILD_ROOT
[x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
[x]: Macros in Summary, %description expandable at SRPM build time.
[x]: Dist tag is present.
[x]: Package does not contain duplicates in %files.
[x]: Package use %makeinstall only when make install DESTDIR=... doesn't
[x]: Package is named using only allowed ASCII characters.
[x]: Package does not use a name that already exists.
[x]: Package is not relocatable.
[x]: Sources used to build the package match the upstream source, as
     provided in the spec URL.
[x]: Spec file name must match the spec package %{name}, in the format
[x]: File names are valid UTF-8.
[x]: Packages must not store files under /srv, /opt or /usr/local

===== SHOULD items =====

[-]: 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]: Final provides and requires are sane (see attachments).
[x]: Fully versioned dependency in subpackages if applicable.
     Note: No Requires: %{name}%{?_isa} = %{version}-%{release} in
[ ]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[x]: Scriptlets must be sane, if used.
[-]: Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.
[x]: Package should compile and build into binary rpms on all supported
[x]: %check is present and all tests pass.
[x]: Packages should try to preserve timestamps of original installed
[x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file
[x]: Sources can be downloaded from URI in Source: tag
[x]: Reviewer should test that the package builds in mock.
[x]: Buildroot is not present
[x]: Package has no %clean section with rm -rf %{buildroot} (or
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: Uses parallel make %{?_smp_mflags} macro.
[x]: The placement of pkgconfig(.pc) files are correct.
[x]: SourceX is a working URL.
[x]: Spec use %global instead of %define unless justified.

===== EXTRA items =====

[!]: Rpmlint is run on all installed packages.
     Note: Mock build failed
     See: http://fedoraproject.org/wiki/Packaging/Guidelines#rpmlint

*This is an unknown problem for me.

[x]: Large data in /usr/share should live in a noarch subpackage if package
     is arched.

Installation errors
INFO: mock.py version 1.2.13 starting (python version = 3.4.3)...
Start: init plugins
INFO: selinux enabled
Finish: init plugins
Start: run
Start: chroot init
INFO: calling preinit hooks
INFO: enabled root cache
INFO: enabled dnf cache
Start: cleaning dnf metadata
Finish: cleaning dnf metadata
INFO: enabled ccache
Mock Version: 1.2.13
INFO: Mock Version: 1.2.13
Finish: chroot init
INFO: installing package(s): /home/sagitter/Downloads/openh264/results/openh264-1.5.2-0.1.git21e44bd.fc24.i686.rpm /home/sagitter/Downloads/openh264/results/openh264-devel-1.5.2-0.1.git21e44bd.fc24.i686.rpm /home/sagitter/Downloads/openh264/results/mozilla-openh264-1.5.2-0.1.git21e44bd.fc24.i686.rpm /home/sagitter/Downloads/openh264/results/openh264-debuginfo-1.5.2-0.1.git21e44bd.fc24.i686.rpm /home/sagitter/Downloads/openh264/results/openh264-debuginfo-1.5.2-0.1.git21e44bd.fc24.i686.rpm
ERROR: Command failed. See logs for output.
 # /usr/bin/dnf --installroot /var/lib/mock/fedora-rawhide-i386/root/ --releasever 24 install /home/sagitter/Downloads/openh264/results/openh264-1.5.2-0.1.git21e44bd.fc24.i686.rpm /home/sagitter/Downloads/openh264/results/openh264-devel-1.5.2-0.1.git21e44bd.fc24.i686.rpm /home/sagitter/Downloads/openh264/results/mozilla-openh264-1.5.2-0.1.git21e44bd.fc24.i686.rpm /home/sagitter/Downloads/openh264/results/openh264-debuginfo-1.5.2-0.1.git21e44bd.fc24.i686.rpm /home/sagitter/Downloads/openh264/results/openh264-debuginfo-1.5.2-0.1.git21e44bd.fc24.i686.rpm --setopt=tsflags=nocontexts

Checking: openh264-1.5.2-0.1.git21e44bd.fc24.i686.rpm
openh264.i686: W: spelling-error Summary(en_US) codec -> codex, code, codes
openh264.i686: W: spelling-error %description -l en_US codec -> codex, code, codes
openh264.i686: W: incoherent-version-in-changelog 1.5.0-1 ['1.5.2-0.1.git21e44bd.fc24', '1.5.2-0.1.git21e44bd']
openh264.i686: E: shlib-with-non-pic-code /usr/lib/libopenh264.so.1
openh264-devel.i686: W: no-documentation
mozilla-openh264.i686: W: spelling-error Summary(en_US) codec -> codex, code, codes
mozilla-openh264.i686: W: spelling-error %description -l en_US codec -> codex, code, codes
mozilla-openh264.i686: W: no-documentation
mozilla-openh264.i686: W: non-conffile-in-etc /etc/profile.d/gmpopenh264.sh
mozilla-openh264.i686: W: devel-file-in-non-devel-package /usr/lib/mozilla/plugins/gmp-gmpopenh264/system-installed/libgmpopenh264.so
mozilla-openh264.i686: E: non-standard-executable-perm /usr/lib/mozilla/plugins/gmp-gmpopenh264/system-installed/libgmpopenh264.so.1 775
openh264.src: W: spelling-error Summary(en_US) codec -> codex, code, codes
openh264.src: W: spelling-error %description -l en_US codec -> codex, code, codes
5 packages and 0 specfiles checked; 2 errors, 11 warnings.

openh264-debuginfo (rpmlib, GLIBC filtered):

openh264 (rpmlib, GLIBC filtered):

mozilla-openh264 (rpmlib, GLIBC filtered):

openh264-devel (rpmlib, GLIBC filtered):





Unversioned so-files
mozilla-openh264: /usr/lib/mozilla/plugins/gmp-gmpopenh264/system-installed/libgmpopenh264.so

Source checksums
https://github.com/cisco/openh264/archive/21e44bda8b45ac85f6ba78e85b3bd37a1beb2a04/openh264-21e44bd.tar.gz :
  CHECKSUM(SHA256) this package     : 97ae284f0b3de32a176de41d9726af6860098d5f9ae14a62472d0aa16990bfed
  CHECKSUM(SHA256) upstream package : 97ae284f0b3de32a176de41d9726af6860098d5f9ae14a62472d0aa16990bfed
https://github.com/mozilla/gmp-api/archive/c5f1d0f3213178818cbfb3e16f31d07328980560/gmp-api-c5f1d0f.tar.gz :
  CHECKSUM(SHA256) this package     : 9f596c0b6dbf3a0e1d97c414f961909b8e71a2f69df3c1638932975c8fddceff
  CHECKSUM(SHA256) upstream package : 9f596c0b6dbf3a0e1d97c414f961909b8e71a2f69df3c1638932975c8fddceff

Generated by fedora-review 0.6.0 (3c5c9d7) last change: 2015-05-20
Command line :/usr/bin/fedora-review -m fedora-rawhide-i386 -rn openh264-1.5.2-0.1.git21e44bd.fc24.src.rpm
Buildroot used: fedora-rawhide-i386
Active plugins: Generic, Shell-api, C/C++
Disabled plugins: Java, Python, fonts, SugarActivity, Ocaml, Perl, Haskell, R, PHP, Ruby
Comment 5 Antonio Trande 2015-11-25 11:41:40 EST
>- 'non-standard-executable-perm' is a false positive 


mozilla-openh264.i686: W: devel-file-in-non-devel-package /usr/lib/mozilla/plugins/gmp-gmpopenh264/system-installed/libgmpopenh264.so

is a false positive.
Comment 6 Kalev Lember 2015-11-26 10:14:48 EST
Thanks Antonio!

* Thu Nov 26 2015 Kalev Lember <klember@redhat.com> - 1.5.2-0.2.git21e44bd
- Pass Fedora LDFLAGS to the build to get full relro

Spec URL: https://kalev.fedorapeople.org/openh264.spec
SRPM URL: https://kalev.fedorapeople.org/openh264-1.5.2-0.2.git21e44bd.fc24.src.rpm
Comment 7 Antonio Trande 2015-11-26 15:39:56 EST
[x]: %build honors applicable compiler flags or justifies otherwise.

Just another thing:

%{_sysconfdir}/profile.d/gmpopenh264.sh shold be marked with %config, i think.
Comment 8 Kalev Lember 2015-11-27 04:54:31 EST
(In reply to Antonio Trande from comment #7)
> [x]: %build honors applicable compiler flags or justifies otherwise.
> Just another thing:
> %{_sysconfdir}/profile.d/gmpopenh264.sh shold be marked with %config, i
> think.

I don't agree here. These aren't meant to be user configurable things; the profile.d scripts just happen to be in /etc because of historical reasons.
Comment 9 Antonio Trande 2015-11-27 05:15:58 EST
Package approved.
Comment 10 Kalev Lember 2015-11-27 16:46:43 EST
Great, thanks for the review!
Comment 11 Till Maas 2015-11-28 17:22:18 EST
Package request has been approved: https://admin.fedoraproject.org/pkgdb/package/openh264
Comment 12 Kalev Lember 2015-11-30 13:08:06 EST
Package imported; thanks again!

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