Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 516754 - app-admin/eselect: support for kernel directories other than linux-[[:digit:]]*
Summary: app-admin/eselect: support for kernel directories other than linux-[[:digit:]]*
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: eselect (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Gentoo eselect Team
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks:
 
Reported: 2014-07-09 11:12 UTC by Kobboi
Modified: 2014-09-01 16:57 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kobboi 2014-07-09 11:12:33 UTC
I would like eselect to be able to recognize kernel source trees other than the ones currently being scanned for. I have my own private tree as shown below. I now have to force meaningless digits (or I should make it so that the directory name changes with the version currently checked out :/) to be able to use eselect to switch trees.

$ ls -rtl /usr/src/
total 8
drwxr-xr-x 24 root root 4096 Jul  7 16:00 linux-3.15.3
drwxr-xr-x 23 root root 4096 Jul  7 18:09 linux-3.15.4
lrwxrwxrwx  1 root root   17 Jul  9 10:59 linux-live -> /home/linux-live/
lrwxrwxrwx  1 root root   12 Jul  9 13:06 linux -> linux-3.15.3
christophe@localhost /usr/src $ eselect kernel list
Available kernel symlink targets:
  [1]   linux-3.15.3 *
  [2]   linux-3.15.4

Discussed with ulm, he is referring to 

http://git.overlays.gentoo.org/gitweb/?p=proj/eselect.git;a=commitdiff;h=dca021004d8a2efee2701fa604541359a457f722

which fixed

https://bugs.gentoo.org/show_bug.cgi?id=104354

both dated 2005

Reproducible: Always
Comment 1 Ulrich Müller gentoo-dev 2014-08-28 13:04:54 UTC
In git, commit 2595c33ecfc5d1604a421f420ca6786c98968ba8:

--- a/modules/kernel.eselect
+++ b/modules/kernel.eselect
@@ -28,8 +28,8 @@ sort_kernel_versions() {
 # find a list of kernel symlink targets
 find_targets() {
        local f
-       for f in "${EROOT}"/usr/src/linux-[[:digit:]]*; do
-               [[ -f ${f}/Makefile ]] && basename "${f}"
+       for f in "${EROOT}"/usr/src/linux-*; do
+               [[ -f ${f}/Makefile && -f ${f}/Kconfig ]] && basename "${f}"
        done | sort_kernel_versions
 }
Comment 2 Ulrich Müller gentoo-dev 2014-09-01 16:57:38 UTC
Fixed in eselect-1.4.3.
Thanks for reporting.