public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: chrubis@suse.cz
To: alexey.kodanev@oracle.com
Cc: vasily.isaenko@oracle.com, ltp-list@lists.sourceforge.net,
	Mike Frysinger <vapier@gentoo.org>
Subject: Re: [LTP] [PATCH v2] configure: add configure checks to compile kernel modules
Date: Wed, 19 Jun 2013 12:53:22 +0200	[thread overview]
Message-ID: <20130619105321.GA23968@rei> (raw)
In-Reply-To: <51C177A3.4020301@oracle.com>

Hi!
> >>> +if [[ -n "$LINUX_VERSION_MAJOR" -a -n "$LINUX_PATCHLEVEL" ]]; then
> >>> +    WITH_MODULES="yes"
> >> If there is Makefile and it contains reasonable content, proceed
> >> with module build, ok.
> >>
> >>> +else
> >>> +    WITH_MODULES="no"
> >>> +    if test -n "$LINUX_VERSION"; then
> >>> +        LINUX_VERSION_MAJOR=`echo "$LINUX_VERSION" | \
> >>> +sed -n 's/\([[0-9]]\).*$/\1/p'`
> >>> +        LINUX_PATCHLEVEL=`echo "$LINUX_VERSION" | \
> >>> +sed -n 's/^[[0-9]]*.\([[0-9]]\).*$/\1/p'`
> >>> +    fi
> >> Here we set the MAJOR and PATCHLEVEL even if WITH_MODULES is set to no.
> >> Is this useful? (Maybe I overlooked something but when WITH_MODULES is
> >> set to no, the kernel version is not needed. Or is this here just in
> >> case we will need that someday?)
> >>
> > Yes, it is true, those variables won't be used if WITH_MODULES is set 
> > to "no".
> > My thought was that they might be of use in the future, so far as we 
> > have something
> > in LINUX_VERSION, why not to get MAJOR & PATCHLEVEL from it. But for 
> > now they're
> > useless.
> Should I remove it?

Well I personally don't tend to add anything that is not used or is not
planned to be used in the near future.

> One more thing, would it be better to use LINUX_VERSION_MAJOR & 
> LINUX_VERSION_PATCH?

Either one is fine.

-- 
Cyril Hrubis
chrubis@suse.cz

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

      parent reply	other threads:[~2013-06-19 10:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-13 13:28 [LTP] [PATCH v2] configure: add configure checks to compile kernel modules Alexey Kodanev
2013-06-17 17:11 ` chrubis
     [not found]   ` <51C01086.1020207@oracle.com>
     [not found]     ` <51C177A3.4020301@oracle.com>
2013-06-19 10:53       ` chrubis [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130619105321.GA23968@rei \
    --to=chrubis@suse.cz \
    --cc=alexey.kodanev@oracle.com \
    --cc=ltp-list@lists.sourceforge.net \
    --cc=vapier@gentoo.org \
    --cc=vasily.isaenko@oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox