Bug 739015 - Review Request: erlang-riak_sysmon - Rate-limiting system_monitor event handler for Riak
Summary: Review Request: erlang-riak_sysmon - Rate-limiting system_monitor event handl...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Michael S.
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 639263
Blocks: 652598
TreeView+ depends on / blocked
 
Reported: 2011-09-16 10:32 UTC by Peter Lemenkov
Modified: 2012-07-01 01:34 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-06-20 00:21:30 UTC
Type: ---
Embargoed:
misc: fedora-review+
gwync: fedora-cvs+


Attachments (Terms of Use)

Description Peter Lemenkov 2011-09-16 10:32:27 UTC
Spec URL: http://peter.fedorapeople.org/erlang-riak_sysmon.spec
SRPM URL: http://peter.fedorapeople.org/erlang-riak_sysmon-1.0.0-1.fc16.src.rpm
Description: Simple OTP app for managing Erlang VM system_monitor event messages.

Comment 1 Peter Lemenkov 2012-05-15 17:55:06 UTC
Lifted NotReady and updated to 1.1.2:

http://peter.fedorapeople.org/erlang-riak_sysmon.spec
http://peter.fedorapeople.org/erlang-riak_sysmon-1.1.2-1.fc18.src.rpm

Koji scratchbuild for F-18:
http://koji.fedoraproject.org/koji/taskinfo?taskID=4079575

rpmlint:

sulaco ~/rpmbuild/SPECS: rpmlint ../RPMS/ppc/erlang-riak_sysmon-1.1.2-1.fc18.ppc.rpm ../SRPMS/erlang-riak_sysmon-1.1.2-1.fc18.src.rpm 
erlang-riak_sysmon.ppc: E: explicit-lib-dependency erlang-stdlib

^^^ this one is a false positive (stdlib as a trigger)

erlang-riak_sysmon.ppc: E: no-binary
erlang-riak_sysmon.ppc: W: only-non-binary-in-usr-lib

^^^ this one is tricky. All erlang packages must be installed into
%{_libdir}/erlang/lib so despite of the fact that some of them contains only
arch-independent data they all must be build as arch-dependent. I plan to fix
than but I wouldn't hold my breath.

erlang-riak_sysmon.src: W: invalid-url Source0: basho-riak_sysmon-1.1.2-0-gaab7706.tar.gz

^^^ blame github for that, not me.

2 packages and 0 specfiles checked; 2 errors, 2 warnings.
sulaco ~/rpmbuild/SPECS:

Comment 2 Michael S. 2012-05-21 13:22:17 UTC
Hi, 

- why is debug package disabled ?
( I assume that's because that's erlang, but in the absence of mention in the draft erlang packaging policy, I prefer to ask )

- lots of stuff are not needed anymore for newer Fedora :

%clean
rm -rf $RPM_BUILD_ROOT

rm -Rf in the beginning of %install

%defattr(-,root,root,-)

BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)

- could you explain how the test fail in koji ( at least, with a comment ? )

otherwise, this seems good, let me start the review.

Comment 3 Michael S. 2012-05-21 14:33:16 UTC
Package Review
==============

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



==== 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 %build honors applicable compiler flags or justifies otherwise.
[x]: MUST All build dependencies are listed in BuildRequires, except for any
     that are listed in the exceptions section of Packaging Guidelines.
[!]: MUST Buildroot is not present
     Note: Buildroot is not needed unless packager plans to package for EPEL5
[x]: MUST Package contains no bundled libraries.
[x]: MUST Changelog in prescribed format.
[!]: MUST Package has no %clean section with rm -rf %{buildroot} (or
     $RPM_BUILD_ROOT)
     Note: Clean is needed only if supporting EPEL
[x]: MUST Sources contain only permissible code or content.
[!]: MUST Each %files section contains %defattr if rpm < 4.4
     Note: defattr(....) present in %files section. This is OK if packaging
     for EPEL5. Otherwise not needed
[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.
[!]: MUST Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
     Note: rm -rf is only needed if supporting EPEL5
[-]: MUST Large documentation files are in a -doc subpackage, if 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.
     Note: Checking patched sources after %prep for licenses. No licenses
     found. Please check the source files for licenses manually.
[!]: MUST Package consistently uses macros (instead of hard-coded directory
     names).
     Note: Using both %{buildroot} and $RPM_BUILD_ROOT
[x]: MUST Package is named according to the Package Naming Guidelines.
[x]: MUST Package does not generate any conflict.
[x]: MUST Package obeys FHS, except libexecdir and /usr/target.
[-]: MUST If the package is a rename of another package, proper Obsoletes and
     Provides are present.
[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.
[x]: MUST Requires correct, justified where necessary.
[x]: MUST Rpmlint is run on all rpms the build produces.
     Note: There are rpmlint messages (see attachment).
[x]: MUST Sources used to build the package match the upstream source, as
     provided in the spec URL.
     Note: Package has no sources or they are generated by developer
[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.
[!]: MUST Useful -debuginfo package or justification otherwise.
[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).
[-]: SHOULD Package functions as described.
[x]: SHOULD Latest version is packaged.
[x]: SHOULD Package does not include license text files separate from
     upstream.
[x]: SHOULD Rpmlint is run on all installed packages.
     Note: There are rpmlint messages (see attachment).
[x]: SHOULD SourceX is a working URL.
[x]: 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.
[!]: 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.

Issues:
[!]: MUST Buildroot is not present
     Note: Buildroot is not needed unless packager plans to package for EPEL5
See: http://fedoraproject.org/wiki/Packaging/Guidelines#BuildRoot_tag
[!]: MUST Package has no %clean section with rm -rf %{buildroot} (or
     $RPM_BUILD_ROOT)
     Note: Clean is needed only if supporting EPEL
See: http://fedoraproject.org/wiki/Packaging/Guidelines#.25clean
[!]: MUST Each %files section contains %defattr if rpm < 4.4
     Note: defattr(....) present in %files section. This is OK if packaging
     for EPEL5. Otherwise not needed
See: http://fedoraproject.org/wiki/Packaging/Guidelines#FilePermissions
[!]: MUST Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
     Note: rm -rf is only needed if supporting EPEL5
See: None
[!]: MUST License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. No licenses
     found. Please check the source files for licenses manually.
See: http://fedoraproject.org/wiki/Packaging/LicensingGuidelines#ValidLicenseShortNames
[!]: MUST Package consistently uses macros (instead of hard-coded directory
     names).
     Note: Using both %{buildroot} and $RPM_BUILD_ROOT
See: http://fedoraproject.org/wiki/Packaging/Guidelines#macros

Rpmlint
-------
Checking: erlang-riak_sysmon-1.1.2-1.fc18.src.rpm
          erlang-riak_sysmon-1.1.2-1.fc18.i686.rpm
erlang-riak_sysmon.src: W: invalid-url Source0: basho-riak_sysmon-1.1.2-0-gaab7706.tar.gz
erlang-riak_sysmon.i686: E: explicit-lib-dependency erlang-stdlib
erlang-riak_sysmon.i686: E: no-binary
erlang-riak_sysmon.i686: W: only-non-binary-in-usr-lib
2 packages and 0 specfiles checked; 2 errors, 2 warnings.


Rpmlint (installed packages)
----------------------------
Cannot parse rpmlint output:
Requires
--------
/var/lib/mock/fedora-rawhide-i386/result/erlang-riak_sysmon-1.1.2-1.fc18.i686.rpm:
    erlang-erts  
    erlang-kernel  
    erlang-stdlib  
    
Provides
--------
/var/lib/mock/fedora-rawhide-i386/result/erlang-riak_sysmon-1.1.2-1.fc18.i686.rpm:
    erlang-riak_sysmon = 1.1.2-1.fc18
    erlang-riak_sysmon(x86-32) = 1.1.2-1.fc18
    


Generated by fedora-review 0.2.0git
External plugins:


So there is some stuff to clean, and I do not know how to test it, I assume there is one simple command line to start the erlang application ?

( again, if this is the same type of command every time, maybe that should be added to the packaging guideline )

Comment 4 Peter Lemenkov 2012-05-22 07:59:39 UTC
First of all thanks for picking this up, Michael!

(In reply to comment #2)
> Hi, 
> 
> - why is debug package disabled ?
> ( I assume that's because that's erlang, but in the absence of mention in
> the draft erlang packaging policy, I prefer to ask )

Yep, that's one of the currrent Erlang shortcomings. Every module must be installed into %{_libdir}/erlang/lib (actually "should" not "must", but otherwise it requires some manual intervention and several changes into application's sources). And since %{_libdir} is arch-dependent the entire package becomes arch-dependent as well. To suppress useless debuginfo generation we're using "%global debug_package %{nil}" directive at the top of the packages like this.

This definitely looks ugly, and I plan to fix it in the future. Also I apologise for absence of Erlang Packaging Policy - we'll probably come up with something worth to reading before F-19.

> - lots of stuff are not needed anymore for newer Fedora :
> 
> %clean
> rm -rf $RPM_BUILD_ROOT
> 
> rm -Rf in the beginning of %install
> 
> %defattr(-,root,root,-)
> 
> BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)

Actually my primary goal is EL6 (and I'm considering EL5 as well) so I have to keep vintage stuff.

> - could you explain how the test fail in koji ( at least, with a comment ? )

Yep. that was my fault - I didn't realise that I need to start epmd daemon before running tests. Erlang Port Monitor Daemon is a generic service which allows different local and remote Erlang nodes to exchange data. Since this package is exactly about monitoring of data exchange channels then it requires epmd to run. Sorry for that - I provided fixed version:

http://peter.fedorapeople.org/erlang-riak_sysmon.spec
http://peter.fedorapeople.org/erlang-riak_sysmon-1.1.2-2.fc18.src.rpm

Koji scratchbuild for F-18:
http://koji.fedoraproject.org/koji/taskinfo?taskID=4093357

Comment 5 Peter Lemenkov 2012-06-06 09:38:38 UTC
Ping, Michael! :)

Comment 6 Michael S. 2012-06-06 21:00:41 UTC
For some reason, mock complain :
State Changed: end
DEBUG: kill orphans
WARNING: Process ID 4037 still running in chroot. Killing...

I guess that's the %check, you need to kill epmd if you start it :)


For the rest, it seems that you corrected everything

Could you correct the last part about %check, and I will approve it.

Comment 7 Peter Lemenkov 2012-06-07 07:51:31 UTC
(In reply to comment #6)
> For some reason, mock complain :
> State Changed: end
> DEBUG: kill orphans
> WARNING: Process ID 4037 still running in chroot. Killing...
> 
> I guess that's the %check, you need to kill epmd if you start it :)

Good catch, thanks!

* http://peter.fedorapeople.org/erlang-riak_sysmon.spec
* http://peter.fedorapeople.org/erlang-riak_sysmon-1.1.2-3.fc18.src.rpm

Comment 8 Peter Lemenkov 2012-06-10 06:57:44 UTC
Ping again, Michael! :)

Comment 9 Michael S. 2012-06-10 08:25:19 UTC
Seems good to go with the latest modification

Comment 10 Peter Lemenkov 2012-06-10 09:02:38 UTC
Thanks!

New Package SCM Request
=======================
Package Name: erlang-riak_sysmon
Short Description: Rate-limiting system_monitor event handler for Riak
Owners: peter
Branches: f16 f17 el6
InitialCC:

Comment 11 Gwyn Ciesla 2012-06-10 14:14:39 UTC
Git done (by process-git-requests).

Comment 12 Fedora Update System 2012-06-10 17:12:22 UTC
erlang-riak_sysmon-1.1.2-3.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/erlang-riak_sysmon-1.1.2-3.fc16

Comment 13 Fedora Update System 2012-06-10 17:12:30 UTC
erlang-riak_sysmon-1.1.2-3.el6 has been submitted as an update for Fedora EPEL 6.
https://admin.fedoraproject.org/updates/erlang-riak_sysmon-1.1.2-3.el6

Comment 14 Fedora Update System 2012-06-10 17:12:40 UTC
erlang-riak_sysmon-1.1.2-3.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/erlang-riak_sysmon-1.1.2-3.fc17

Comment 15 Fedora Update System 2012-06-12 00:25:29 UTC
erlang-riak_sysmon-1.1.2-3.fc17 has been pushed to the Fedora 17 testing repository.

Comment 16 Fedora Update System 2012-06-20 00:21:30 UTC
erlang-riak_sysmon-1.1.2-3.fc17 has been pushed to the Fedora 17 stable repository.

Comment 17 Fedora Update System 2012-06-20 00:34:45 UTC
erlang-riak_sysmon-1.1.2-3.fc16 has been pushed to the Fedora 16 stable repository.

Comment 18 Fedora Update System 2012-07-01 01:34:52 UTC
erlang-riak_sysmon-1.1.2-3.el6 has been pushed to the Fedora EPEL 6 stable repository.


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