Re: [systemd-devel] [PATCH] Fix: can not pass configure by default kmod build option

2014-01-15 Thread Zbigniew Jędrzejewski-Szmek
On Wed, Jan 15, 2014 at 01:28:26PM +0800, Chengwei Yang wrote:
 The situation is: by default, we get a auto value for kmod compiling
 option, so if we found required kmod files, then we build it with kmod
 enabled, otherwise, just build without kmod and do not complain to user.
 
 However, currently, if kmod version  15 available in machine, and build
 with default option, say no explicitly with --enable/disable-kmod,
 then the configure will fail with
 
 ...
 checking for KMOD... no
 configure: error: *** kmod version = 15 not found
 ...
This is on purpose.

commit c4955740969d7ba8ba43b024bca1a0a5b56eb8e8
Author: Tom Gundersen t...@jklm.no
Date:   Tue Jul 9 00:12:35 2013 +0200

configure: fail if out-of-date kmod found and kmod not disabled

Almost everyone wants kmod support, so don't fail silently if the libs are
out-of-date.

kmod can still be explicitly disabled and if it is not found at all, we 
still
default to disabling it.

Zbyszek
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] [PATCH] Fix: can not pass configure by default kmod build option

2014-01-15 Thread Yang Chengwei
On Thu, Jan 16, 2014 at 02:56:27AM +0100, Zbigniew Jędrzejewski-Szmek wrote:
 On Wed, Jan 15, 2014 at 01:28:26PM +0800, Chengwei Yang wrote:
  The situation is: by default, we get a auto value for kmod compiling
  option, so if we found required kmod files, then we build it with kmod
  enabled, otherwise, just build without kmod and do not complain to user.
  
  However, currently, if kmod version  15 available in machine, and build
  with default option, say no explicitly with --enable/disable-kmod,
  then the configure will fail with
  
  ...
  checking for KMOD... no
  configure: error: *** kmod version = 15 not found
  ...
 This is on purpose.

I'm not sure if this is worth, given that kmod may not available in some
distro version, for example, ubuntu 12.04, so you're expecting us to
replace kmod from OS repo or upgrade our OS to do systemd development. A
little dominating to user I think.

--
Thanks,
Chengwei

 
 commit c4955740969d7ba8ba43b024bca1a0a5b56eb8e8
 Author: Tom Gundersen t...@jklm.no
 Date:   Tue Jul 9 00:12:35 2013 +0200
 
 configure: fail if out-of-date kmod found and kmod not disabled
 
 Almost everyone wants kmod support, so don't fail silently if the libs are
 out-of-date.
 
 kmod can still be explicitly disabled and if it is not found at all, we 
 still
 default to disabling it.
 
 Zbyszek


signature.asc
Description: Digital signature
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] [PATCH] Fix: can not pass configure by default kmod build option

2014-01-15 Thread Zbigniew Jędrzejewski-Szmek
On Thu, Jan 16, 2014 at 10:05:23AM +0800, Yang Chengwei wrote:
 On Thu, Jan 16, 2014 at 02:56:27AM +0100, Zbigniew Jędrzejewski-Szmek wrote:
  On Wed, Jan 15, 2014 at 01:28:26PM +0800, Chengwei Yang wrote:
   The situation is: by default, we get a auto value for kmod compiling
   option, so if we found required kmod files, then we build it with kmod
   enabled, otherwise, just build without kmod and do not complain to user.
   
   However, currently, if kmod version  15 available in machine, and build
   with default option, say no explicitly with --enable/disable-kmod,
   then the configure will fail with
   
   ...
   checking for KMOD... no
   configure: error: *** kmod version = 15 not found
   ...
  This is on purpose.
 
 I'm not sure if this is worth, given that kmod may not available in some
 distro version, for example, ubuntu 12.04, so you're expecting us to
 replace kmod from OS repo or upgrade our OS to do systemd development. A
 little dominating to user I think.
No, the idea is to prevent accidental breakage when kmod is available,
but in an older version. Since this is fairly important functionality,
it is deemed better to require explicit override in this case.

Zbyszek
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] [PATCH] Fix: can not pass configure by default kmod build option

2014-01-15 Thread Yang Chengwei
On Thu, Jan 16, 2014 at 10:05:23AM +0800, Yang Chengwei wrote:
 On Thu, Jan 16, 2014 at 02:56:27AM +0100, Zbigniew Jędrzejewski-Szmek wrote:
  On Wed, Jan 15, 2014 at 01:28:26PM +0800, Chengwei Yang wrote:
   The situation is: by default, we get a auto value for kmod compiling
   option, so if we found required kmod files, then we build it with kmod
   enabled, otherwise, just build without kmod and do not complain to user.
   
   However, currently, if kmod version  15 available in machine, and build
   with default option, say no explicitly with --enable/disable-kmod,
   then the configure will fail with
   
   ...
   checking for KMOD... no
   configure: error: *** kmod version = 15 not found
   ...
  This is on purpose.
 
 I'm not sure if this is worth, given that kmod may not available in some
 distro version, for example, ubuntu 12.04, so you're expecting us to
 replace kmod from OS repo or upgrade our OS to do systemd development. A
 little dominating to user I think.

I also found several cases which doesn't cry in kmod way, like
libcryptsetup, qrencode, microhttpd, python_devel and maybe more, I'm
not going to list all of them, so I think it's good to make kmod work in
the same way as others.

--
Thanks,
Chengwei

 
 --
 Thanks,
 Chengwei
 
  
  commit c4955740969d7ba8ba43b024bca1a0a5b56eb8e8
  Author: Tom Gundersen t...@jklm.no
  Date:   Tue Jul 9 00:12:35 2013 +0200
  
  configure: fail if out-of-date kmod found and kmod not disabled
  
  Almost everyone wants kmod support, so don't fail silently if the libs 
  are
  out-of-date.
  
  kmod can still be explicitly disabled and if it is not found at all, we 
  still
  default to disabling it.
  
  Zbyszek




signature.asc
Description: Digital signature
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] [PATCH] Fix: can not pass configure by default kmod build option

2014-01-15 Thread Holger Schurig
Chengwai,

 given that kmod may not available in some distro version

I'm on Debian and use my self-compiled systemd v208 with a self-made
kmod_15.deb file. Packaging kmod is dead easy, it's a very
straightforward package. Using the newest kmod doesn't hurt Debian
Stable nor Debian SID. So the Debian packagers of systemd could very
easily package a decent version of kmod if they think that their
version of systemd should use if.

If they think that it's not worth the hassle, then they could simply
apply --disable-kmod. Both systemd and udev source code have the
proper #ifdef HAVE_KMOD guarding.
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] [PATCH] Fix: can not pass configure by default kmod build option

2014-01-15 Thread Kay Sievers
On Thu, Jan 16, 2014 at 8:27 AM, Holger Schurig holgerschu...@gmail.com wrote:

 If they think that it's not worth the hassle, then they could simply
 apply --disable-kmod. Both systemd and udev source code have the
 proper #ifdef HAVE_KMOD guarding.

Keep in mind that machines with modular kernels will just not boot
that way, unless something else than udev loads the modules, which is
not usually the case.

Kay
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel


[systemd-devel] [PATCH] Fix: can not pass configure by default kmod build option

2014-01-14 Thread Chengwei Yang
The situation is: by default, we get a auto value for kmod compiling
option, so if we found required kmod files, then we build it with kmod
enabled, otherwise, just build without kmod and do not complain to user.

However, currently, if kmod version  15 available in machine, and build
with default option, say no explicitly with --enable/disable-kmod,
then the configure will fail with

...
checking for KMOD... no
configure: error: *** kmod version = 15 not found
...

This isn't quite correct because the user didn't ask build with kmod,
why it complain with it.

So the correct behavior is only complain to user if it was required but
not available.

Signed-off-by: Chengwei Yang chengwei.y...@intel.com
---
 configure.ac |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/configure.ac b/configure.ac
index 7140627..2f4fe2c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -288,10 +288,10 @@ if test x$enable_kmod != xno; then
 if test x$have_kmod = xyes; then
 PKG_CHECK_MODULES(KMOD, [ libkmod = 15 ],
 [AC_DEFINE(HAVE_KMOD, 1, [Define if kmod is 
available])],
-AC_MSG_ERROR([*** kmod version = 15 not found]))
+have_kmod=no)
 fi
 if test x$have_kmod = xno -a x$enable_kmod = xyes; then
-AC_MSG_ERROR([*** kmod support requested, but libraries not 
found])
+AC_MSG_ERROR([*** kmod support requested, but kmod version = 
15 not found])
 fi
 fi
 AM_CONDITIONAL(HAVE_KMOD, [test $have_kmod = yes])
-- 
1.7.9.5

___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel