Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 945285 - sys-power/tlp-1.7.0-r1 - internal collisions between non-identical files
Summary: sys-power/tlp-1.7.0-r1 - internal collisions between non-identical files
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Jay Faulkner
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-11-29 08:20 UTC by Bryce Copeland
Modified: 2025-03-12 19:24 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build log (build.log,16.16 KB, text/x-log)
2024-11-29 08:20 UTC, Bryce Copeland
Details
emerge --info (emerge.info,8.44 KB, text/plain)
2024-11-29 08:20 UTC, Bryce Copeland
Details
proposed fix (tlp-ebuild.patch,1.26 KB, patch)
2024-11-29 09:31 UTC, Bryce Copeland
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Bryce Copeland 2024-11-29 08:20:21 UTC
Created attachment 912575 [details]
build log

Hi, I've been getting this error while trying to build the latest version of tlp

 * Package 'sys-power/tlp-1.7.0-r1' has internal collisions between non-
 * identical files (located in separate directories in the installation
 * image (${D}) corresponding to merged directories in the target
 * filesystem (${ROOT})):
 *
 * 	/usr/lib/elogind/system-sleep/49-tlp-sleep
 * 		/lib/elogind/system-sleep/49-tlp-sleep
 * 		/usr/lib/elogind/system-sleep/49-tlp-sleep
 * 			Differences: type, mode
 *
 * Package 'sys-power/tlp-1.7.0-r1' NOT merged due to internal collisions
 * between non-identical files. If necessary, refer to your elog messages
 * for the whole content of the above message.

I'm running on llvm/musl with non-splitusr. It looks like it's somehow creating different files in /lib and /usr/lib for 49-tlp-sleep.
Comment 1 Bryce Copeland 2024-11-29 08:20:42 UTC
Created attachment 912576 [details]
emerge --info
Comment 2 Bryce Copeland 2024-11-29 09:31:37 UTC
Created attachment 912608 [details, diff]
proposed fix

I had a play round with the ebuild, and I think the issue comes from a dosym function that creates a symlink: 
/usr/lib/elogind/system-sleep/49-tlp-sleep -> /lib/elogind/system-sleep/49-tlp-sleep

this leads to one of the files being a symlink and the other the actual script. Since this is only necessary under split-usr, I think having it run conditionally under the split-usr use flag would fix it. I'll attach a patch showing what I mean :)

I also noticed that the package always installs files for both elogind and system regardless of which is present, might be a good idea to add those use flags too, but this is unrelated to this bug.
Comment 3 Jay Faulkner gentoo-dev 2024-12-02 20:32:58 UTC
I'll look at the proposed patch and bugfix. Thanks!

For the elogind/systemd configs; under Gentoo's small files policy https://projects.gentoo.org/qa/policy-guide/installed-files.html#pg0301 we don't use use flags to prevent the installation of minor files, such as the config files indicated.
Comment 4 Jay Faulkner gentoo-dev 2025-03-12 19:19:01 UTC
A similar patch was PR'd, I'm merging that one to resolve this issue. Thanks fort he report.
Comment 5 Larry the Git Cow gentoo-dev 2025-03-12 19:24:29 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ac22bc3b256a7ccd530debb425a62ff04809e972

commit ac22bc3b256a7ccd530debb425a62ff04809e972
Author:     Stilic <lateman-jpeg@outlook.fr>
AuthorDate: 2025-03-10 20:02:37 +0000
Commit:     Jay Faulkner <jayf@gentoo.org>
CommitDate: 2025-03-12 19:21:18 +0000

    sys-power/tlp: fix install with elogind
    
    Signed-off-by: Stilic <lateman-jpeg@outlook.fr>
    Closes: https://bugs.gentoo.org/945285
    Closes: https://github.com/gentoo/gentoo/pull/41004
    Signed-off-by: Jay Faulkner <jayf@gentoo.org>

 sys-power/tlp/tlp-1.7.0-r1.ebuild | 4 ----
 1 file changed, 4 deletions(-)