Bug 5268

Summary: Review request: dptfxtract - Utility to generate a thermald configuration from DPTF
Product: Package Reviews Reporter: Benjamin Berg <benjamin>
Component: Review RequestAssignee: RPM Fusion Package Review <rpmfusion-package-review>
Status: RESOLVED FIXED    
Severity: enhancement CC: leigh123linux, rpmfusion-package-review, vascom2, xavier
Priority: P1 Flags: vascom2: fedora-review+
Version: Current   
Hardware: x86_64   
OS: GNU/Linux   
namespace: nonfree

Description Benjamin Berg 2019-05-17 11:31:15 CEST
spec file: https://benjamin.sipsolutions.net/dptfxtract.spec
SRPM: https://benjamin.sipsolutions.net/dptfxtract-1.3-1.fc30.src.rpm
RPM: https://benjamin.sipsolutions.net/dptfxtract-1.3-1.fc30.x86_64.rpm
Upstream: https://github.com/intel/dptfxtract

Description:

This is a companion tool to Linux Thermal Daemon (thermald). This tool tries to
reuse some of the tables used by "Intel ® Dynamic Platform and Thermal
Framework (Intel® DPTF)" by converting to the thermal_conf.xml format used by
thermald.

Integration with thermald is included so that that a thermald configuration
will be created automatically if thermald is enabled.


This package is not eligible for Fedora as dptfxtract is a non-free executable. The executable is freely distributable.


Note that I have chosen to enable the extraction by default when installed by adding an appropriate symlink for thermald.service.wants.


RPM Lint:
dptfxtract.src: W: spelling-error Summary(en_US) thermald -> thermals, thermal, thermal d
dptfxtract.src: W: spelling-error %description -l en_US thermald -> thermals, thermal, thermal d
dptfxtract.src: W: spelling-error %description -l en_US conf -> con, cone, cons
dptfxtract.src: W: spelling-error %description -l en_US xml -> XML, ml
 -> Wrong reports of spelling errors


dptfxtract.x86_64: W: spelling-error %description -l en_US conf -> con, cone, cons
dptfxtract.x86_64: W: spelling-error %description -l en_US xml -> XML, ml
 -> Wrong reports of spelling errors
dptfxtract.x86_64: W: unstripped-binary-or-object /usr/libexec/dptfxtract
 -> Upstream binary should not be modified

This is my first rpmfusion package.
Comment 1 Vasiliy Glazov 2019-05-17 11:34:18 CEST
thermald orphaned in Fedora and can be removed in next few weeks. First of all someone need to take maintanership of thermald package.
Comment 2 Benjamin Berg 2019-05-17 11:46:50 CEST
I had not realised that yet.

It looks to me like that could be an error, as dbenoit stepped up to maintain it last year and is still listed as a co-maintainer. I'll reach out to David and see what the situation is and may possibly take over maintainership/become co-maintainer of thermald.
Comment 3 Vasiliy Glazov 2019-05-17 12:42:38 CEST
0. Please use %{buildroot} instead of $RPM_BUILD_ROOT. And remove "/" in "/%{_libexecdir}" because this macros already contain it.

1. Remove %clean section.

2. Remove 
install -m 644 COPYING $RPM_BUILD_ROOT/usr/share/doc/dptfxtract/COPYING
install -m 644 README.txt $RPM_BUILD_ROOT/usr/share/doc/dptfxtract/README.txt

and change
%license /usr/share/doc/dptfxtract/COPYING
%doc /usr/share/doc/dptfxtract/README.txt

to
%license COPYING
%doc README.txt
Comment 4 Benjamin Berg 2019-05-17 12:50:47 CEST
Thanks! I update the package with the suggested changes.
Comment 5 Vasiliy Glazov 2019-05-17 13:17:06 CEST
Regenerate SRPM and post link to it.
Comment 6 Benjamin Berg 2019-05-17 13:20:03 CEST
Oh, I updated the files in-place. So the old URL is still valid:

 https://benjamin.sipsolutions.net/dptfxtract-1.3-1.fc30.src.rpm
Comment 7 Vasiliy Glazov 2019-05-17 13:50:20 CEST
No known owner of /usr/lib/systemd/system/thermald.service.wants
Comment 8 Vasiliy Glazov 2019-05-17 13:51:20 CEST
And remove
rm -rf %{buildroot}
from %install section.
Comment 9 Benjamin Berg 2019-05-17 14:17:48 CEST
Done; files on the server have been updated.

I added

%dir %attr(0755,root,root) %{_unitdir}/thermald.service.wants

for the directory.
Comment 10 Vasiliy Glazov 2019-05-17 14:21:02 CEST
Attributes not needed. Remove %attr(0755,root,root)
Comment 11 Vasiliy Glazov 2019-05-17 14:21:52 CEST
Spec now is normal but need wait normalisation situation with thermald.
Comment 12 Benjamin Berg 2019-05-17 14:38:56 CEST
Thanks for the review! I updated everything again.

I'll post a comment here once the thermald situation has been clarified.
Comment 13 Benjamin Berg 2019-05-17 15:34:11 CEST
I am now the owner of the upstream thermald package. It is no longer orphaned at this point.
Comment 14 Benjamin Berg 2019-05-17 18:31:30 CEST
An updated version of thermald is on its way into F30. See:
  https://bodhi.fedoraproject.org/updates/FEDORA-2019-2142259d7d
Comment 15 Benjamin Berg 2019-05-29 18:47:52 CEST
thermald is up to date in Fedora. Is there anything needed from my side at this point?
Comment 16 Vasiliy Glazov 2019-05-29 19:02:16 CEST
Correct spec. And post here updated spec and src.rpm.
Comment 18 Vasiliy Glazov 2019-05-30 08:39:40 CEST
Approved.

Package Review
==============

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


Issues:
=======
- systemd_post is invoked in %post, systemd_preun in %preun, and
  systemd_postun in %postun for Systemd service files.
  Note: Systemd service file(s) in dptfxtract
  See: https://docs.fedoraproject.org/en-US/packaging-
  guidelines/Scriptlets/#_scriptlets


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

Generic:
[!]: 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: "BSD (unspecified)", "Unknown or generated". 3 files have
     unknown license. Detailed output of licensecheck in
     /home/vascom/review-dptfxtract/licensecheck.txt
[-]: %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]: 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.
[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.
[x]: Package contains systemd file(s) if in need.
[!]: Useful -debuginfo package or justification otherwise.
[!]: Package is not known to require an ExcludeArch tag.
[x]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 10240 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 must not depend on deprecated() packages.
[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:
[x]: 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.
[-]: %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]: Package should compile and build into binary rpms on all supported
     architectures.
[x]: Spec use %global instead of %define unless justified.

===== EXTRA items =====

Generic:
[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]: Spec file according to URL is the same as in SRPM.


Rpmlint
-------
Checking: dptfxtract-1.3-1.fc31.x86_64.rpm
          dptfxtract-1.3-1.fc31.src.rpm
dptfxtract.x86_64: W: spelling-error %description -l en_US conf -> con, cone, cons
dptfxtract.x86_64: W: spelling-error %description -l en_US xml -> XML, ml
dptfxtract.x86_64: W: unstripped-binary-or-object /usr/libexec/dptfxtract
dptfxtract.src: W: spelling-error Summary(en_US) thermald -> thermals, thermal, thermal d
dptfxtract.src: W: spelling-error %description -l en_US thermald -> thermals, thermal, thermal d
dptfxtract.src: W: spelling-error %description -l en_US conf -> con, cone, cons
dptfxtract.src: W: spelling-error %description -l en_US xml -> XML, ml
2 packages and 0 specfiles checked; 0 errors, 7 warnings.




Rpmlint (installed packages)
----------------------------
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
	LANGUAGE = (unset),
	LC_ALL = (unset),
	LC_CTYPE = "C.UTF-8",
	LANG = "ru_RU.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
	LANGUAGE = (unset),
	LC_ALL = (unset),
	LC_CTYPE = "C.UTF-8",
	LANG = "ru_RU.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
	LANGUAGE = (unset),
	LC_ALL = (unset),
	LC_CTYPE = "C.UTF-8",
	LANG = "ru_RU.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
sh: /usr/bin/python: No such file or directory
/usr/share/rpmlint/Pkg.py:168: UnicodeWarning: decode() called on unicode string, see https://bugzilla.redhat.com/show_bug.cgi?id=1693751
  s.decode('UTF-8')
dptfxtract.x86_64: W: spelling-error %description -l en_US conf -> con, cone, cons
dptfxtract.x86_64: W: spelling-error %description -l en_US xml -> XML, ml
dptfxtract.x86_64: W: invalid-url URL: https://github.com/intel/dptfxtract <urlopen error [Errno -2] Name or service not known>
dptfxtract.x86_64: W: unstripped-binary-or-object /usr/libexec/dptfxtract
/usr/share/rpmlint/Pkg.py:168: UnicodeWarning: decode() called on unicode string, see https://bugzilla.redhat.com/show_bug.cgi?id=1693751
  s.decode('UTF-8')
1 packages and 0 specfiles checked; 0 errors, 4 warnings.



Source checksums
----------------
https://github.com/intel/dptfxtract/archive/v1.3.tar.gz :
  CHECKSUM(SHA256) this package     : c8efa83a15072a934f8288a19435d9f068ac2f6a1c7e6abbc4e986e199119f26
  CHECKSUM(SHA256) upstream package : c8efa83a15072a934f8288a19435d9f068ac2f6a1c7e6abbc4e986e199119f26


Requires
--------
dptfxtract (rpmlib, GLIBC filtered):
    /bin/sh
    libc.so.6()(64bit)
    libpthread.so.0()(64bit)
    librt.so.1()(64bit)
    rtld(GNU_HASH)
    systemd
    thermald



Provides
--------
dptfxtract:
    dptfxtract
    dptfxtract(x86-64)



Generated by fedora-review 0.7.2 (65d36bb) last change: 2019-04-09
Command line :/usr/bin/fedora-review -u https://bugzilla.rpmfusion.org/show_bug.cgi?id=5268
Buildroot used: fedora-rawhide-x86_64
Active plugins: Generic, Shell-api
Disabled plugins: SugarActivity, C/C++, Java, Ocaml, PHP, Haskell, Perl, Python, fonts, R
Disabled flags: EPEL6, EPEL7, DISTTAG, BATCH, EXARCH
Comment 19 Xavier Bachelot 2019-06-06 16:50:28 CEST
Benjamin, as this is your first package, you need to be sponsored in RPM Fusion, unless you are already a sponsored packager in Fedora, which would then grant you packager status in RPM Fusion too.
Also, I can't find your FAS username in this review. I'll guess you are benzea in Fedora, but I'd rather not guess :-)
https://rpmfusion.org/Contributors#Get_an_RPM_Fusion_Account
Comment 20 Benjamin Berg 2019-06-06 17:00:59 CEST
Alright, my FAS account is created now and also "benzea".

I am already sponsored for Fedora.
Comment 21 Benjamin Berg 2019-06-06 17:01:26 CEST
Er, correction, I created the rpmfusion account "benzea" and my FAS account is indeed "benzea" :)
Comment 22 leigh scott 2019-06-06 18:15:22 CEST
(In reply to Benjamin Berg from comment #21)
> Er, correction, I created the rpmfusion account "benzea" and my FAS account
> is indeed "benzea" :)

You need to accept our CLA agreement before I can add you to packagers

https://admin.rpmfusion.org/accounts/user/view/benzea
Comment 23 Benjamin Berg 2019-06-06 18:40:30 CEST
Ah, sorry about that. Done, I hope I didn't miss anything else.
Comment 24 leigh scott 2019-06-07 04:13:07 CEST
(In reply to Benjamin Berg from comment #23)
> Ah, sorry about that. Done, I hope I didn't miss anything else.

Sponsorship approved, now you need to apply for package branches. 

https://admin.rpmfusion.org/pkgdb/request/package/
Comment 25 Benjamin Berg 2019-06-07 13:55:12 CEST
> Sponsorship approved, now you need to apply for package branches. 

Thanks! I just did that.
Comment 26 leigh scott 2019-06-07 19:32:05 CEST
Processed. https://admin.rpmfusion.org/pkgdb/package/nonfree/dptfxtract/
Comment 27 Benjamin Berg 2019-06-16 17:27:58 CEST
The package is available now. Thanks everyone!