genkernel version parsing problem

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

genkernel version parsing problem

Marco Gigante
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

check_genkernel_version.diff (616 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Leno Hou

On Fri, Apr 15, 2016 at 3:54 PM, Marco Gigante <[hidden email]> wrote:
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

Thanks, yesterday I have faced the problem you said and this works fine with me~~

-Leno Hou 

Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Mike Frysinger
In reply to this post by Marco Gigante
On 15 Apr 2016 09:54, Marco Gigante wrote:
> 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.

is this new to 3.5.0.1 ?  or did it happen with 3.5.0.0 ?  i don't think
it was intentional, so we can always just change genkernel ...
-mike

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Leno Hou
On Thu, Apr 21, 2016 at 1:42 PM, Mike Frysinger <[hidden email]> wrote:
On 15 Apr 2016 09:54, Marco Gigante wrote:
> 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.

is this new to 3.5.0.1 ?  or did it happen with 3.5.0.0 ?  i don't think
it was intentional, so we can always just change genkernel ...
-mike

Faced the problem only in v3.5.0.1. Not happen in v3.5.0.0

leno@localhost ~ $ genkernel --version

v3.5.0.1


-Leno Hou
Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Mike Frysinger
On 21 Apr 2016 13:48, Leno Hou wrote:

> On Thu, Apr 21, 2016 at 1:42 PM, Mike Frysinger wrote:
> > On 15 Apr 2016 09:54, Marco Gigante wrote:
> > > 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.
> >
> > is this new to 3.5.0.1 ?  or did it happen with 3.5.0.0 ?  i don't think
> > it was intentional, so we can always just change genkernel ...
>
> Faced the problem only in v3.5.0.1. Not happen in v3.5.0.0
>
> leno@localhost ~ $ genkernel --version
>
> v3.5.0.1
i made the 3.5.0.1 release and def did not mean to make that change.
but in looking at the git history, i'm not seeing anything since the
3.5.0.0 tag that looks relevant.

that said, i'm not seeing this behavior:
$ genkernel --version
3.5.0.1

and when i look at the source, it's OK:
$ tar xf /usr/portage/distfiles/genkernel-3.5.0.1.tar.xz
$ grep ^GK genkernel-3.5.0.1/genkernel
GK_V='3.5.0.1'

so where are you guys getting that "v" from ?  if your GK_V var is
also set correctly, send over the output from running:
$ bash -x genkernel --version
-mike

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Leno Hou
On Thu, Apr 21, 2016 at 2:21 PM, Mike Frysinger <[hidden email]> wrote:
On 21 Apr 2016 13:48, Leno Hou wrote:
> On Thu, Apr 21, 2016 at 1:42 PM, Mike Frysinger wrote:
> > On 15 Apr 2016 09:54, Marco Gigante wrote:
> > > 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.
> >
> > is this new to 3.5.0.1 ?  or did it happen with 3.5.0.0 ?  i don't think
> > it was intentional, so we can always just change genkernel ...
>
> Faced the problem only in v3.5.0.1. Not happen in v3.5.0.0
>
> leno@localhost ~ $ genkernel --version
>
> v3.5.0.1

i made the 3.5.0.1 release and def did not mean to make that change.
but in looking at the git history, i'm not seeing anything since the
3.5.0.0 tag that looks relevant.

that said, i'm not seeing this behavior:
$ genkernel --version
3.5.0.1

and when i look at the source, it's OK:
$ tar xf /usr/portage/distfiles/genkernel-3.5.0.1.tar.xz
$ grep ^GK genkernel-3.5.0.1/genkernel
GK_V='3.5.0.1'

so where are you guys getting that "v" from ?  if your GK_V var is
also set correctly, send over the output from running:
$ bash -x genkernel --version

leno@localhost ~ $ bash -x genkernel --version

+ PATH=/usr/local/bin:/usr/bin:/bin:/opt/bin:/usr/powerpc64le-unknown-linux-gnu/gcc-bin/5.3.0:/sbin:/usr/sbin

+ GK_V=v3.5.0.1

+ TMPDIR=/var/tmp/genkernel

+ TODEBUGCACHE=1

+ (( i=1 ))

+ (( i<=1  ))

+ eval 'arg=$1'

++ arg=--version

+ [[ --version = --config=* ]]

+ (( i=i+1  ))

+ (( i<=1  ))

+ _GENKERNEL_CONF=/etc/genkernel.conf

+ source /etc/genkernel.conf

++ OLDCONFIG=yes

++ MENUCONFIG=no

++ CLEAN=yes

++ MRPROPER=yes

++ MOUNTBOOT=yes

++ SAVE_CONFIG=yes

++ USECOLOR=yes

++ DISKLABEL=yes

++ GK_SHARE=/usr/share/genkernel

++ CACHE_DIR=/var/cache/genkernel

++ DISTDIR=/usr/share/genkernel/distfiles

++ LOGFILE=/var/log/genkernel.log

++ LOGLEVEL=1

++ DEFAULT_KERNEL_SOURCE=/usr/src/linux

+ LOGLEVEL=1

+ source /usr/share/genkernel/defaults/software.sh

++ BUSYBOX_VER=1.20.2

++ BUSYBOX_SRCTAR=/usr/share/genkernel/distfiles/busybox-1.20.2.tar.bz2

++ BUSYBOX_DIR=busybox-1.20.2

++ BUSYBOX_BINCACHE=%%CACHE%%/busybox-1.20.2-%%ARCH%%.tar.bz2

++ LVM_VER=2.02.88

++ LVM_DIR=LVM2.2.02.88

++ LVM_SRCTAR=/usr/share/genkernel/distfiles/LVM2.2.02.88.tgz

++ LVM_BINCACHE=%%CACHE%%/LVM2.2.02.88-%%ARCH%%.tar.bz2

++ MDADM_VER=3.1.5

++ MDADM_DIR=mdadm-3.1.5

++ MDADM_SRCTAR=/usr/share/genkernel/distfiles/mdadm-3.1.5.tar.bz2

++ MDADM_BINCACHE=%%CACHE%%/mdadm-3.1.5-%%ARCH%%.tar.bz2

++ DMRAID_VER=1.0.0.rc16-3

++ DMRAID_DIR=dmraid/1.0.0.rc16-3/dmraid

++ DMRAID_SRCTAR=/usr/share/genkernel/distfiles/dmraid-1.0.0.rc16-3.tar.bz2

++ DMRAID_BINCACHE=%%CACHE%%/dmraid-1.0.0.rc16-3-%%ARCH%%.tar.bz2

++ ISCSI_VER=2.0-872

++ ISCSI_DIR=open-iscsi-2.0-872

++ ISCSI_SRCTAR=/usr/share/genkernel/distfiles/open-iscsi-2.0-872.tar.gz

++ ISCSI_BINCACHE=%%CACHE%%/iscsi-2.0-872-%%ARCH%%.bz2

++ FUSE_VER=2.8.6

++ FUSE_DIR=fuse-2.8.6

++ FUSE_SRCTAR=/usr/share/genkernel/distfiles/fuse-2.8.6.tar.gz

++ FUSE_BINCACHE=%%CACHE%%/fuse-2.8.6-%%ARCH%%.tar.bz2

++ UNIONFS_FUSE_VER=0.24

++ UNIONFS_FUSE_DIR=unionfs-fuse-0.24

++ UNIONFS_FUSE_SRCTAR=/usr/share/genkernel/distfiles/unionfs-fuse-0.24.tar.bz2

++ UNIONFS_FUSE_BINCACHE=%%CACHE%%/unionfs-fuse-0.24-%%ARCH%%.bz2

++ GPG_VER=1.4.11

++ GPG_DIR=gnupg-1.4.11

++ GPG_SRCTAR=/usr/share/genkernel/distfiles/gnupg-1.4.11.tar.bz2

++ GPG_BINCACHE=%%CACHE%%/gnupg-1.4.11-%%ARCH%%.bz2

+ source /usr/share/genkernel/defaults/config.sh

++ KERNEL_MAKE_DIRECTIVE=--INVALID--

++ DEFAULT_KERNEL_MAKE_DIRECTIVE_OVERRIDE=--INVALID--

++ KERNEL_MAKE_DIRECTIVE_OVERRIDE=--INVALID--

++ KERNEL_MAKE_DIRECTIVE_2=

++ KERNEL_BINARY=--INVALID--

++ KERNEL_BINARY_OVERRIDE=

++ DEFAULT_COMPRESS_INITRD=yes

++ DEFAULT_COMPRESS_INITRD_TYPE=best

+++ portageq envvar MAKEOPTS

++ PORTAGE_MAKEOPTS=

++ DEFAULT_MAKEOPTS=' -j2'

++ DEFAULT_KERNEL_MAKE=make

++ DEFAULT_UTILS_MAKE=make

++ DEFAULT_KERNEL_CC=gcc

++ DEFAULT_KERNEL_AS=as

++ DEFAULT_KERNEL_LD=ld

++ DEFAULT_UTILS_CC=gcc

++ DEFAULT_UTILS_AS=as

++ DEFAULT_UTILS_LD=ld

+ source /usr/share/genkernel/gen_funcs.sh

++ setColorVars

++ isTrue yes

++ case "$1" in

++ return 0

++ GOOD=''

++ WARN=''

++ BAD=''

++ NORMAL=''

++ BOLD=''

++ UNDER=''

+ source /usr/share/genkernel/gen_cmdline.sh

+ source /usr/share/genkernel/gen_arch.sh

+ source /usr/share/genkernel/gen_determineargs.sh

+ source /usr/share/genkernel/gen_compile.sh

+ source /usr/share/genkernel/gen_configkernel.sh

+ source /usr/share/genkernel/gen_initramfs.sh

++ COPY_BINARIES=false

++ CPIO_ARGS='--quiet -o -H newc --owner root:root --force-local'

+ source /usr/share/genkernel/gen_moddeps.sh

+ source /usr/share/genkernel/gen_package.sh

+ source /usr/share/genkernel/gen_bootloader.sh

+ TEMP=/var/tmp/genkernel/25303.5280.20958.30535

+ trap trap_cleanup SIGHUP SIGQUIT SIGINT SIGTERM SIGKILL

+ BUILD_KERNEL=0

+ BUILD_RAMDISK=0

+ BUILD_MODULES=0

+ Options=--version

+ '[' 1 -gt 0 ']'

+ Option=--version

+ shift

+ parse_cmdline --version

+ case "$*" in

+ echo v3.5.0.1

v3.5.0.1

+ exit 0


-Leno Hou

Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Marco Gigante
In reply to this post by Leno Hou
On 21/04/2016 07:48, Leno Hou wrote:
On Thu, Apr 21, 2016 at 1:42 PM, Mike Frysinger <[hidden email]> wrote:
On 15 Apr 2016 09:54, Marco Gigante wrote:
> 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.

is this new to 3.5.0.1 ?  or did it happen with 3.5.0.0 ?  i don't think
it was intentional, so we can always just change genkernel ...

I looked at genkernel before writing and GK_V is "3.5.0.1". Couldn't quickly figure out where the 'v' comes from.

I just analysed the issue, and it is the genkernel-9999 ebuild which modifies the GK_V into src_prepare(), by picking the git tag as version number.
Not sure which is better, change genkernel or catalyst. I guess protecting version check in catalyst will make it more reliable anyway.

-marco

-mike

Faced the problem only in v3.5.0.1. Not happen in v3.5.0.0

leno@localhost ~ $ genkernel --version

v3.5.0.1


-Leno Hou

Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Leno Hou
In reply to this post by Mike Frysinger
On Thu, Apr 21, 2016 at 2:21 PM, Mike Frysinger <[hidden email]> wrote:

i made the 3.5.0.1 release and def did not mean to make that change.
but in looking at the git history, i'm not seeing anything since the
3.5.0.0 tag that looks relevant.

that said, i'm not seeing this behavior:
$ genkernel --version
3.5.0.1

and when i look at the source, it's OK:
$ tar xf /usr/portage/distfiles/genkernel-3.5.0.1.tar.xz
$ grep ^GK genkernel-3.5.0.1/genkernel
GK_V='3.5.0.1'


Sorry, this happens in genkernel-9999 

Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Mike Frysinger
On 21 Apr 2016 14:34, Leno Hou wrote:

> On Thu, Apr 21, 2016 at 2:21 PM, Mike Frysinger wrote:
> > i made the 3.5.0.1 release and def did not mean to make that change.
> > but in looking at the git history, i'm not seeing anything since the
> > 3.5.0.0 tag that looks relevant.
> >
> > that said, i'm not seeing this behavior:
> > $ genkernel --version
> > 3.5.0.1
> >
> > and when i look at the source, it's OK:
> > $ tar xf /usr/portage/distfiles/genkernel-3.5.0.1.tar.xz
> > $ grep ^GK genkernel-3.5.0.1/genkernel
> > GK_V='3.5.0.1'
>
> Sorry, this happens in genkernel-9999
ok, that makes more sense.  i'll update the ebuild so that it doesn't
add the v prefix and so it includes 9999 so it's clear where the code
is coming from.
-mike

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Mike Frysinger
In reply to this post by Marco Gigante
On 15 Apr 2016 09:54, Marco Gigante wrote:
> 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've fixed the ebuild here:
        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=187ec2310c21c0c96812dec5e2d2a13172492ca9

with that in place, i don't think any changes to catalyst are needed.
-mike

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: genkernel version parsing problem

Marco Gigante
On 21/04/2016 19:05, Mike Frysinger wrote:
> On 15 Apr 2016 09:54, Marco Gigante wrote:
>> 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've fixed the ebuild here:
> https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=187ec2310c21c0c96812dec5e2d2a13172492ca9
>
> with that in place, i don't think any changes to catalyst are needed.

Will try it asap.
Thanks a lot for the fix and the help.

-marco

> -mike