public inbox for gentoo-catalyst@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-catalyst] genkernel version parsing problem
@ 2016-04-15  7:54 Marco Gigante
  2016-04-21  5:41 ` Leno Hou
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Marco Gigante @ 2016-04-15  7:54 UTC (permalink / raw
  To: gentoo-catalyst

[-- Attachment #1: Type: text/plain, Size: 315 bytes --]

Hi,
I got a problem with catalyst and latest version of genkernel, installed 
with genkernel-9999 ebuild.
genkernel --version returns v3.5.0.1 (with the 'v' prefix) and catalyst 
fails to check the minimal required version.

I made a quick fix which worked for me and wanted to share it for comments.

Thanks
marco

[-- Attachment #2: check_genkernel_version.diff --]
[-- Type: text/x-patch, Size: 604 bytes --]

diff --git a/targets/support/chroot-functions.sh b/targets/support/chroot-functions.sh
index 456ae4c..bcb22f4 100755
--- a/targets/support/chroot-functions.sh
+++ b/targets/support/chroot-functions.sh
@@ -21,6 +21,7 @@ check_genkernel_version(){
 	if [ -x /usr/bin/genkernel ]
 	then
 		genkernel_version=$(genkernel --version)
+		genkernel_version=${genkernel_version//[^0-9\.]/}	# keep just numbers and dots
 		genkernel_version_major=${genkernel_version%%.*}
 		genkernel_version_minor_sub=${genkernel_version#${genkernel_version_major}.}
 		genkernel_version_minor=${genkernel_version_minor_sub%%.*}

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2016-04-22  6:49 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-15  7:54 [gentoo-catalyst] genkernel version parsing problem Marco Gigante
2016-04-21  5:41 ` Leno Hou
2016-04-21  5:42 ` Mike Frysinger
2016-04-21  5:48   ` Leno Hou
2016-04-21  6:21     ` Mike Frysinger
2016-04-21  6:29       ` Leno Hou
2016-04-21  6:34       ` Leno Hou
2016-04-21 16:43         ` Mike Frysinger
2016-04-21  6:34     ` Marco Gigante
2016-04-21 17:05 ` Mike Frysinger
2016-04-22  6:49   ` Marco Gigante

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox