Bug 1735562 - Review Request: perl-CommonMark - Interface to the CommonMark C library
Summary: Review Request: perl-CommonMark - Interface to the CommonMark C library
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Petr Pisar
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-08-01 05:37 UTC by Emmanuel Seyman
Modified: 2019-08-02 08:39 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2019-08-01 20:33:22 UTC
Type: ---
Embargoed:
ppisar: fedora-review+


Attachments (Terms of Use)

Description Emmanuel Seyman 2019-08-01 05:37:31 UTC
Spec URL: http://people.parinux.org/~seyman/fedora/perl-CommonMark/perl-CommonMark.spec
SRPM URL: http://people.parinux.org/~seyman/fedora/perl-CommonMark/perl-CommonMark-0.290000-1.fc30.src.rpm
Description:
This module is a wrapper around the official CommonMark C library libcmark.
It closely follows the original API.

Fedora Account System Username: eseyman
Rpmlint Output:
perl-CommonMark.src: W: spelling-error %description -l en_US libcmark -> millibar
1 packages and 1 specfiles checked; 0 errors, 1 warnings.

Comment 1 Petr Pisar 2019-08-01 08:06:21 UTC
Url and Source0 addresses are Ok.
Source0 archive (SHA-256: a501b4c3ef6ca89f8703f9ed0b2dc0da878281f2b1277a7ec92902e088c2eadd) is original. Ok.
Summary verified from lib/CommonMark.pod. Ok.
Description verified from lib/CommonMark.pod. Ok.
License verified from lib/CommonMark/Iterator.pod, lib/CommonMark/Parser.pod, lib/CommonMark/Node.pod, lib/CommonMark.pod, Makefile.PL, README.pod, and LICENSE. Ok.

TODO: Either call make program by an absolute path, or do not call perl by absolute path. This is inconsistent.
TODO: Use %{make_build} and %{make_install} macros instead of "make" and "make pure_install".
TODO: Do not perform AUTHOR's tests. These are intended for maintainer only are in fragile. FPC considers banning them.

FIX: Remove version constraint from perl-interpreter. The package has an epoch and thus it does not make sense to use it that way.
TODO: Build-require 'perl(:VERSION) >= 5.8' (Makefile.PL:8).

FIX: Constrain 'cmake-devel' dependency with '>= 0.21.0' (Makefile.PL:19).

All tests pass. Ok.

$ rpmlint perl-CommonMark.spec ../SRPMS/perl-CommonMark-0.290000-1.fc31.src.rpm ../RPMS/x86_64/perl-CommonMark-*
perl-CommonMark.src: W: spelling-error %description -l en_US libcmark -> millibar
perl-CommonMark.x86_64: W: spelling-error %description -l en_US libcmark -> millibar
4 packages and 1 specfiles checked; 0 errors, 2 warnings.
rpmlint is Ok.

$ rpm -q -lv -p ../RPMS/x86_64/perl-CommonMark-0.290000-1.fc31.x86_64.rpm 
drwxr-xr-x    2 root     root                        0 Aug  1 09:57 /usr/lib/.build-id
drwxr-xr-x    2 root     root                        0 Aug  1 09:57 /usr/lib/.build-id/73
lrwxrwxrwx    1 root     root                       69 Aug  1 09:57 /usr/lib/.build-id/73/00db58e088bff8459d5ce87fcfb2b5967174e6 -> ../../../../usr/lib64/perl5/vendor_perl/auto/CommonMark/CommonMark.so
drwxr-xr-x    2 root     root                        0 Aug  1 09:57 /usr/lib64/perl5/vendor_perl/CommonMark
-rw-r--r--    1 root     root                     7828 Apr  9 13:14 /usr/lib64/perl5/vendor_perl/CommonMark.pm
-rw-r--r--    1 root     root                     8654 Apr  9 13:14 /usr/lib64/perl5/vendor_perl/CommonMark.pod
-rw-r--r--    1 root     root                     3160 Apr  9 13:14 /usr/lib64/perl5/vendor_perl/CommonMark/Iterator.pod
-rw-r--r--    1 root     root                     6772 Apr  9 13:14 /usr/lib64/perl5/vendor_perl/CommonMark/Node.pod
-rw-r--r--    1 root     root                     1019 Apr  9 13:14 /usr/lib64/perl5/vendor_perl/CommonMark/Parser.pod
drwxr-xr-x    2 root     root                        0 Aug  1 09:57 /usr/lib64/perl5/vendor_perl/auto/CommonMark
-rwxr-xr-x    1 root     root                    36776 Aug  1 09:57 /usr/lib64/perl5/vendor_perl/auto/CommonMark/CommonMark.so
drwxr-xr-x    2 root     root                        0 Aug  1 09:57 /usr/share/doc/perl-CommonMark
-rw-r--r--    1 root     root                     2627 Apr  9 13:14 /usr/share/doc/perl-CommonMark/Changes
drwxr-xr-x    2 root     root                        0 Aug  1 09:57 /usr/share/licenses/perl-CommonMark
-rw-r--r--    1 root     root                    15786 Apr  9 13:14 /usr/share/licenses/perl-CommonMark/LICENSE
-rw-r--r--    1 root     root                     4118 Aug  1 09:57 /usr/share/man/man3/CommonMark.3pm.gz
-rw-r--r--    1 root     root                     2353 Aug  1 09:57 /usr/share/man/man3/CommonMark::Iterator.3pm.gz
-rw-r--r--    1 root     root                     3501 Aug  1 09:57 /usr/share/man/man3/CommonMark::Node.3pm.gz
-rw-r--r--    1 root     root                     1596 Aug  1 09:57 /usr/share/man/man3/CommonMark::Parser.3pm.gz
File layout and permissions is Ok.

$ rpm -q --requires -p ../RPMS/x86_64/perl-CommonMark-0.290000-1.fc31.x86_64.rpm | sort -f | uniq -c
      1 libc.so.6()(64bit)
      1 libc.so.6(GLIBC_2.2.5)(64bit)
      1 libc.so.6(GLIBC_2.4)(64bit)
      1 libcmark.so.0.28.3()(64bit)
      1 libperl.so.5.30()(64bit)
      1 libpthread.so.0()(64bit)
      1 perl(:MODULE_COMPAT_5.30.0)
      1 perl(:VERSION) >= 5.8.0
      1 perl(Exporter)
      1 perl(strict)
      1 perl(warnings)
      1 perl(XSLoader)
      1 rpmlib(CompressedFileNames) <= 3.0.4-1
      1 rpmlib(FileDigests) <= 4.6.0-1
      1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1
      1 rpmlib(PayloadIsZstd) <= 5.4.18-1
      1 rtld(GNU_HASH)
Binary requires are Ok.

$ rpm -q --provides -p ../RPMS/x86_64/perl-CommonMark-0.290000-1.fc31.x86_64.rpm | sort -f | uniq -c
      1 perl(CommonMark) = 0.290000
      1 perl(CommonMark::Node)
      1 perl-CommonMark = 0.290000-1.fc31
      1 perl-CommonMark(x86-64) = 0.290000-1.fc31
Binary provides are Ok.

$ resolvedeps rawhide ../RPMS/x86_64/perl-CommonMark-0.290000-1.fc31.x86_64.rpm 
Binary dependencies are resolvable. Ok.

The package build in F31 (https://koji.fedoraproject.org/koji/taskinfo?taskID=36727796). Ok.

Otherwise the package is in line with Fedora and Perl packaging guide lines.

Please correct the 'FIX' items and consider fixing 'TODO' items before building this package.
Resolution: Package APPROVED.

Comment 2 Gwyn Ciesla 2019-08-01 17:36:05 UTC
(fedscm-admin):  The Pagure repository was created at https://src.fedoraproject.org/rpms/perl-CommonMark

Comment 3 Emmanuel Seyman 2019-08-01 17:42:08 UTC
(In reply to Petr Pisar from comment #1)
> 
> TODO: Either call make program by an absolute path, or do not call perl by
> absolute path. This is inconsistent.
> TODO: Use %{make_build} and %{make_install} macros instead of "make" and
> "make pure_install".

Using %{make_install} makes the build fail:
https://koji.fedoraproject.org/koji/taskinfo?taskID=36738176

I went with "/usr/bin/make pure_install" and replaced "make" with %{make_build}.

> TODO: Do not perform AUTHOR's tests. These are intended for maintainer only
> are in fragile. FPC considers banning them.

Ah, that's news to me. Removed.

> FIX: Remove version constraint from perl-interpreter. The package has an
> epoch and thus it does not make sense to use it that way.
> TODO: Build-require 'perl(:VERSION) >= 5.8' (Makefile.PL:8).

Done.

> FIX: Constrain 'cmake-devel' dependency with '>= 0.21.0' (Makefile.PL:19).

Done.

> Please correct the 'FIX' items and consider fixing 'TODO' items before
> building this package.

Spec URL: http://people.parinux.org/~seyman/fedora/perl-CommonMark/perl-CommonMark.spec
SRPM URL: http://people.parinux.org/~seyman/fedora/perl-CommonMark/perl-CommonMark-0.290000-2.fc30.src.rpm

> Resolution: Package APPROVED.

Thank you for the review, Petr. Repo requested.

Comment 4 Emmanuel Seyman 2019-08-01 20:33:22 UTC
Published for rawhide and f30.

Comment 5 Petr Pisar 2019-08-02 08:34:54 UTC
(In reply to Emmanuel Seyman from comment #3)
> Using %{make_install} makes the build fail:
> https://koji.fedoraproject.org/koji/taskinfo?taskID=36738176
> 
> I went with "/usr/bin/make pure_install" and replaced "make" with
> %{make_build}.
> 
I guess the culprit is the PERL_INSTALL_ROOT argument that should not be there:

Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.P4anEp
[...]
+ /usr/bin/make install DESTDIR=/builddir/build/BUILDROOT/perl-CommonMark-0.290000-1.fc31.arm 'INSTALL=/usr/bin/install -p' PERL_INSTALL_ROOT=/builddir/build/BUILDROOT/perl-CommonMark-0.290000-1.fc31.arm
[...]
Installing /builddir/build/BUILDROOT/perl-CommonMark-0.290000-1.fc31.arm/builddir/build/BUILDROOT/perl-CommonMark-0.290000-1.fc31.arm/usr/lib/perl5/vendor_perl/auto/CommonMark/CommonMark.so

Comment 6 Petr Pisar 2019-08-02 08:39:28 UTC
Indeed. This works:

@@ -38,11 +38,11 @@ It closely follows the original API.
 %setup -q -n CommonMark-%{version}
 
 %build
-/usr/bin/perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="$RPM_OPT_FLAGS" NO_PACKLIST=1
-%{make_build} %{?_smp_mflags}
+/usr/bin/perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="$RPM_OPT_FLAGS" NO_PACKLIST=1 NO_PERLLOCAL=1
+%{make_build}
 
 %install
-/usr/bin/make pure_install PERL_INSTALL_ROOT=$RPM_BUILD_ROOT
+%{make_install}
 %{_fixperms} $RPM_BUILD_ROOT/*


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