SPEC URL: https://dl.dropboxusercontent.com/u/42480493/tlp.spec SRPM URL: https://dl.dropboxusercontent.com/u/42480493/tlp-0.5-1.fc20.src.rpm Description: TLP brings you the benefits of advanced power management for Linux without the need to understand every technical detail. TLP comes with a default configuration already optimized for battery life. Fedora Account System Username: mystro256
I've taken the package since I'm a TLP user and very interested in this package :) Review will follow soon. Greetings, Christian
Thanks Christian! Notice that I used your systemd preset ;) Note that I plan to eventually make a package for tpacpi-bat in rpmfusion, as it requires kmods to work Also I believe TLP_NO_PMUTILS=1 is required because pm-utils is a part of fedora, right? As well, I did not include the thinkpad-radiosw files because i believe fedora does not include CONFIG_ACPI_PROC_EVENT=y in the kernel package. Please let me know if I am incorrect because I have minimal experience with kernel development. Finally, is there a macro for the udev folder to your knowledge? Because I would like to use it, if available, to clean the spec a little bit. Thanks!
Hi Jeremy! There are some issues with the package: 1.) Your package doesn't build in mock (please use it :), because the macros %{_presetdir} and %{_unitdir} are unknown. The macro definition is part of the systemd package, which should be a BuildRequires. Please add it! 2.) I'm not the author of the file 50-tlp.preset, maybe you got this information because I created the very first rpm for TLP (some years ago, for openSUSE, no systemd) ;) Other rpms were derived from this work. 3.) The sense of the preset file is enabling tlp automatically after installation? If yes: Please remove it, services should be enabled manually. Confirm https://fedoraproject.org/wiki/Packaging:Systemd#Why_don.27t_we.... 3.) Please order Requires (and BuildRequires) alphabetically About your questions: 1.) About TLP_NO_PMUTILS=1 I have to check later. I don't know the answer right now. 2.) CONFIG_ACPI_PROC_EVENT is not set http://pkgs.fedoraproject.org/cgit/kernel.git/tree/config-x86-generic#n89 3.) There is a macro for the udev rules, this is also part of the systemd package ;) It is called %{_udevrulesdir}, you can confirm the file /usr/lib/rpm/macros.d/macros.systemd for these macros After you made your corrections I will perform a more detailed review using the fedora-review tool. In general, fedora-review and mock are very powerful tools for packaging :) When I want to submit a new package, I always check that my package builds fine using mock. Then fedora-review works fine :) https://fedorahosted.org/FedoraReview/ https://fedoraproject.org/wiki/Projects/Mock Greetings, Christian
(In reply to Christian Dersch from comment #3) > Hi Jeremy! > > There are some issues with the package: > > 1.) Your package doesn't build in mock (please use it :), because the macros > %{_presetdir} and %{_unitdir} are unknown. The macro definition is part of > the systemd package, which should be a BuildRequires. Please add it! Ah my bad, I'll fix this issue right away.. I usually check with mock, I was negligent this time ;) > 2.) I'm not the author of the file 50-tlp.preset, maybe you got this > information because I created the very first rpm for TLP (some years ago, > for openSUSE, no systemd) ;) Other rpms were derived from this work. Indeed, you are correct. It seems Andreas Roederer wrote this. I'll give him the credit. > 3.) The sense of the preset file is enabling tlp automatically after > installation? If yes: Please remove it, services should be enabled manually. > Confirm https://fedoraproject.org/wiki/Packaging:Systemd#Why_don.27t_we.... I was under the impression that %systemd_post, %systemd_preun and %systemd_postun_with_restart were required for systemd services period... See here: https://fedoraproject.org/wiki/Packaging:ScriptletSnippets#Systemd > 3.) Please order Requires (and BuildRequires) alphabetically Will do > About your questions: > > 1.) About TLP_NO_PMUTILS=1 I have to check later. I don't know the answer > right now. Alright thanks! I'll redirect the question to the code maintainer/developer. > 2.) CONFIG_ACPI_PROC_EVENT is not set > http://pkgs.fedoraproject.org/cgit/kernel.git/tree/config-x86-generic#n89 Oh okay, so my assumption was correct; as from what I know, CONFIG_ACPI_PROC_EVENT is defaulted to N as of 2.6.23... if it even exists in the current kernel. > 3.) There is a macro for the udev rules, this is also part of the systemd > package ;) It is called %{_udevrulesdir}, you can confirm the file > /usr/lib/rpm/macros.d/macros.systemd for these macros Ahhh the more you know. Thanks for the tip! I do have another question/concern though. I know my package spec gives a hardcoded-library-path in rpmlint... I only do this because building it x86-64 causes a build error, due to %{_libdir} being /usr/lib64, not /usr/lib, which is necessary for this package. Granted, I'm told it SHOULD be patched to go into %{_libexecdir} instead. Do you have any thoughts on this?
Ah I found my answer: https://fedoraproject.org/wiki/Packaging:Guidelines#Filesystem_Layout The Multilib Exempt Locations section describes it pretty well, items that would normally be put in libexec can use %{_prefix}/lib instead of %{_libdir}. The Libexecdir section goes on to say that the libexec section is not required. This rpmlint error can be treated as a non-issue, although rpmlint suggests that they should really be in /usr/share. Let me know what you think and I can direct this issue towards the developer if necessary. I noticed the non-conffile-in-etc error in rpmlint though. I believe this is a false positive but I'm a little confused how bash-completion files should be handled... Let me know what you think. Also at the developer's request, I've re-added tpacpi-bat, as even though it requires kmod's, it's an optional require. If someone decides to add them later to the kernel or to rpmfusion, it should adapt seamlessly according to the developer. None the less, I've uploaded the file at the same links. Note that I'm not bumping the release because the old one didn't build.. I bumped the changelog though. SPEC URL: https://dl.dropboxusercontent.com/u/42480493/tlp.spec SRPM URL: https://dl.dropboxusercontent.com/u/42480493/tlp-0.5-1.fc20.src.rpm
My remarks on the SPEC: > URL: http://linrunner.de/en/tlp/tlp.html Should be: http://linrunner.de/tlp > Requires: smartmontools Is not mandatory for TLP to work, should be an optional dependency. > Requires: %{_bindir}/on_ac_power Is not needed (since 0.3.10 in fact, as stated in the docs). In case laptop-mode-tools is in the Fedora repos, there should be a "Conflicts:" for it.
(In reply to Thomas Koch from comment #6) > My remarks on the SPEC: > > > URL: http://linrunner.de/en/tlp/tlp.html > Should be: http://linrunner.de/tlp Ah thanks! > > Requires: smartmontools > Is not mandatory for TLP to work, should be an optional dependency. I don't believe fedora has "optional" dependencies, so I'll remove this and make note of it in the description. > > Requires: %{_bindir}/on_ac_power > Is not needed (since 0.3.10 in fact, as stated in the docs). Ah I misread; I thought it said mandatory after 0.3.10. Thanks! > In case laptop-mode-tools is in the Fedora repos, there should be a > "Conflicts:" for it. laptop-mode-tools is not a part of the official repo, but I know that there are ones being distributed by third party vendors (e.g. http://www.samwel.tk/laptop_mode). I guess I can add a conflict for %{_sbindir}/laptop_mode, but I don't want to use a package name due to possible renaming or re-branding. I'll make these changes later today when I get home.
New files SPEC URL: https://dl.dropboxusercontent.com/u/42480493/tlp.spec SRPM URL: https://dl.dropboxusercontent.com/u/42480493/tlp-0.5-2.fc20.src.rpm Note that I moved the bash completion into /usr/share/bash-completion/completions to avoid an rpmlint warning. I'm told this is the "more correct" location for these. Here's the current rpmlint errors: > tlp.src: W: spelling-error %description -l en_US smartmontools -> smartypants > tlp.src: W: spelling-error %description -l en_US smartctl -> smarts > tlp.noarch: W: spelling-error %description -l en_US smartmontools -> smartypants > tlp.noarch: W: spelling-error %description -l en_US smartctl -> smarts > tlp.noarch: W: no-manual-page-for-binary tlp-pcilist > tlp.noarch: W: no-manual-page-for-binary tlp-usblist These can be safely ignored > tlp.src:74: E: hardcoded-library-path in %{_prefix}/lib/tlp-pm This is explained/justified in comment#5 > tlp.noarch: W: only-non-binary-in-usr-lib > tlp-rdw.noarch: W: only-non-binary-in-usr-lib These are just warnings, so it can be ignored, but these files really should be going into /usr/libexec or /usr/share, pedantically speaking that is... Anyway thanks Thomas!
Thanks for the corrections Jeremy! I will check again today or tomorrow :)
Hi! Package looks fine now, already tested it with my Thinkpad R400. Greetings, Christian Package Review ============== Legend: [x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated [ ] = Manual review needed ===== 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. [x]: License field in the package spec file matches the actual license. Note: Checking patched sources after %prep for licenses. Licenses found: "Unknown or generated". 1 files have unknown license. Detailed output of licensecheck in /home/rpmbuild/1089559-tlp/licensecheck.txt [x]: License file installed when any subpackage combination is installed. [x]: Package must own all directories that it creates. Note: Directories without known owners: /usr/share/bash-completion, /usr/share/bash-completion/completions [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. [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. [x]: 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 61440 bytes in 6 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 %doc. [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]: %config files are marked noreplace or the reason is justified. [x]: Macros in Summary, %description expandable at SRPM build time. [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]: No %config files under /usr. [x]: Package do not use a name that already exist [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: [!]: Uses parallel make %{?_smp_mflags} macro. => I think it's a false positive in this case [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]: 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. [-]: %check is present and all tests pass. [x]: Packages should try to preserve timestamps of original installed files. [x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file [x]: Sources can be downloaded from URI in Source: tag [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]: Dist tag is present (not strictly required in GL). [x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin. [x]: Fully versioned dependency in subpackages if applicable. [x]: SourceX is a working URL. [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]: Spec file according to URL is the same as in SRPM. Rpmlint ------- Checking: tlp-0.5-2.fc21.noarch.rpm tlp-rdw-0.5-2.fc21.noarch.rpm tlp-0.5-2.fc21.src.rpm tlp.noarch: W: spelling-error %description -l en_US smartmontools -> smartypants tlp.noarch: W: spelling-error %description -l en_US smartctl -> smarts tlp.noarch: W: only-non-binary-in-usr-lib tlp.noarch: W: no-manual-page-for-binary tlp-pcilist tlp.noarch: W: no-manual-page-for-binary tlp-usblist tlp-rdw.noarch: W: only-non-binary-in-usr-lib tlp.src: W: spelling-error %description -l en_US smartmontools -> smartypants tlp.src: W: spelling-error %description -l en_US smartctl -> smarts tlp.src:74: E: hardcoded-library-path in %{_prefix}/lib/tlp-pm 3 packages and 0 specfiles checked; 1 errors, 8 warnings. => Should be ok according to comment in spec file Rpmlint (installed packages) ---------------------------- # rpmlint tlp-rdw tlp tlp-rdw.noarch: W: only-non-binary-in-usr-lib tlp.noarch: W: spelling-error %description -l en_US smartmontools -> smartypants tlp.noarch: W: spelling-error %description -l en_US smartctl -> smarts tlp.noarch: W: only-non-binary-in-usr-lib tlp.noarch: W: no-manual-page-for-binary tlp-pcilist tlp.noarch: W: no-manual-page-for-binary tlp-usblist 2 packages and 0 specfiles checked; 0 errors, 6 warnings. # echo 'rpmlint-done:' Requires -------- tlp-rdw (rpmlib, GLIBC filtered): /bin/sh NetworkManager tlp tlp (rpmlib, GLIBC filtered): /bin/sh /usr/bin/perl config(tlp) ethtool hdparm iw perl(File::Basename) perl(strict) perl(warnings) redhat-lsb-core rfkill systemd udev usbutils wireless-tools Provides -------- tlp-rdw: tlp-rdw tlp: config(tlp) tlp Source checksums ---------------- https://github.com/linrunner/TLP/archive/0.5.tar.gz : CHECKSUM(SHA256) this package : e535e53c340a1af2ea72f0de8a2ffbfc5f832a4e29c391a4052ab1d783c5c157 CHECKSUM(SHA256) upstream package : e535e53c340a1af2ea72f0de8a2ffbfc5f832a4e29c391a4052ab1d783c5c157 Generated by fedora-review 0.5.1 (bb9bf27) last change: 2013-12-13 Command line :/bin/fedora-review -m fedora-rawhide-x86_64 -b 1089559 Buildroot used: fedora-rawhide-x86_64 Active plugins: Generic, Shell-api Disabled plugins: Java, C/C++, Python, fonts, SugarActivity, Ocaml, Perl, Haskell, R, PHP, Ruby Disabled flags: EXARCH, EPEL5, BATCH, DISTTAG
Thanks! New Package SCM Request ======================= Package Name: tlp Short Description: Advanced power management tool for Linux Owners: mystro256 Branches: f19 f20 el6 epel7 InitialCC:
Git done (by process-git-requests).
Thanks Jon! Builds underway...
tlp-0.5-2.fc19 has been submitted as an update for Fedora 19. https://admin.fedoraproject.org/updates/tlp-0.5-2.fc19
tlp-0.5-2.fc20 has been submitted as an update for Fedora 20. https://admin.fedoraproject.org/updates/tlp-0.5-2.fc20
fedora 19/20 updates pending for testing, pending a push to rawhide and epel7 As for epel6, I forgot that el6 doesn't use systemd, so I'll likely have to come back to this.
tlp-0.5-2.fc19 has been pushed to the Fedora 19 testing repository.
tlp-0.5-2.fc19 has been pushed to the Fedora 19 stable repository.
tlp-0.5-2.fc20 has been pushed to the Fedora 20 stable repository.