Spec URL: http://t2.unl.edu/sources/libmacaroons.spec SRPM URL: http://t2.unl.edu/sources/libmacaroons-0.3.0-1.el7.src.rpm Description: Macaroons are flexible authorization credentials that support decentralized delegation, attenuation, and verification. They provide a power and lightweight mechanism for generating bearer tokens and were first described by Google researchers in 2014 (https://ai.google/research/pubs/pub41892). libmacaroons is a flexible C library for creating, manipulating, and verify these tokens. I am working to use it as a dependency in a different project (Xrootd) for authentication tokens, meaning it would be quite useful if we can have it in Fedora/EPEL and avoid embedded sources. The packaging is relatively simple (I enabled the Python bindings) and it appears functional. I have run rpmlint against the spec file, SRPM, and binary RPMs and see no glaring errors or blockers. Fedora Account System Username: bbockelm
- Group: is not used in Fedora - BuildRequires: python-devel is deprecated. Use: BuildRequires: python2-devel - %package -n python2-macaroons should include the python provide: %{?python_provide:%python_provide python2-macaroons} - make %{?_smp_mflags} → %make_build - make install DESTDIR=%{buildroot} → %make_install - Instead of: %post -p /sbin/ldconfig %postun -p /sbin/ldconfig Use: %ldconfig_scriptlets See https://fedoraproject.org/wiki/Changes/Removing_ldconfig_scriptlets#Upgrade.2Fcompatibility_impact - You must install the LICENSE file in %files: %files %license LICENSE %{_libdir}/%{name}.so.* - The Requires should include %{?_isa} %package devel Summary: Development libraries linking against libmacaroons Requires: %{name}%{?_isa} = %{version}-%{release} - Simplify Source/URL URL: https://github.com/rescrv/libmacaroons Source0: %url/archive/releases/%{version}/%{name}-%{version}.tar.gz - Add a comment above the patch to explain what it's for
- Add README to %doc - Python 2 will be EOL soon, is there no Python 3 package?
Robert, many thanks for the review! It seems that I must be using an older version of rpmlint... will correct these as soon as I can. That said, for these two items: - python2-devel - ldconfig_scriptlets I am planning to submit this for EPEL7, where these don't apply (or, rather, don't work). How should I proceed? Apply the fixes for Fedora then later revert them for EPEL support? For Python3 support: my understanding is that Python3 support is available in the upstream master but not part of any released code. I'm reluctant to maintain a backport of the python3 code myself.
(In reply to Brian Bockelman from comment #3) > Robert, many thanks for the review! It seems that I must be using an older > version of rpmlint... will correct these as soon as I can. > > That said, for these two items: > - python2-devel > - ldconfig_scriptlets > > I am planning to submit this for EPEL7, where these don't apply (or, rather, > don't work). How should I proceed? Apply the fixes for Fedora then later > revert them for EPEL support? > > For Python3 support: my understanding is that Python3 support is available > in the upstream master but not part of any released code. I'm reluctant to > maintain a backport of the python3 code myself. %ldconfig_scriptlets works on EPEL. See https://src.fedoraproject.org/rpms/epel-rpm-macros/c/8c54d820ba193370a39e1547472163f1e0fd67ef python2-devel does work on EPEL (it's a shim for python-devel but it's easier to have the same for both Fedora and EPEL).
Ah, I see that our local mirror has an outdated version of epel-rpm-macros. That explains the missing ldconfig_scriptlets. Ok, I can fix these too.
Ok, I have uploaded the revised spec file and SRPM to the original URLs: Spec URL: http://t2.unl.edu/sources/libmacaroons.spec SRPM URL: http://t2.unl.edu/sources/libmacaroons-0.3.0-1.el7.src.rpm Robert, I believe I have addressed all of your review suggestions. Please let me know if there was something I overlooked
(In reply to Brian Bockelman from comment #6) > Ok, I have uploaded the revised spec file and SRPM to the original URLs: > > Spec URL: http://t2.unl.edu/sources/libmacaroons.spec > SRPM URL: http://t2.unl.edu/sources/libmacaroons-0.3.0-1.el7.src.rpm > > Robert, I believe I have addressed all of your review suggestions. Please > let me know if there was something I overlooked The %{?_isa} part is for the -devel package which is arched, not the python2 one which is noarch: %package -n python2-macaroons Summary: Python 2 bindings for libmacaroons Requires: %{name} = %{version}-%{release} %{?python_provide:%python_provide python2-macaroons} %description -n python2-macaroons %{summary} %package devel Summary: Development libraries linking against libmacaroons Requires: %{name}%{?_isa} = %{version}-%{release} - Simplify Source: URL: https://github.com/rescrv/libmacaroons Source0: %url/archive/releases/%{version}/%{name}-%{version}.tar.gz → notice the first tar.gz is removed - Build error: checking for the distutils Python package... no BUILDSTDERR: configure: error: cannot import Python module "distutils". Add before %configure: export PYTHON=/usr/bin/python2 to force Python2 detection. Package Review ============== Legend: [x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated [ ] = Manual review needed ===== MUST items ===== C/C++: [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]: Package does not contain any libtool archives (.la) [x]: Rpath absent or only used for internal libs. 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: "BSD (3 clause)", "ISC", "GPL (v3 or later)", "Unknown or generated". 10 files have unknown license. Detailed output of licensecheck in /home/bob/packaging/review/libmacaroons/review- libmacaroons/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. [-]: 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 40960 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]: 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 python2-macaroons [?]: Package functions as described. [x]: Latest version is packaged. [x]: Package does not include license text files separate from upstream. [x]: Patches link to upstream bugs/comments/lists or are otherwise justified. [-]: 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]: The placement of pkgconfig(.pc) files are correct. [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]: Package should not use obsolete m4 macros [x]: Spec file according to URL is the same as in SRPM. Rpmlint ------- Checking: libmacaroons-0.3.0-1.fc29.x86_64.rpm python2-macaroons-0.3.0-1.fc29.x86_64.rpm libmacaroons-devel-0.3.0-1.fc29.x86_64.rpm libmacaroons-debuginfo-0.3.0-1.fc29.x86_64.rpm libmacaroons-debugsource-0.3.0-1.fc29.x86_64.rpm libmacaroons-0.3.0-1.fc29.src.rpm python2-macaroons.x86_64: W: no-documentation libmacaroons-devel.x86_64: W: no-documentation 6 packages and 0 specfiles checked; 0 errors, 2 warnings.
Alright, latest version: - Adds isa dependency to -devel subpackage. Note that the python package is arch-specific as it's an extension module. - Second attempt to fix the Source. I think I got it right this time. Didn't know GitHub could do that! - Added "export PYTHON=..." to the build. Double-checked build on both RHEL7 and FC28 this time. Spec file and source RPM URL remain unchanged.
Perfect, package approved.
(fedscm-admin): The Pagure repository was created at https://src.fedoraproject.org/rpms/libmacaroons
Package has been successfully built into rawhide. Closing out ticket with resolution 'rawhide'.