Bug 1379165 (libslz) - Review Request: libslz - StateLess Zip
Summary: Review Request: libslz - StateLess Zip
Keywords:
Status: CLOSED ERRATA
Alias: libslz
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Christoph Junghans
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-09-25 16:53 UTC by Dridi Boukelmoune
Modified: 2017-02-28 21:19 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-02-22 17:23:56 UTC
Type: ---
Embargoed:
junghans: fedora-review+


Attachments (Terms of Use)

Description Dridi Boukelmoune 2016-09-25 16:53:56 UTC
Spec URL: https://dridi.fedorapeople.org/review/libslz.spec
SRPM URL: https://dridi.fedorapeople.org/review/libslz-1.1.0-1.fc24.src.rpm
Description:
SLZ is a fast and memory-less stream compressor which produces an output that
can be decompressed with zlib or gzip. It does not implement decompression at
all, zlib is perfectly fine for this.

The purpose is to use SLZ in situations where a zlib-compatible stream is
needed and zlib's resource usage would be too high while the compression ratio
is not critical. The typical use case is in HTTP servers and gateways which
have to compress many streams in parallel with little CPU resources to assign
to this task, and without having to limit the compression ratio due to the
memory usage. In such an environment, the server's memory usage can easily be
divided by 10 and the CPU usage by 3.

Fedora Account System Username: dridi

Comment 1 Dridi Boukelmoune 2016-09-25 17:02:35 UTC
Scratch build: http://koji.fedoraproject.org/koji/taskinfo?taskID=15796124

Comment 2 Christoph Junghans 2016-10-02 15:48:31 UTC
> URL:		http://libslz.org/
Seems to be dead? http://1wt.eu/projects/libslz/
> Source:		libslz-1.1.0.tar.gz
Fix url
http://git.1wt.eu/web?p=libslz.git;a=snapshot;h=afa04ae1f976957cf36287cc5370998d0559bc63;sf=tgz#/libslz-1.1.0.tar.gz

> %doc README LICENSE
%doc README
%license LICENSE

Are there any consumers of the static libs, which cannot use shared? Otherwise drop.

Comment 3 Christoph Junghans 2016-10-02 15:49:30 UTC
> make %{?_smp_mflags} CFLAGS="%{optflags}"
%make_build CFLAGS="%{optflags}"

Comment 4 Dridi Boukelmoune 2016-10-02 16:17:52 UTC
> > URL:		http://libslz.org/
> Seems to be dead?

Quite the opposite, the web site isn't born yet. Upstream's working on it but I put it ahead of time. This is not a widely used project, although it will have its use in Fedora and EPEL with haproxy. I plan to open a bug for that next.

If that's a problem, I'll change the URL and update once it's ready.

> > Source:		libslz-1.1.0.tar.gz
> Fix url

When I initially submitted this package, archives generated from upstream's git-web were non-deterministic and would conflict with our tooling.

Also, once libslz.org is up, source tarball should be published just like I did: a `%{name}-%{version}.tar.gz` archive containing the source tree inside a `%{name}-%{version}/` directory.

> Are there any consumers of the static libs, which cannot use shared? Otherwise drop.

Although I'm against bundling in general, I don't see a reason not to ship the static lib in the devel subpackage. I actually asked haproxy's author (same author) not to expect a static libslz when building against it when we were working on making libslz package-able (there used to be no shared lib).

I will submit a new spec tomorrow, thanks for reviewing!

Comment 5 Christoph Junghans 2016-10-02 21:57:29 UTC
(In reply to Dridi Boukelmoune from comment #4)
> > > URL:		http://libslz.org/
> > Seems to be dead?
> 
> Quite the opposite, the web site isn't born yet. Upstream's working on it
> but I put it ahead of time. This is not a widely used project, although it
> will have its use in Fedora and EPEL with haproxy. I plan to open a bug for
> that next.
I would prefer a url, which works now. You can always change in the next release.

> 
> If that's a problem, I'll change the URL and update once it's ready.
> 
> > > Source:		libslz-1.1.0.tar.gz
> > Fix url
> When I initially submitted this package, archives generated from upstream's
> git-web were non-deterministic and would conflict with our tooling.
> 
> Also, once libslz.org is up, source tarball should be published just like I
> did: a `%{name}-%{version}.tar.gz` archive containing the source tree inside
> a `%{name}-%{version}/` directory.
Actually URL
http://git.1wt.eu/web?p=%{name}.git;a=snapshot;h=v%{version};sf=tgz#/%{name}-%{version}.tar.gz
will work with
%setup -q -n %{name}

> 
> > Are there any consumers of the static libs, which cannot use shared? Otherwise drop.
> 
> Although I'm against bundling in general, I don't see a reason not to ship
> the static lib in the devel subpackage. I actually asked haproxy's author
> (same author) not to expect a static libslz when building against it when we
> were working on making libslz package-able (there used to be no shared lib).
The guideline says "In general, packagers are strongly encouraged not to ship static libs unless a compelling reason exists.", so drop it if haproxy works with shared libs.

> 
> I will submit a new spec tomorrow, thanks for reviewing!

Comment 6 Dridi Boukelmoune 2016-10-03 10:11:13 UTC
Spec URL: https://dridi.fedorapeople.org/review/libslz.spec
SRPM URL: https://dridi.fedorapeople.org/review/libslz-1.1.0-1.fc24.src.rpm

I went ahead and fixed or commented everything you mentioned.

Comment 7 Christoph Junghans 2016-10-03 16:06:01 UTC
> %global _hardened_build 1
Can be dropped this is the default now, see https://fedoraproject.org/wiki/Changes/Harden_All_Packages

> Source:		libslz-1.1.0.tar.gz
Follow https://fedoraproject.org/wiki/Packaging:SourceURL?rd=Packaging/SourceURL#Git_Tags and
use
URL: http://git.1wt.eu/web?p=%{name}.git;a=snapshot;h=v%{version};sf=tgz#/%{name}-%{version}.tar.gz
and
%setup -q -n %{name}
You can always change it once their website is up.

fedora-review throughs an error when installing:
<https://travis-ci.org/junghans/fedora-review/builds/164653787#L3184>
it seems something went wrong with the auto-provide for the shared lib.

Comment 8 Christoph Junghans 2016-10-03 18:00:25 UTC
(In reply to Christoph Junghans from comment #7)
> fedora-review throughs an error when installing:
> <https://travis-ci.org/junghans/fedora-review/builds/164653787#L3184>
> it seems something went wrong with the auto-provide for the shared lib.
Try
%make_build ... LDFLAGS='%__global_ldflags'

Comment 9 Christoph Junghans 2016-10-04 19:05:37 UTC
Thanks to Tom Spura, he pointed out to me that lib*.so.* misses an executable bit, which fixes the above issue, have look here:

Spec URL: http://junghans.github.io/fedora-review/libslz/libslz.spec
SRPM URL: http://junghans.github.io/fedora-review/libslz/libslz-1.1.0-1.fc26.src.rpm
Review.txt: http://junghans.github.io/fedora-review/libslz/review.txt
Build log: https://travis-ci.org/junghans/fedora-review/builds/165023015
Raw Build log: https://s3.amazonaws.com/archive.travis-ci.org/jobs/165023016/log.txt

Comment 10 Dridi Boukelmoune 2016-10-04 21:02:32 UTC
One more thing in the patch set I'll send upstream, good catch. The problem actually lies in the Makefile where chmod explicitly sets 644.

I'll submit an updated spec tomorrow, it may look a lot like yours.

Comment 11 Dridi Boukelmoune 2016-10-06 11:52:39 UTC
Spec URL: https://dridi.fedorapeople.org/review/libslz.spec
SRPM URL: https://dridi.fedorapeople.org/review/libslz-1.1.0-1.fc24.src.rpm

I decided to fix it with a patch instead of the install scriptlet, this way once it's merge upstream it will ftbfs and I can't forget to remove it.

Comment 12 Christoph Junghans 2016-10-07 14:33:08 UTC
> %global _hardened_build 1
Drop, it is the default, see https://fedoraproject.org/wiki/Changes/Harden_All_Packages

> %make_build CFLAGS="%{optflags}"
Add LDFLAGS
%make_build CFLAGS="%{optflags}" LDFLAGS='%__global_ldflags'

Avoid strip
> strip libslz.so.1
Drop
> %make_install PREFIX=%{_prefix} LIBDIR=%{_libdir}
%make_install PREFIX=%{_prefix} LIBDIR=%{_libdir} STRIP=/bin/true

see policy: https://fedoraproject.org/wiki/Packaging:Debuginfo#Useless_or_incomplete_debuginfo_packages_due_to_packaging_issues

Otherwise I am happy.

Comment 13 Dridi Boukelmoune 2017-02-11 11:32:55 UTC
Spec URL: https://dridi.fedorapeople.org/review/libslz.spec
SRPM URL: https://dridi.fedorapeople.org/review/libslz-1.1.0-1.fc25.src.rpm

Hello,

Sorry for the long delay, I'm back with an updated spec. Please note that I'm not disabling strip and that only programs are effectively stripped.

Comment 14 Christoph Junghans 2017-02-12 00:39:39 UTC
(In reply to Dridi Boukelmoune from comment #13)
> Spec URL: https://dridi.fedorapeople.org/review/libslz.spec
> SRPM URL: https://dridi.fedorapeople.org/review/libslz-1.1.0-1.fc25.src.rpm
> 
> Hello,
> 
> Sorry for the long delay, I'm back with an updated spec. Please note that
> I'm not disabling strip and that only programs are effectively stripped.
I would leave the stripping to rpmbuild for a better debug info and run make install with STRIP=/bin/true as suggested in the guideline:
<https://fedoraproject.org/wiki/Packaging:Debuginfo?rd=Packaging/Debuginfo#Useless_or_incomplete_debuginfo_packages_due_to_packaging_issues>
Or do you have a special reason to strip them yourself?

Second minor nitpick, submit your patch upstream (if you haven't done it already) and make a comment in the spec.

Otherwise here is the review:

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

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



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

C/C++:
[-]: Package does not contain kernel modules.
[x]: Package contains no static executables.
[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]: Development (unversioned) .so files in -devel subpackage, if present.

Generic:
[x]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
     Guidelines.
[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "MIT/X11 (BSD like)", "Unknown or generated". 12 files have
     unknown license. Detailed output of licensecheck in /travis/libslz
     /review-libslz/licensecheck.txt
[x]: License file installed when any subpackage combination is installed.
[x]: %build honors applicable compiler flags or justifies otherwise.
[x]: Package contains no bundled libraries without FPC exception.
[x]: 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
     names).
[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.
[x]: 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.
[!]: 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 20480 bytes in 1 files.
[x]: Package complies to the Packaging Guidelines
[x]: Package successfully compiles and builds into binary rpms on at least
     one supported primary architecture.
[x]: Package installs properly.
[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 must own all directories that it creates.
[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]: Permissions on files are set properly.
[x]: Package use %makeinstall only when make install DESTDIR=... doesn't
     work.
[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
     %{name}.spec.
[x]: File names are valid UTF-8.
[x]: Packages must not store files under /srv, /opt or /usr/local

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

Generic:
[-]: 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 libslz-
     debuginfo
[x]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[!]: Patches link to upstream bugs/comments/lists or are otherwise
     justified.
[x]: Scriptlets must be sane, if used.
[x]: 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
     architectures.
[-]: %check is present and all tests pass.
[x]: Packages should try to preserve timestamps of original installed
     files.
[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
     $RPM_BUILD_ROOT)
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file
[x]: Sources can be downloaded from URI in Source: tag
[x]: SourceX is a working URL.
[x]: Spec use %global instead of %define unless justified.

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

Generic:
[x]: Rpmlint is run on debuginfo package(s).
     Note: No rpmlint messages.
[x]: Rpmlint is run on all installed packages.
     Note: There are rpmlint messages (see attachment).
[x]: Large data in /usr/share should live in a noarch subpackage if package
     is arched.
[x]: Spec file according to URL is the same as in SRPM.


Rpmlint
-------
Checking: libslz-1.1.0-1.fc26.x86_64.rpm
          libslz-devel-1.1.0-1.fc26.x86_64.rpm
          libslz-debuginfo-1.1.0-1.fc26.x86_64.rpm
          libslz-1.1.0-1.fc26.src.rpm
libslz.x86_64: W: spelling-error %description -l en_US zlib -> lib, glib, z lib
libslz.x86_64: W: spelling-error %description -l en_US gzip -> zip, grip, g zip
libslz.x86_64: W: spelling-error %description -l en_US zlib's -> lib's, z lib's, Libby's
libslz-devel.x86_64: W: only-non-binary-in-usr-lib
libslz-devel.x86_64: W: no-documentation
libslz-devel.x86_64: W: no-manual-page-for-binary zdec
libslz-devel.x86_64: W: no-manual-page-for-binary zenc
libslz.src: W: spelling-error %description -l en_US zlib -> lib, glib, z lib
libslz.src: W: spelling-error %description -l en_US gzip -> zip, grip, g zip
libslz.src: W: spelling-error %description -l en_US zlib's -> lib's, z lib's, Libby's
libslz.src:13: W: macro-in-comment %{name}
libslz.src:13: W: macro-in-comment %{version}
4 packages and 0 specfiles checked; 0 errors, 12 warnings.




Rpmlint (debuginfo)
-------------------
Checking: libslz-debuginfo-1.1.0-1.fc26.x86_64.rpm
1 packages and 0 specfiles checked; 0 errors, 0 warnings.





Rpmlint (installed packages)
----------------------------
sh: /usr/bin/python: No such file or directory
libslz.x86_64: W: spelling-error %description -l en_US zlib -> lib, glib, z lib
libslz.x86_64: W: spelling-error %description -l en_US gzip -> zip, grip, g zip
libslz.x86_64: W: spelling-error %description -l en_US zlib's -> lib's, z lib's, Libby's
libslz-devel.x86_64: W: only-non-binary-in-usr-lib
libslz-devel.x86_64: W: no-documentation
libslz-devel.x86_64: W: no-manual-page-for-binary zdec
libslz-devel.x86_64: W: no-manual-page-for-binary zenc
3 packages and 0 specfiles checked; 0 errors, 7 warnings.



Requires
--------
libslz-debuginfo (rpmlib, GLIBC filtered):

libslz (rpmlib, GLIBC filtered):
    /sbin/ldconfig
    libc.so.6()(64bit)
    rtld(GNU_HASH)

libslz-devel (rpmlib, GLIBC filtered):
    libc.so.6()(64bit)
    libslz(x86-64)
    libslz.so.1()(64bit)
    rtld(GNU_HASH)



Provides
--------
libslz-debuginfo:
    libslz-debuginfo
    libslz-debuginfo(x86-64)

libslz:
    libslz
    libslz(x86-64)
    libslz.so.1()(64bit)

libslz-devel:
    libslz-devel
    libslz-devel(x86-64)



Source checksums
----------------
http://git.1wt.eu/web?p=libslz.git;a=snapshot;h=v1.1.0;sf=tgz#/libslz-1.1.0.tar.gz :
  CHECKSUM(SHA256) this package     : 93073cbb68b3b77fb4289c3f5550ff466b4e10679fb3ac12bb7d5fe157c42498
  CHECKSUM(SHA256) upstream package : 93073cbb68b3b77fb4289c3f5550ff466b4e10679fb3ac12bb7d5fe157c42498


Generated by fedora-review 0.6.1 (f03e4e7) last change: 2016-05-02
Command line :/usr/bin/fedora-review -v --mock-config fedora-rawhide-x86_64 -n libslz
Buildroot used: fedora-rawhide-x86_64
Active plugins: Generic, Shell-api, C/C++
Disabled plugins: Java, Python, fonts, SugarActivity, Ocaml, Perl, Haskell, R, PHP
Disabled flags: EXARCH, DISTTAG, EPEL5, BATCH, EPEL6

Comment 15 Dridi Boukelmoune 2017-02-12 23:01:14 UTC
Spec URL: https://dridi.fedorapeople.org/review/libslz.spec
SRPM URL: https://dridi.fedorapeople.org/review/libslz-1.1.0-1.fc25.src.rpm

Hello Christoph,

Thank you for your patience, it finally went click. It's not just libraries but any ELF binaries that need to be `not stripped`. I was mislead by binaries being effectively stripped once installed and assumed it was only for libraries [1] somehow. I see that after debuginfo is extracted, the binary is stripped.

I reckon I need to check other packages I maintain to un-strip programs.

Thanks

[1] After a quick check, most libraries are shipped stripped too...

Comment 16 Christoph Junghans 2017-02-13 00:55:39 UTC
Looks good to me now!

Comment 17 Gwyn Ciesla 2017-02-13 14:35:40 UTC
Package request has been approved: https://admin.fedoraproject.org/pkgdb/package/rpms/libslz

Comment 18 Fedora Update System 2017-02-13 17:03:27 UTC
libslz-1.1.0-2.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2017-fdeb7cb901

Comment 19 Fedora Update System 2017-02-13 17:03:36 UTC
libslz-1.1.0-2.el6 has been submitted as an update to Fedora EPEL 6. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-62625ee2aa

Comment 20 Fedora Update System 2017-02-13 17:03:41 UTC
libslz-1.1.0-2.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2017-a02e36c349

Comment 21 Fedora Update System 2017-02-13 17:03:46 UTC
libslz-1.1.0-2.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-ba2ede3701

Comment 22 Fedora Update System 2017-02-13 23:19:42 UTC
libslz-1.1.0-2.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-ba2ede3701

Comment 23 Fedora Update System 2017-02-13 23:50:17 UTC
libslz-1.1.0-2.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-fdeb7cb901

Comment 24 Fedora Update System 2017-02-14 00:54:26 UTC
libslz-1.1.0-2.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-a02e36c349

Comment 25 Fedora Update System 2017-02-14 02:16:32 UTC
libslz-1.1.0-2.el6 has been pushed to the Fedora EPEL 6 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-62625ee2aa

Comment 26 Fedora Update System 2017-02-22 17:23:56 UTC
libslz-1.1.0-2.fc25 has been pushed to the Fedora 25 stable repository. If problems still persist, please make note of it in this bug report.

Comment 27 Fedora Update System 2017-02-22 17:51:28 UTC
libslz-1.1.0-2.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 28 Fedora Update System 2017-02-28 21:17:37 UTC
libslz-1.1.0-2.el6 has been pushed to the Fedora EPEL 6 stable repository. If problems still persist, please make note of it in this bug report.

Comment 29 Fedora Update System 2017-02-28 21:19:22 UTC
libslz-1.1.0-2.el7 has been pushed to the Fedora EPEL 7 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.