Bug 1352667 - Review Request: licensecheck - Simple license checker for source files
Summary: Review Request: licensecheck - Simple license checker for source files
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: gil cattaneo
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1352666
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-07-04 15:53 UTC by Sandro Mani
Modified: 2016-07-07 09:11 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-07-07 09:11:49 UTC
Type: ---
Embargoed:
puntogil: fedora-review+


Attachments (Terms of Use)

Description Sandro Mani 2016-07-04 15:53:58 UTC
Spec URL: https://smani.fedorapeople.org/review/licensecheck.spec
SRPM URL: https://smani.fedorapeople.org/review/licensecheck-3.0.1-1.fc25.src.rpm
Description: Simple license checker for source files
Fedora Account System Username: smani

Comment 1 Parag AN(पराग) 2016-07-04 15:58:57 UTC
how is this different than existing 
$ rpm -qf /usr/bin/licensecheck 
devscripts-minimal-2.16.5-1.fc24.x86_64

Comment 2 Sandro Mani 2016-07-04 16:00:14 UTC
You beat me, I'm writing a fedora-devel post right now to explain that devscripts-2.16.6 removed licensecheck and it lives in this package now. Details on -devel shortly.

Comment 3 gil cattaneo 2016-07-04 16:16:40 UTC
have time for this https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=1346382 ?

Comment 4 gil cattaneo 2016-07-04 17:01:45 UTC
Package Review
==============

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


Issues:
=======
- 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
- 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.
  Note: License file licensecheck is not marked as %license
  See:
  http://fedoraproject.org/wiki/Packaging/LicensingGuidelines#License_Text


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

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.
[!]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "LGPL (unversioned/unknown version)", "Artistic (v2.0)", "GPL
     (v2) (with incorrect FSF address)", "LLGPL", "LGPL (v2.1)", "ISC",
     "GPL (v1 or later)", "Public domain", "CDDL", "GPL (v3 or later)",
     "AFL-3.0", "BSL", "LGPL (v3 or later)", "Beerware", "BSD", "BSD (2
     clause)", "EPL-1.0", "GPL (v3)", "Artistic (v1.0)", "Apache (v2.0)",
     "FreeType", "GPL (v2 or later)", "MIT/X11 (BSD like)", "MPL (v1.1)",
     "BSD (3 clause)", "Public domain GPL (v3)", "Unknown or generated",
     "GPL (v2)", "LGPL (v2 or v3)", "GPL (unversioned/unknown version)",
     "MPL (v2.0)", "LGPL (v2.1 or v3)". 13 files have unknown license.
     Detailed output of licensecheck in
     /home/gil/1352667-licensecheck/licensecheck.txt

    These source files are without license headers:
    App-Licensecheck-v3.0.1/bin/licensecheck
    App-Licensecheck-v3.0.1/lib/App/Licensecheck.pm
    Please, ask to upstream to confirm the
    licensing of code and/or content/s, and ask to add license headers
    https://fedoraproject.org/wiki/Packaging:LicensingGuidelines?rd=Packaging/LicensingGuidelines#License_Clarification

[?]: Package does not own files or directories owned by other packages.
     Note: Dirs in package are owned also by: /usr/share/bash-
     completion(kmod, dnf, cmake, rpmdevtools, python-pip, mercurial, bash-
     completion, subversion, rpmlint, yum, python3-pip, fedpkg, source-
     highlight, glib2, git-core), /usr/share/bash-
     completion/completions(kmod, dnf, cmake, rpmdevtools, python-pip,
     mercurial, firewalld, libappstream-glib, subversion, rpmlint, yum,
     bash-completion, python3-pip, fedpkg, source-highlight, glib2, git-
     core), /usr/share/perl5/vendor_perl/App(perl-Test-Harness, perl-CPAN)
[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.
[-]: Development files must be in a -devel package
[x]: Package uses nothing in %doc for runtime.
[ ]: Package consistently uses macros (instead of hard-coded directory
     names).
[x]: Package is named according to the Package Naming Guidelines.
[?]: 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]: 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 2 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]: Rpmlint is run on all rpms the build produces.
     Note: There are rpmlint messages (see attachment).
[x]: Package requires other packages for directories it uses.
[x]: Package must own all directories that it creates.
[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
     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

Perl:
[x]: Package contains the mandatory BuildRequires and Requires:.
[x]: CPAN urls should be non-versioned.

===== 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]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[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.
[x]: %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:
[!]: Rpmlint is run on all installed packages.
     Note: Mock build failed
     See: http://fedoraproject.org/wiki/Packaging/Guidelines#rpmlint
[x]: Spec file according to URL is the same as in SRPM.


Installation errors
-------------------
INFO: mock.py version 1.2.18 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
Mock Version: 1.2.18
INFO: Mock Version: 1.2.18
Finish: chroot init
INFO: installing package(s): /home/gil/1352667-licensecheck/results/licensecheck-3.0.1-1.fc25.noarch.rpm
ERROR: Command failed. See logs for output.
 # /usr/bin/dnf --installroot /var/lib/mock/fedora-rawhide-i386/root/ --releasever 25 --disableplugin=local --setopt=deltarpm=false install /home/gil/1352667-licensecheck/results/licensecheck-3.0.1-1.fc25.noarch.rpm --setopt=tsflags=nocontexts


Rpmlint
-------
Checking: licensecheck-3.0.1-1.fc25.noarch.rpm
          licensecheck-3.0.1-1.fc25.src.rpm
licensecheck.noarch: E: non-standard-executable-perm /usr/bin/licensecheck 555
2 packages and 0 specfiles checked; 1 errors, 0 warnings.




Requires
--------
licensecheck (rpmlib, GLIBC filtered):
    /usr/bin/perl
    perl(:MODULE_COMPAT_5.24.0)
    perl(:VERSION)
    perl(App::Licensecheck)
    perl(Encode)
    perl(Fcntl)
    perl(Getopt::Long)
    perl(Moo)
    perl(Path::Tiny)
    perl(Pod::Constants)
    perl(Pod::Usage)
    perl(String::Escape)
    perl(Try::Tiny)
    perl(Type::Utils)
    perl(Types::Common::Numeric)
    perl(Types::Standard)
    perl(autodie)
    perl(charnames)
    perl(namespace::clean)
    perl(strictures)
    perl(utf8)
    perl(version)
    perl(warnings)



Provides
--------
licensecheck:
    licensecheck
    perl(App::Licensecheck)



Source checksums
----------------
https://cpan.metacpan.org/authors/id/J/JO/JONASS/App-Licensecheck-v3.0.1.tar.gz :
  CHECKSUM(SHA256) this package     : 7e2326d577f0dd7d062736e7fe426780d49827bea49a65ab1854f5ad8f3a9749
  CHECKSUM(SHA256) upstream package : 7e2326d577f0dd7d062736e7fe426780d49827bea49a65ab1854f5ad8f3a9749


Generated by fedora-review 0.6.1 (f03e4e7) last change: 2016-05-02
Command line :/usr/bin/fedora-review -b 1352667 --plugins Perl -m fedora-rawhide-i386 -L ~/1352666-perl-Pod-Constants/dependencies/perl-Pod-Constants-0.18-1.fc25.noarch.rpm
Buildroot used: fedora-rawhide-i386
Active plugins: Generic, Shell-api, Perl
Disabled plugins: Java, C/C++, Python, fonts, SugarActivity, Ocaml, Haskell, R, PHP
Disabled flags: EXARCH, DISTTAG, EPEL5, BATCH, EPEL6

Built with local dependencies:

Comment 5 gil cattaneo 2016-07-04 17:03:39 UTC
Issues (non blocking):

[!]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "LGPL (unversioned/unknown version)", "Artistic (v2.0)", "GPL
     (v2) (with incorrect FSF address)", "LLGPL", "LGPL (v2.1)", "ISC",
     "GPL (v1 or later)", "Public domain", "CDDL", "GPL (v3 or later)",
     "AFL-3.0", "BSL", "LGPL (v3 or later)", "Beerware", "BSD", "BSD (2
     clause)", "EPL-1.0", "GPL (v3)", "Artistic (v1.0)", "Apache (v2.0)",
     "FreeType", "GPL (v2 or later)", "MIT/X11 (BSD like)", "MPL (v1.1)",
     "BSD (3 clause)", "Public domain GPL (v3)", "Unknown or generated",
     "GPL (v2)", "LGPL (v2 or v3)", "GPL (unversioned/unknown version)",
     "MPL (v2.0)", "LGPL (v2.1 or v3)". 13 files have unknown license.
     Detailed output of licensecheck in
     /home/gil/1352667-licensecheck/licensecheck.txt

    These source files are without license headers:
    App-Licensecheck-v3.0.1/bin/licensecheck
    App-Licensecheck-v3.0.1/lib/App/Licensecheck.pm
    Please, ask to upstream to confirm the
    licensing of code and/or content/s, and ask to add license headers
    https://fedoraproject.org/wiki/Packaging:LicensingGuidelines?rd=Packaging/LicensingGuidelines#License_Clarification

- Permissions on files are set properly.
  Note: See rpmlint output
  See: http://fedoraproject.org/wiki/Packaging/Guidelines#FilePermissions
licensecheck.noarch: E: non-standard-executable-perm /usr/bin/licensecheck 555

Comment 6 gil cattaneo 2016-07-04 17:06:50 UTC
maybe you should add also App-Licensecheck-v3.0.1/COPYRIGHT to %license macro

Comment 7 Sandro Mani 2016-07-05 07:36:52 UTC
COPYRIGHT refers to the files as they are located in the source tarball and I don't think it makes sense to ship with the installed package. I've raised the point about adding license headers to bin/licensecheck and lib/App/Licensecheck.pm upstream: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=829667.

Comment 8 gil cattaneo 2016-07-05 09:04:27 UTC
Thanks, approved
if want take my bug quoted in the Comment#3 i would be grateful

Comment 9 Sandro Mani 2016-07-05 09:06:48 UTC
Thanks.
I'll look at #1346382.

Comment 10 Gwyn Ciesla 2016-07-05 16:20:59 UTC
Package request has been approved: https://admin.fedoraproject.org/pkgdb/package/rpms/licensecheck


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