Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 460328

Summary: app-admin/eselect: patch for kernel.eselect to detect valid linux sources by presence of Makefile
Product: Gentoo Hosted Projects Reporter: C. Wijtmans <cj.wijtmans>
Component: eselectAssignee: Gentoo eselect Team <eselect>
Status: RESOLVED FIXED    
Severity: normal Keywords: InVCS
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: patch
patch

Description C. Wijtmans 2013-03-04 20:47:25 UTC
Created attachment 340964 [details]
patch

Several packages in portage require a Makefile to be present.
Absent Makefile also usually means an unmerged source.
This patch only lists targets that have a Makefile.
Comment 1 Ulrich Müller gentoo-dev 2013-03-04 21:43:27 UTC
(In reply to comment #0)
> Created attachment 340964 [details]
> patch

Looks like there's a typo here:

-       elif [[ -d ${EROOT}/usr/src/linux-${target} ]]; then
+       elif [[ -d ${EROOT}/usr/src/linux-${target}/Makefile ]]; then
Comment 2 C. Wijtmans 2013-03-04 23:05:49 UTC
Created attachment 340972 [details]
patch

fixed typo

-d > -e
Comment 3 C. Wijtmans 2013-07-14 09:56:14 UTC
What would it take for a dev to push it?
Comment 4 Ulrich Müller gentoo-dev 2013-07-14 11:12:02 UTC
Sorry, this went off my radar.

I think I'm going to omit the change in do_show. It's misleading if it displays "unset" when the link exists.
Comment 5 C. Wijtmans 2013-07-14 11:25:29 UTC
My logic behind it was that a link to a dir without a Makefile would be invalid.
Comment 6 Ulrich Müller gentoo-dev 2013-07-14 15:26:15 UTC
Committed to git:
http://git.overlays.gentoo.org/gitweb/?p=proj/eselect.git;a=commit;h=fb4af551582bbc588e9a97fdb0af942126b618c9

(In reply to C.J. Wijtmans from comment #5)
> My logic behind it was that a link to a dir without a Makefile would be
> invalid.

I've added a warning message if the symlink target doesn't look like a valid kernel tree.
Comment 7 C. Wijtmans 2013-07-14 16:14:42 UTC
Thank you Ulrich MUller :)
Comment 8 Ulrich Müller gentoo-dev 2013-07-16 16:08:36 UTC
Fixed in eselect-1.3.7.
Thanks for reporting!
Comment 9 C. Wijtmans 2013-07-19 21:14:10 UTC
This patch has introduced a bug i havent thought about.

- merge 3.10.0 sources
- eselect 3.10.0 sources
- emerge 3.10.1 sources
- unmerge 3.10.0 sources.
- eselect kernel list
Comment 10 Ulrich Müller gentoo-dev 2013-07-19 22:08:50 UTC
(In reply to C.J. Wijtmans from comment #9)
> This patch has introduced a bug i havent thought about.
> 
> - merge 3.10.0 sources
> - eselect 3.10.0 sources
> - emerge 3.10.1 sources
> - unmerge 3.10.0 sources.
> - eselect kernel list

What does this output? And what did you expect as output?
Comment 11 C. Wijtmans 2013-07-20 10:04:24 UTC
hmm nevermind everything is fine. somehow my link got set to 3.10.1 while i was using 3.10.0, something went wrong but idk what. cant reproduce it.