| Summary: | Review Request: inih - Simple INI file parser library | ||
|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | jfch2222 <jfch> |
| Component: | Package Review | Assignee: | Igor Gnatenko <ignatenko> |
| Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
| Severity: | medium | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | rawhide | CC: | mcepl, mcepl, package-review |
| Target Milestone: | --- | Flags: | ignatenko:
fedora-review+
|
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2016-11-14 12:59:41 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
|
Description
jfch2222
2016-08-30 16:16:57 UTC
New src rpm is https://fedorapeople.org/~jfch2222/inih-36-2.el6.src.rpm Some review hints were integrated into it. Successfuly built on koji http://koji.fedoraproject.org/koji/taskinfo?taskID=15438634 Preliminary review:
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]: 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.
[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.
[x]: Each %files section contains %defattr if rpm < 4.4
[-]: 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.
[-]: 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.
[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]: Package requires other packages for directories it uses.
[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:
[?]: Package has no %clean section with rm -rf %{buildroot} (or
$RPM_BUILD_ROOT)
Package should work even on EL-6
[-]: If the source package does not include license text(s) as a separate
file from upstream, the packager SHOULD query upstream to include it.
[-]: Final provides and requires are sane (see attachments).
[x]: Fully versioned dependency in subpackages if applicable.
Note: No Requires: %{name}%{?_isa} = %{version}-%{release} in inih-
devel
[?]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[-]: Scriptlets must be sane, if used.
[-]: 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.
http://koji.fedoraproject.org/koji/taskinfo?taskID=15438634
[!]: %check is present and all tests pass.
[-]: 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]: 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]: Spec file according to URL is the same as in SRPM.
[x]: Rpmlint is run on debuginfo package(s).
[x]: Rpmlint is run on all installed packages.
Note: There are rpmlint messages (see attachment).
[-]: Large data in /usr/share should live in a noarch subpackage if package
is arched.
Rpmlint
-------
Checking: inih-36-1.el7.centos.x86_64.rpm
inih-devel-36-1.el7.centos.x86_64.rpm
inih-36-1.el7.centos.src.rpm
inih.x86_64: W: incoherent-version-in-changelog 36-1 ['36-1.el7.centos', '36-1.centos']
inih-devel.x86_64: W: no-documentation
3 packages and 0 specfiles checked; 0 errors, 2 warnings.
Rpmlint (debuginfo)
-------------------
Checking: inih-debuginfo-36-1.el7.centos.x86_64.rpm
1 packages and 0 specfiles checked; 0 errors, 0 warnings.
Rpmlint (installed packages)
----------------------------
inih-devel.x86_64: W: no-documentation
inih-debuginfo.x86_64: W: only-non-binary-in-usr-lib
inih.x86_64: W: incoherent-version-in-changelog 36-1 ['36-1.el7.centos', '36-1.centos']
3 packages and 0 specfiles checked; 0 errors, 3 warnings.
Requires
--------
inih-devel (rpmlib, GLIBC filtered):
inih
libinih.so.0()(64bit)
inih (rpmlib, GLIBC filtered):
/sbin/ldconfig
libc.so.6()(64bit)
rtld(GNU_HASH)
Provides
--------
inih-devel:
inih-devel
inih-devel(x86-64)
inih:
inih
inih(x86-64)
libinih.so.0()(64bit)
Source checksums
----------------
https://github.com/benhoyt/inih/archive/r36.tar.gz :
CHECKSUM(SHA256) this package : f1fa09e5369cbe43495150c5b19c6c6ad035f9e83004418686f07918b5e427de
CHECKSUM(SHA256) upstream package : f1fa09e5369cbe43495150c5b19c6c6ad035f9e83004418686f07918b5e427de
Generated by fedora-review 0.6.1 (f03e4e7) last change: 2016-05-02
Command line :/usr/bin/fedora-review -n inih -v -D DISTTAG=epel7 -x CheckOwnDirs
Buildroot used: epel-7-x86_64
Active plugins: Generic, Shell-api, C/C++
Disabled plugins: Java, Python, fonts, SugarActivity, Ocaml, Perl, Haskell, R, PHP
Disabled flags: EXARCH, EPEL5, BATCH, EPEL6
> gcc -shared -o libinih.so.0.%{version} -Wl,-soname,libinih.so.0 ini.o missing %{__global_ldflags} > Source0: https://github.com/benhoyt/inih/archive/r%{version}.tar.gz Source0: %{url}/archive/r%{version}/%{name}-%{version}.tar.gz > %setup -q -n inih-r%{version} %setup -q -n %{name}-r%{version} > %clean > rm -rf %{buildroot} remove this > %defattr(-,root,root,-) remove this * Missing BuildRequires: gcc * Group tag is not needed * Add "-p" to all "install" invocations to preserve timestamp modified to my best. relese is now 3 download is on fedorapeople.org/~jfch2222 Almost good.
--- inih.spec~ 2016-08-31 06:56:31.479004801 +0200
+++ inih.spec 2016-08-31 07:04:53.338189890 +0200
@@ -1,3 +1,5 @@
+%global sover 0
+
Name: inih
Version: 36
Release: 3%{?dist}
@@ -5,7 +7,7 @@
License: BSD
URL: https://github.com/benhoyt/inih
-Source0: https://github.com/benhoyt/inih/archive/r%{version}/%{name}-r%{version}.tar.gz
+Source0: %{url}/archive/r%{version}/%{name}-r%{version}.tar.gz
BuildRequires: gcc
@@ -35,32 +37,25 @@
%build
gcc -c -fPIC %{optflags} ini.c
-gcc -shared %{?__global_ldflags} -o libinih.so.0.%{version} -Wl,-soname,libinih.so.0 ini.o
-
+gcc -shared %{?__global_ldflags} -o libinih.so.%{sover}.%{version} -Wl,-soname,libinih.so.%{sover} ini.o
%install
-mkdir -p %{buildroot}%{_libdir}
-mkdir -p %{buildroot}%{_includedir}
-install -p -m 644 ini.h %{buildroot}%{_includedir}/ini.h
-install -p -m 755 libinih.so* %{buildroot}%{_libdir}
-ln -s libinih.so.0.%{version} %{buildroot}%{_libdir}/libinih.so.0
-ln -s libinih.so.0.%{version} %{buildroot}%{_libdir}/libinih.so
-
+install -D -p -m 0644 ini.h %{buildroot}%{_includedir}/ini.h
+install -D -p -m 0755 lib%{name}.so.%{sover}.%{version} %{buildroot}%{_libdir}/lib%{name}.so.%{sover}.%{version}
+ln -s lib%{name}.so.%{sover}.%{version} %{buildroot}%{_libdir}/lib%{name}.so.%{sover}
+ln -s lib%{name}.so.%{sover}.%{version} %{buildroot}%{_libdir}/lib%{name}.so
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
-
%files
-%doc README.md LICENSE.txt
-%{_libdir}/libinih.so.0.%{version}
-%{_libdir}/libinih.so.0
-
+%license LICENSE.txt
+%doc README.md
+%{_libdir}/lib%{name}.so.%{sover}*
%files devel
%{_includedir}/ini.h
-%{_libdir}/libinih.so
-
+%{_libdir}/lib%{name}.so
%changelog
* Tue Aug 30 2016 Jan F. Chadima <jfch> - 36-3
You can simplify spec as written above. though marking license by %license is not optional.
Almost all done but %license tag causes local compilation fail. Looking at other rawhide srpms I didn't see it anywhere. (In reply to jfch2222 from comment #7) > Almost all done but %license tag causes local compilation fail. > Looking at other rawhide srpms I didn't see it anywhere. $ find -type f -name '*.spec' | xargs grep "^%license" ./hawkey/hawkey.spec:%license COPYING ./vte291/vte291.spec:%license COPYING ./python-iniparse/python-iniparse.spec:%license LICENSE LICENSE-PSF ./python-docker-squash/python-docker-squash.spec:%license LICENSE ./python-xunitparser/python-xunitparser.spec:%license LICENSE [snip] There is some guidelines about that. Though it fails only on EL6 I guess. https://fedoraproject.org/wiki/Packaging:LicensingGuidelines https://fedoraproject.org/wiki/EPEL:Packaging#Previously_required_boilerplate As a workaround you can add into beginning of spec: %if 0%{?rhel} && 0%{?rhel} <= 6 %{!?_licensedir:%global license %%doc} %endif and it will start working. > 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 must be included in %license.
implemented %license now release is 5 Package request has been approved: https://admin.fedoraproject.org/pkgdb/package/rpms/inih |