All of lore.kernel.org
 help / color / mirror / Atom feed
* RFC - Debian patches
@ 2009-10-08 11:54 Fabio M. Di Nitto
  2009-10-08 11:58   ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 11:54 UTC (permalink / raw)
  To: lvm-devel

Hi guys,

I was asked to look into the patch set Debian carries around to see what
we can merge upstream and what not, to try to reduce the delta between
distributions and upstream.

This morning I had a very pleasent talk with Bastian Blank (Debian maintainer
for lvm2) and this is the full patch queue rebased on latest CVS.

Debian at this point is at 2.02.53 from released tarball.

Bastian gave me explanations on all the patches.

This patch set is neutral (it means I am not asking inclusion of any patch
right away) but only review of ideas and possible bug fixes behind the patches.

Once we settled on what patches could be included and what changes need
to be done to merge them upstream, we will take appropriate steps, with
repost and extra review, etc.

Thanks
Fabio



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

* [PATCH 01/11] debian: fix library search path in example.conf
@ 2009-10-08 11:58   ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 11:54 UTC (permalink / raw)
  To: lvm-devel

this patch is debian specific and sets the library search path
to /lib/lvm2 to avoid cluttering /lib

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 1067665... 46c4dba... M	doc/example.conf
 doc/example.conf |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/doc/example.conf b/doc/example.conf
index 1067665..46c4dba 100644
--- a/doc/example.conf
+++ b/doc/example.conf
@@ -312,7 +312,7 @@ global {
     # Full pathnames can be given.
 
     # Search this directory first for shared libraries.
-    #   library_dir = "/lib"
+    #   library_dir = "/lib/lvm2"
 
     # The external locking library to load if locking_type is set to 2.
     #   locking_library = "liblvm2clusterlock.so"
-- 
1.5.4.3



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

* RFC - Debian patches (resend)
@ 2009-10-08 11:58 Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 11:58 UTC (permalink / raw)
  To: lvm-devel

smtp didn't like me



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

* [PATCH 01/11] debian: fix library search path in example.conf
@ 2009-10-08 11:58   ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 11:58 UTC (permalink / raw)
  To: lvm-devel

this patch is debian specific and sets the library search path
to /lib/lvm2 to avoid cluttering /lib

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 1067665... 46c4dba... M	doc/example.conf
 doc/example.conf |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/doc/example.conf b/doc/example.conf
index 1067665..46c4dba 100644
--- a/doc/example.conf
+++ b/doc/example.conf
@@ -312,7 +312,7 @@ global {
     # Full pathnames can be given.
 
     # Search this directory first for shared libraries.
-    #   library_dir = "/lib"
+    #   library_dir = "/lib/lvm2"
 
     # The external locking library to load if locking_type is set to 2.
     #   locking_library = "liblvm2clusterlock.so"
-- 
1.5.4.3



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

* RFC - Debian patches (resend - one more time)
@ 2009-10-08 12:16 Fabio M. Di Nitto
  2009-10-08 12:49   ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:16 UTC (permalink / raw)
  To: lvm-devel

Sorry for the repost.. there has been some technical issues with SMTP server



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

* [PATCH 01/11] debian: fix library search path in example.conf
@ 2009-10-08 11:58   ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:16 UTC (permalink / raw)
  To: lvm-devel

this patch is debian specific and sets the library search path
to /lib/lvm2 to avoid cluttering /lib

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 1067665... 46c4dba... M	doc/example.conf
 doc/example.conf |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/doc/example.conf b/doc/example.conf
index 1067665..46c4dba 100644
--- a/doc/example.conf
+++ b/doc/example.conf
@@ -312,7 +312,7 @@ global {
     # Full pathnames can be given.
 
     # Search this directory first for shared libraries.
-    #   library_dir = "/lib"
+    #   library_dir = "/lib/lvm2"
 
     # The external locking library to load if locking_type is set to 2.
     #   locking_library = "liblvm2clusterlock.so"
-- 
1.5.4.3



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

* [PATCH 02/11] debian: drop realtime
@ 2009-10-08 12:49   ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:16 UTC (permalink / raw)
  To: lvm-devel

the realtime support is completely unused and just includes another library
dependency

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 b4e7f28... 45dc2c9... M	configure.in
:100644 100644 2bd6fba... d4e24d4... M	lib/Makefile.in
:100644 000000 62e1be8... 0000000... D	lib/misc/timestamp.c
:100644 000000 50e2a85... 0000000... D	lib/misc/timestamp.h
 configure.in         |   23 ---------
 lib/Makefile.in      |    1 -
 lib/misc/timestamp.c |  130 --------------------------------------------------
 lib/misc/timestamp.h |   33 -------------
 4 files changed, 0 insertions(+), 187 deletions(-)

diff --git a/configure.in b/configure.in
index b4e7f28..45dc2c9 100644
--- a/configure.in
+++ b/configure.in
@@ -40,7 +40,6 @@ case "$host_os" in
 		ODIRECT=yes
 		DM_IOCTLS=yes
 		SELINUX=yes
-		REALTIME=yes
 		CLUSTER=internal
 		FSADM=yes
 		;;
@@ -55,7 +54,6 @@ case "$host_os" in
 		ODIRECT=no
 		DM_IOCTLS=no
 		SELINUX=no
-		REALTIME=no
 		CLUSTER=none
 		FSADM=no
 		;;
@@ -316,13 +314,6 @@ AC_ARG_ENABLE([readline],
 AC_MSG_RESULT($READLINE)
 
 ################################################################################
-dnl -- Disable realtime clock support
-AC_MSG_CHECKING(whether to enable realtime support)
-AC_ARG_ENABLE(realtime, [  --disable-realtime      Disable realtime clock support],
-REALTIME=$enableval)
-AC_MSG_RESULT($REALTIME)
-
-################################################################################
 dnl -- Init pkg-config with dummy invokation:
 dnl -- this is required because PKG_CHECK_MODULES macro is expanded
 dnl -- to initialize the pkg-config environment only at the first invokation,
@@ -868,19 +859,6 @@ if test x$SELINUX = xyes; then
 fi
 
 ################################################################################
-dnl -- Check for realtime clock support
-if test x$REALTIME = xyes; then
-	AC_CHECK_LIB(rt, clock_gettime, HAVE_REALTIME=yes, HAVE_REALTIME=no)
-
-	if test x$HAVE_REALTIME = xyes; then
-		AC_DEFINE([HAVE_REALTIME], 1, [Define to 1 to include support for realtime clock.])
-		LIBS="-lrt $LIBS"
-	else
-		AC_MSG_WARN(Disabling realtime clock)
-	fi
-fi
-
-################################################################################
 dnl -- Check for getopt
 AC_CHECK_HEADERS(getopt.h, AC_DEFINE([HAVE_GETOPTLONG], 1, [Define to 1 if getopt_long is available.]))
 
@@ -1098,7 +1076,6 @@ AC_SUBST(GROUP)
 AC_SUBST(GULM_CFLAGS)
 AC_SUBST(GULM_LIBS)
 AC_SUBST(HAVE_LIBDL)
-AC_SUBST(HAVE_REALTIME)
 AC_SUBST(HAVE_SELINUX)
 AC_SUBST(INTL)
 AC_SUBST(INTL_PACKAGE)
diff --git a/lib/Makefile.in b/lib/Makefile.in
index 2bd6fba..d4e24d4 100644
--- a/lib/Makefile.in
+++ b/lib/Makefile.in
@@ -82,7 +82,6 @@ SOURCES =\
 	misc/lvm-globals.c \
 	misc/lvm-string.c \
 	misc/lvm-wrappers.c \
-	misc/timestamp.c \
 	misc/util.c \
 	mm/memlock.c \
 	report/report.c \
diff --git a/lib/misc/timestamp.c b/lib/misc/timestamp.c
deleted file mode 100644
index 62e1be8..0000000
--- a/lib/misc/timestamp.c
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (C) 2006 Rackable Systems All rights reserved.
- *
- * This file is part of LVM2.
- *
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU Lesser General Public License v.2.1.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-/*
- * Abstract out the time methods used so they can be adjusted later -
- * the results of these routines should stay in-core.  This implementation
- * requires librt.
- */
-
-#include "lib.h"
-#include <stdlib.h>
-
-#include "timestamp.h"
-
-/*
- * The realtime section uses clock_gettime with the CLOCK_MONOTONIC
- * parameter to prevent issues with time warps
- */
-#ifdef HAVE_REALTIME
-
-#include <time.h>
-#include <bits/time.h>
-
-struct timestamp {
-	struct timespec t;
-};
-
-struct timestamp *get_timestamp(void)
-{
-	struct timestamp *ts = NULL;
-
-	if (!(ts = dm_malloc(sizeof(*ts))))
-		return_NULL;
-
-	if (clock_gettime(CLOCK_MONOTONIC, &ts->t)) {
-		log_sys_error("clock_gettime", "get_timestamp");
-		return NULL;
-	}
-
-	return ts;
-}
-
-/* cmp_timestamp: Compare two timestamps
- *
- * Return: -1 if t1 is less than t2
- *          0 if t1 is equal to t2
- *          1 if t1 is greater than t2
- */
-int cmp_timestamp(struct timestamp *t1, struct timestamp *t2)
-{
-	if(t1->t.tv_sec < t2->t.tv_sec)
-		return -1;
-	if(t1->t.tv_sec > t2->t.tv_sec)
-		return 1;
-
-	if(t1->t.tv_nsec < t2->t.tv_nsec)
-		return -1;
-	if(t1->t.tv_nsec > t2->t.tv_nsec)
-		return 1;
-
-	return 0;
-}
-
-#else /* ! HAVE_REALTIME */
-
-/*
- * The !realtime section just uses gettimeofday and is therefore subject
- * to ntp-type time warps - not sure if should allow that.
- */
-
-#include <sys/time.h>
-
-struct timestamp {
-	struct timeval t;
-};
-
-struct timestamp *get_timestamp(void)
-{
-	struct timestamp *ts = NULL;
-
-	if (!(ts = dm_malloc(sizeof(*ts))))
-		return_NULL;
-
-	if (gettimeofday(&ts->t, NULL)) {
-		log_sys_error("gettimeofday", "get_timestamp");
-		return NULL;
-	}
-
-	return ts;
-}
-
-/* cmp_timestamp: Compare two timestamps
- *
- * Return: -1 if t1 is less than t2
- *          0 if t1 is equal to t2
- *          1 if t1 is greater than t2
- */
-int cmp_timestamp(struct timestamp *t1, struct timestamp *t2)
-{
-	if(t1->t.tv_sec < t2->t.tv_sec)
-		return -1;
-	if(t1->t.tv_sec > t2->t.tv_sec)
-		return 1;
-
-	if(t1->t.tv_usec < t2->t.tv_usec)
-		return -1;
-	if(t1->t.tv_usec > t2->t.tv_usec)
-		return 1;
-
-	return 0;
-}
-
-#endif /* HAVE_REALTIME */
-
-void destroy_timestamp(struct timestamp *t)
-{
-	if (t)
-		dm_free(t);
-}
diff --git a/lib/misc/timestamp.h b/lib/misc/timestamp.h
deleted file mode 100644
index 50e2a85..0000000
--- a/lib/misc/timestamp.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2006 Rackable Systems All rights reserved.  
- *
- * This file is part of LVM2.
- *
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU Lesser General Public License v.2.1.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-#ifndef _LVM_TIMESTAMP_H
-#define _LVM_TIMESTAMP_H
-
-struct timestamp;
-
-struct timestamp *get_timestamp(void);
-
-/* cmp_timestamp: Compare two timestamps
- * 
- * Return: -1 if t1 is less than t2
- *  	    0 if t1 is equal to t2
- *          1 if t1 is greater than t2
- */
-int cmp_timestamp(struct timestamp *t1, struct timestamp *t2);
-
-void destroy_timestamp(struct timestamp *t);
-
-#endif /* _LVM_TIMESTAMP_H */
-
-- 
1.5.4.3



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

* RFC - Debian patches (full set)
@ 2009-10-08 12:49 Fabio M. Di Nitto
  2009-10-08 12:49 ` [PATCH 03/11] debian: force modprobe Fabio M. Di Nitto
                   ` (8 more replies)
  0 siblings, 9 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

I am out of luck today..



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

* [PATCH 01/11] debian: fix library search path in example.conf
@ 2009-10-08 11:58   ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

this patch is debian specific and sets the library search path
to /lib/lvm2 to avoid cluttering /lib

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 1067665... 46c4dba... M	doc/example.conf
 doc/example.conf |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/doc/example.conf b/doc/example.conf
index 1067665..46c4dba 100644
--- a/doc/example.conf
+++ b/doc/example.conf
@@ -312,7 +312,7 @@ global {
     # Full pathnames can be given.
 
     # Search this directory first for shared libraries.
-    #   library_dir = "/lib"
+    #   library_dir = "/lib/lvm2"
 
     # The external locking library to load if locking_type is set to 2.
     #   locking_library = "liblvm2clusterlock.so"
-- 
1.5.4.3



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

* [PATCH 02/11] debian: drop realtime
@ 2009-10-08 12:49   ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

the realtime support is completely unused and just includes another library
dependency

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 b4e7f28... 45dc2c9... M	configure.in
:100644 100644 2bd6fba... d4e24d4... M	lib/Makefile.in
:100644 000000 62e1be8... 0000000... D	lib/misc/timestamp.c
:100644 000000 50e2a85... 0000000... D	lib/misc/timestamp.h
 configure.in         |   23 ---------
 lib/Makefile.in      |    1 -
 lib/misc/timestamp.c |  130 --------------------------------------------------
 lib/misc/timestamp.h |   33 -------------
 4 files changed, 0 insertions(+), 187 deletions(-)

diff --git a/configure.in b/configure.in
index b4e7f28..45dc2c9 100644
--- a/configure.in
+++ b/configure.in
@@ -40,7 +40,6 @@ case "$host_os" in
 		ODIRECT=yes
 		DM_IOCTLS=yes
 		SELINUX=yes
-		REALTIME=yes
 		CLUSTER=internal
 		FSADM=yes
 		;;
@@ -55,7 +54,6 @@ case "$host_os" in
 		ODIRECT=no
 		DM_IOCTLS=no
 		SELINUX=no
-		REALTIME=no
 		CLUSTER=none
 		FSADM=no
 		;;
@@ -316,13 +314,6 @@ AC_ARG_ENABLE([readline],
 AC_MSG_RESULT($READLINE)
 
 ################################################################################
-dnl -- Disable realtime clock support
-AC_MSG_CHECKING(whether to enable realtime support)
-AC_ARG_ENABLE(realtime, [  --disable-realtime      Disable realtime clock support],
-REALTIME=$enableval)
-AC_MSG_RESULT($REALTIME)
-
-################################################################################
 dnl -- Init pkg-config with dummy invokation:
 dnl -- this is required because PKG_CHECK_MODULES macro is expanded
 dnl -- to initialize the pkg-config environment only at the first invokation,
@@ -868,19 +859,6 @@ if test x$SELINUX = xyes; then
 fi
 
 ################################################################################
-dnl -- Check for realtime clock support
-if test x$REALTIME = xyes; then
-	AC_CHECK_LIB(rt, clock_gettime, HAVE_REALTIME=yes, HAVE_REALTIME=no)
-
-	if test x$HAVE_REALTIME = xyes; then
-		AC_DEFINE([HAVE_REALTIME], 1, [Define to 1 to include support for realtime clock.])
-		LIBS="-lrt $LIBS"
-	else
-		AC_MSG_WARN(Disabling realtime clock)
-	fi
-fi
-
-################################################################################
 dnl -- Check for getopt
 AC_CHECK_HEADERS(getopt.h, AC_DEFINE([HAVE_GETOPTLONG], 1, [Define to 1 if getopt_long is available.]))
 
@@ -1098,7 +1076,6 @@ AC_SUBST(GROUP)
 AC_SUBST(GULM_CFLAGS)
 AC_SUBST(GULM_LIBS)
 AC_SUBST(HAVE_LIBDL)
-AC_SUBST(HAVE_REALTIME)
 AC_SUBST(HAVE_SELINUX)
 AC_SUBST(INTL)
 AC_SUBST(INTL_PACKAGE)
diff --git a/lib/Makefile.in b/lib/Makefile.in
index 2bd6fba..d4e24d4 100644
--- a/lib/Makefile.in
+++ b/lib/Makefile.in
@@ -82,7 +82,6 @@ SOURCES =\
 	misc/lvm-globals.c \
 	misc/lvm-string.c \
 	misc/lvm-wrappers.c \
-	misc/timestamp.c \
 	misc/util.c \
 	mm/memlock.c \
 	report/report.c \
diff --git a/lib/misc/timestamp.c b/lib/misc/timestamp.c
deleted file mode 100644
index 62e1be8..0000000
--- a/lib/misc/timestamp.c
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Copyright (C) 2006 Rackable Systems All rights reserved.
- *
- * This file is part of LVM2.
- *
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU Lesser General Public License v.2.1.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-/*
- * Abstract out the time methods used so they can be adjusted later -
- * the results of these routines should stay in-core.  This implementation
- * requires librt.
- */
-
-#include "lib.h"
-#include <stdlib.h>
-
-#include "timestamp.h"
-
-/*
- * The realtime section uses clock_gettime with the CLOCK_MONOTONIC
- * parameter to prevent issues with time warps
- */
-#ifdef HAVE_REALTIME
-
-#include <time.h>
-#include <bits/time.h>
-
-struct timestamp {
-	struct timespec t;
-};
-
-struct timestamp *get_timestamp(void)
-{
-	struct timestamp *ts = NULL;
-
-	if (!(ts = dm_malloc(sizeof(*ts))))
-		return_NULL;
-
-	if (clock_gettime(CLOCK_MONOTONIC, &ts->t)) {
-		log_sys_error("clock_gettime", "get_timestamp");
-		return NULL;
-	}
-
-	return ts;
-}
-
-/* cmp_timestamp: Compare two timestamps
- *
- * Return: -1 if t1 is less than t2
- *          0 if t1 is equal to t2
- *          1 if t1 is greater than t2
- */
-int cmp_timestamp(struct timestamp *t1, struct timestamp *t2)
-{
-	if(t1->t.tv_sec < t2->t.tv_sec)
-		return -1;
-	if(t1->t.tv_sec > t2->t.tv_sec)
-		return 1;
-
-	if(t1->t.tv_nsec < t2->t.tv_nsec)
-		return -1;
-	if(t1->t.tv_nsec > t2->t.tv_nsec)
-		return 1;
-
-	return 0;
-}
-
-#else /* ! HAVE_REALTIME */
-
-/*
- * The !realtime section just uses gettimeofday and is therefore subject
- * to ntp-type time warps - not sure if should allow that.
- */
-
-#include <sys/time.h>
-
-struct timestamp {
-	struct timeval t;
-};
-
-struct timestamp *get_timestamp(void)
-{
-	struct timestamp *ts = NULL;
-
-	if (!(ts = dm_malloc(sizeof(*ts))))
-		return_NULL;
-
-	if (gettimeofday(&ts->t, NULL)) {
-		log_sys_error("gettimeofday", "get_timestamp");
-		return NULL;
-	}
-
-	return ts;
-}
-
-/* cmp_timestamp: Compare two timestamps
- *
- * Return: -1 if t1 is less than t2
- *          0 if t1 is equal to t2
- *          1 if t1 is greater than t2
- */
-int cmp_timestamp(struct timestamp *t1, struct timestamp *t2)
-{
-	if(t1->t.tv_sec < t2->t.tv_sec)
-		return -1;
-	if(t1->t.tv_sec > t2->t.tv_sec)
-		return 1;
-
-	if(t1->t.tv_usec < t2->t.tv_usec)
-		return -1;
-	if(t1->t.tv_usec > t2->t.tv_usec)
-		return 1;
-
-	return 0;
-}
-
-#endif /* HAVE_REALTIME */
-
-void destroy_timestamp(struct timestamp *t)
-{
-	if (t)
-		dm_free(t);
-}
diff --git a/lib/misc/timestamp.h b/lib/misc/timestamp.h
deleted file mode 100644
index 50e2a85..0000000
--- a/lib/misc/timestamp.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (C) 2006 Rackable Systems All rights reserved.  
- *
- * This file is part of LVM2.
- *
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU Lesser General Public License v.2.1.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-#ifndef _LVM_TIMESTAMP_H
-#define _LVM_TIMESTAMP_H
-
-struct timestamp;
-
-struct timestamp *get_timestamp(void);
-
-/* cmp_timestamp: Compare two timestamps
- * 
- * Return: -1 if t1 is less than t2
- *  	    0 if t1 is equal to t2
- *          1 if t1 is greater than t2
- */
-int cmp_timestamp(struct timestamp *t1, struct timestamp *t2);
-
-void destroy_timestamp(struct timestamp *t);
-
-#endif /* _LVM_TIMESTAMP_H */
-
-- 
1.5.4.3



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

* [PATCH 03/11] debian: force modprobe
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-08 23:30   ` Alasdair G Kergon
  2009-10-08 12:49 ` [PATCH 04/11] debian: fix implicit pointer Fabio M. Di Nitto
                   ` (7 subsequent siblings)
  8 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

well, a linux system without modprobe can't use any modules.
so this just assumes that it is available in a real system

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 45dc2c9... 06759b6... M	configure.in
 configure.in |    6 +-----
 1 files changed, 1 insertions(+), 5 deletions(-)

diff --git a/configure.in b/configure.in
index 45dc2c9..06759b6 100644
--- a/configure.in
+++ b/configure.in
@@ -974,11 +974,7 @@ if test x$UDEV_SYNC = xyes; then
 fi
 
 ################################################################################
-AC_PATH_PROG(MODPROBE_CMD, modprobe)
-
-if test x$MODPROBE_CMD != x; then
-	AC_DEFINE_UNQUOTED([MODPROBE_CMD], ["$MODPROBE_CMD"], [The path to 'modprobe', if available.])
-fi
+AC_DEFINE_UNQUOTED([MODPROBE_CMD], ["/sbin/modprobe"], [The path to 'modprobe', if available.])
 
 ################################################################################
 dnl -- dmeventd pidfile and executable path
-- 
1.5.4.3



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

* [PATCH 04/11] debian: fix implicit pointer
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
  2009-10-08 12:49 ` [PATCH 03/11] debian: force modprobe Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-08 23:34   ` Alasdair G Kergon
  2009-10-08 12:49 ` [PATCH 05/11] debian: keep libdm-abi consistent Fabio M. Di Nitto
                   ` (6 subsequent siblings)
  8 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

not sure why the ifdef does not fire, but this is a readline function
and must not be redefined

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 e1f7900... 257cc40... M	tools/lvm.c
 tools/lvm.c |    3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/tools/lvm.c b/tools/lvm.c
index e1f7900..257cc40 100644
--- a/tools/lvm.c
+++ b/tools/lvm.c
@@ -25,9 +25,6 @@ int main(int argc, char **argv)
 
 #  include <readline/readline.h>
 #  include <readline/history.h>
-#  ifndef HAVE_RL_COMPLETION_MATCHES
-#    define rl_completion_matches(a, b) completion_matches((char *)a, b)
-#  endif
 
 static struct cmdline_context *_cmdline;
 
-- 
1.5.4.3



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

* [PATCH 05/11] debian: keep libdm-abi consistent
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
  2009-10-08 12:49 ` [PATCH 03/11] debian: force modprobe Fabio M. Di Nitto
  2009-10-08 12:49 ` [PATCH 04/11] debian: fix implicit pointer Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-08 23:35   ` Alasdair G Kergon
  2009-10-08 12:49 ` [PATCH 06/11] debian/ubuntu: make the device node creation more atomic Fabio M. Di Nitto
                   ` (5 subsequent siblings)
  8 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

don't change the ABI of libdm on selinux enable, just make the selinux
function a NOP

Also noted by Alasdair that some other feature set affects the libdm ABI.

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 e412cff... 6e4f91a... M	lib/activate/fs.c
:100644 100644 175d8d1... 248d3ac... M	libdm/libdm-common.c
 lib/activate/fs.c    |    2 --
 libdm/libdm-common.c |    6 ++----
 2 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/lib/activate/fs.c b/lib/activate/fs.c
index e412cff..6e4f91a 100644
--- a/lib/activate/fs.c
+++ b/lib/activate/fs.c
@@ -201,10 +201,8 @@ static int _mk_link(const char *dev_dir, const char *vg_name,
 		return 0;
 	}
 
-#ifdef HAVE_SELINUX
 	if (!dm_set_selinux_context(lv_path, S_IFLNK))
 		return_0;
-#endif
 
 	return 1;
 }
diff --git a/libdm/libdm-common.c b/libdm/libdm-common.c
index 175d8d1..248d3ac 100644
--- a/libdm/libdm-common.c
+++ b/libdm/libdm-common.c
@@ -373,9 +373,9 @@ int dm_task_add_target(struct dm_task *dmt, uint64_t start, uint64_t size,
 	return 1;
 }
 
-#ifdef HAVE_SELINUX
 int dm_set_selinux_context(const char *path, mode_t mode)
 {
+#ifdef HAVE_SELINUX
 	security_context_t scontext;
 
 	if (is_selinux_enabled() <= 0)
@@ -396,9 +396,9 @@ int dm_set_selinux_context(const char *path, mode_t mode)
 	}
 
 	freecon(scontext);
+#endif
 	return 1;
 }
-#endif
 
 static int _add_dev_node(const char *dev_name, uint32_t major, uint32_t minor,
 			 uid_t uid, gid_t gid, mode_t mode)
@@ -445,10 +445,8 @@ static int _add_dev_node(const char *dev_name, uint32_t major, uint32_t minor,
 
 	log_debug("Created %s", path);
 
-#ifdef HAVE_SELINUX
 	if (!dm_set_selinux_context(path, S_IFBLK))
 		return 0;
-#endif
 
 	return 1;
 }
-- 
1.5.4.3



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

* [PATCH 06/11] debian/ubuntu: make the device node creation more atomic
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
                   ` (2 preceding siblings ...)
  2009-10-08 12:49 ` [PATCH 05/11] debian: keep libdm-abi consistent Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-08 23:39   ` Alasdair G Kergon
  2009-10-08 12:49 ` [PATCH 07/11] debian: workaround for broken kernel headers Fabio M. Di Nitto
                   ` (4 subsequent siblings)
  8 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=455745

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 248d3ac... 90e0907... M	libdm/libdm-common.c
 libdm/libdm-common.c |   32 ++++++++++++++++++++++++--------
 1 files changed, 24 insertions(+), 8 deletions(-)

diff --git a/libdm/libdm-common.c b/libdm/libdm-common.c
index 248d3ac..90e0907 100644
--- a/libdm/libdm-common.c
+++ b/libdm/libdm-common.c
@@ -403,12 +403,19 @@ int dm_set_selinux_context(const char *path, mode_t mode)
 static int _add_dev_node(const char *dev_name, uint32_t major, uint32_t minor,
 			 uid_t uid, gid_t gid, mode_t mode)
 {
-	char path[PATH_MAX];
+	char path[PATH_MAX], tmppath[PATH_MAX];
 	struct stat info;
 	dev_t dev = MKDEV(major, minor);
 	mode_t old_mask;
 
 	_build_dev_path(path, sizeof(path), dev_name);
+	_build_dev_path(tmppath, sizeof(tmppath), ".XXXXXX");
+
+	mktemp(tmppath);
+	if (strlen(tmppath) == 0) {
+		log_error("Unable to create name of temporary file");
+		return 0;
+	}
 
 	if (stat(path, &info) >= 0) {
 		if (!S_ISBLK(info.st_mode)) {
@@ -431,24 +438,33 @@ static int _add_dev_node(const char *dev_name, uint32_t major, uint32_t minor,
 			 "node creation.", path);
 
 	old_mask = umask(0);
-	if (mknod(path, S_IFBLK | mode, dev) < 0) {
+	if (mknod(tmppath, S_IFBLK | mode, dev) < 0) {
 		umask(old_mask);
 		log_error("Unable to make device node for '%s'", dev_name);
-		return 0;
+		goto error;
 	}
 	umask(old_mask);
 
-	if (chown(path, uid, gid) < 0) {
+	if (chown(tmppath, uid, gid) < 0) {
 		log_sys_error("chown", path);
-		return 0;
+		goto error;
 	}
 
-	log_debug("Created %s", path);
+	if (!dm_set_selinux_context(tmppath, S_IFBLK))
+		goto error;
 
-	if (!dm_set_selinux_context(path, S_IFBLK))
-		return 0;
+	if (rename(tmppath, path) < 0) {
+		log_error("Unable to replace device node for '%s'", dev_name);
+		goto error;
+	}
+
+	log_debug("Created %s", path);
 
 	return 1;
+
+error:
+	unlink(tmppath);
+	return 0;
 }
 
 static int _rm_dev_node(const char *dev_name)
-- 
1.5.4.3



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

* [PATCH 07/11] debian: workaround for broken kernel headers
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
                   ` (3 preceding siblings ...)
  2009-10-08 12:49 ` [PATCH 06/11] debian/ubuntu: make the device node creation more atomic Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-08 23:41   ` Alasdair G Kergon
  2009-10-12  8:57   ` Fabio M. Di Nitto
  2009-10-08 12:49 ` [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding Fabio M. Di Nitto
                   ` (3 subsequent siblings)
  8 siblings, 2 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

this patch might be debian specific and needs more investigation.

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 5ba63ce... a8edf55... M	libdm/ioctl/libdm-compat.h
:100644 100644 5fcda74... ec990d7... M	libdm/misc/kdev_t.h
 libdm/ioctl/libdm-compat.h |    5 +++--
 libdm/misc/kdev_t.h        |    4 ++++
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/libdm/ioctl/libdm-compat.h b/libdm/ioctl/libdm-compat.h
index 5ba63ce..a8edf55 100644
--- a/libdm/ioctl/libdm-compat.h
+++ b/libdm/ioctl/libdm-compat.h
@@ -19,6 +19,7 @@
 #include "kdev_t.h"
 #include "dm-ioctl.h"
 #include <inttypes.h>
+#include <linux/types.h>
 #include <sys/ioctl.h>
 
 struct dm_task;
@@ -40,7 +41,7 @@ struct dm_ioctl_v1 {
 	int32_t open_count;	/* out */
 	uint32_t flags;		/* in/out */
 
-	__kernel_dev_t dev;	/* in/out */
+	devmapper_kernel_dev_t dev;	/* in/out */
 
 	char name[DM_NAME_LEN];	/* device name */
 	char uuid[DM_UUID_LEN];	/* unique identifier for
@@ -60,7 +61,7 @@ struct dm_target_spec_v1 {
 struct dm_target_deps_v1 {
 	uint32_t count;
 
-	__kernel_dev_t dev[0];	/* out */
+	devmapper_kernel_dev_t dev[0];	/* out */
 };
 
 enum {
diff --git a/libdm/misc/kdev_t.h b/libdm/misc/kdev_t.h
index 5fcda74..ec990d7 100644
--- a/libdm/misc/kdev_t.h
+++ b/libdm/misc/kdev_t.h
@@ -15,8 +15,12 @@
 #ifndef _LIBDM_KDEV_H
 #define _LIBDM_KDEV_H
 
+#include <linux/types.h>
+
 #define MAJOR(dev)      ((dev & 0xfff00) >> 8)
 #define MINOR(dev)      ((dev & 0xff) | ((dev >> 12) & 0xfff00))
 #define MKDEV(ma,mi)    ((mi & 0xff) | (ma << 8) | ((mi & ~0xff) << 12))
 
+typedef __u32 devmapper_kernel_dev_t;
+
 #endif
-- 
1.5.4.3



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

* [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
                   ` (4 preceding siblings ...)
  2009-10-08 12:49 ` [PATCH 07/11] debian: workaround for broken kernel headers Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-08 23:44   ` Alasdair G Kergon
  2009-10-08 12:49 ` [PATCH 09/11] debian: libs cleanup Fabio M. Di Nitto
                   ` (2 subsequent siblings)
  8 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

use selinux pkgconfig file instead of hardcoding the contents

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 b657090... d4ca036... M	libdm/libdevmapper.pc.in
 libdm/libdevmapper.pc.in |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libdm/libdevmapper.pc.in b/libdm/libdevmapper.pc.in
index b657090..d4ca036 100644
--- a/libdm/libdevmapper.pc.in
+++ b/libdm/libdevmapper.pc.in
@@ -8,4 +8,4 @@ Description: device-mapper library
 Version: @DM_LIB_PATCHLEVEL@
 Cflags: -I${includedir} 
 Libs: -L${libdir} -ldevmapper
-Libs.private: @SELINUX_LIBS@
+Requires.private: libselinux
-- 
1.5.4.3



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

* [PATCH 09/11] debian: libs cleanup
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
                   ` (5 preceding siblings ...)
  2009-10-08 12:49 ` [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-09  0:02   ` Alasdair G Kergon
  2009-10-08 12:49 ` [PATCH 10/11] debian: make the subdir recursion -j capable Fabio M. Di Nitto
  2009-10-08 12:49 ` [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions Fabio M. Di Nitto
  8 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

patch with several changes on how libs are found and used
(selinux and readline)

patch is not clean or ready for submission

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 06759b6... ad871fd... M	configure.in
:100644 100644 207c0e2... 2a14ba6... M	daemons/dmeventd/Makefile.in
:100644 100644 4273eeb... f20ad5d... M	lib/misc/configure.h.in
:100644 100644 6dd25ff... 191e2ae... M	libdm/Makefile.in
:100644 100644 6d12920... 5464188... M	make.tmpl.in
:100644 100644 5702f4f... 4f8be22... M	tools/Makefile.in
 configure.in                 |   57 +++++------------------------------------
 daemons/dmeventd/Makefile.in |    2 +-
 lib/misc/configure.h.in      |   14 +++-------
 libdm/Makefile.in            |    4 +-
 make.tmpl.in                 |    5 +--
 tools/Makefile.in            |   14 +++++-----
 6 files changed, 23 insertions(+), 73 deletions(-)

diff --git a/configure.in b/configure.in
index 06759b6..ad871fd 100644
--- a/configure.in
+++ b/configure.in
@@ -34,7 +34,6 @@ case "$host_os" in
 		CLDWHOLEARCHIVE="-Wl,-whole-archive"
 		CLDNOWHOLEARCHIVE="-Wl,-no-whole-archive"
 		LDDEPS="$LDDEPS .export.sym"
-		LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
 		LIB_SUFFIX=so
 		DEVMAPPER=yes
 		ODIRECT=yes
@@ -779,24 +778,6 @@ if [[ "x$exec_prefix" = xNONE -a "x$prefix" = xNONE ]];
 fi;
 
 ################################################################################
-dnl -- Check for termcap (Shamelessly copied from parted 1.4.17)
-if test x$READLINE != xno; then
-	AC_SEARCH_LIBS([tgetent], [tinfo ncurses curses termcap termlib],
-	  [tg_found=yes], [tg_found=no])
-	test x$READLINE:$tg_found = xyes:no &&
-	  AC_MSG_ERROR(
-termcap could not be found which is required for the
---enable-readline option (which is enabled by default).  Either disable readline
-support with --disable-readline or download and install termcap from:
-	ftp.gnu.org/gnu/termcap
-Note: if you are using precompiled packages you will also need the development
-  package as well (which may be called termcap-devel or something similar).
-Note: (n)curses also seems to work as a substitute for termcap.  This was
-  not found either - but you could try installing that as well.
-)
-fi
-
-################################################################################
 dnl -- Check for dlopen
 AC_CHECK_LIB(dl, dlopen, HAVE_LIBDL=yes, HAVE_LIBDL=no)
 
@@ -827,35 +808,9 @@ AC_MSG_RESULT($SELINUX)
 ################################################################################
 dnl -- Check for selinux
 if test x$SELINUX = xyes; then
-	AC_CHECK_LIB(sepol, sepol_check_context, HAVE_SEPOL=yes, HAVE_SEPOL=no)
-
-	if test x$HAVE_SEPOL = xyes; then
-		AC_DEFINE([HAVE_SEPOL], 1,
-		  [Define to 1 if sepol_check_context is available.])
-		SELINUX_LIBS="-lsepol $SELINUX_LIBS"
-	fi
-
-	AC_CHECK_LIB(selinux, is_selinux_enabled, HAVE_SELINUX=yes, HAVE_SELINUX=no)
-
-	if test x$HAVE_SELINUX = xyes; then
-		AC_DEFINE([HAVE_SELINUX], 1, [Define to 1 to include support for selinux.])
-		SELINUX_LIBS="-lselinux $SELINUX_LIBS"
-	else
-		AC_MSG_WARN(Disabling selinux)
-	fi
-	LIBS="$SELINUX_LIBS $LIBS"
-
-	# With --enable-static_link and selinux enabled, linking
-	# fails on at least Debian unstable due to unsatisfied references
-	# to pthread_mutex_lock and _unlock.  See if we need -lpthread.
-	if test "$STATIC_LINK-$HAVE_SELINUX" = yes-yes; then
-		lvm_saved_libs=$LIBS
-		LIBS="$LIBS -static"
-		AC_SEARCH_LIBS([pthread_mutex_lock], [pthread],
-		  [test "$ac_cv_search_pthread_mutex_lock" = "none required" ||
-				LIB_PTHREAD=-lpthread])
-		LIBS=$lvm_saved_libs
-	fi
+	AC_DEFINE([HAVE_SELINUX], 1, [Define to 1 to include support for selinux.])
+	LIBS_SELINUX="$(pkg-config --libs libselinux)"
+	LIBS_SELINUX_STATIC="$(pkg-config --libs --static libselinux)"
 fi
 
 ################################################################################
@@ -866,7 +821,7 @@ AC_CHECK_HEADERS(getopt.h, AC_DEFINE([HAVE_GETOPTLONG], 1, [Define to 1 if getop
 dnl -- Check for readline (Shamelessly copied from parted 1.4.17)
 if test x$READLINE != xno; then
 	rl_found=yes
-	AC_CHECK_LIB([readline], [readline], , [rl_found=no])
+	AC_CHECK_LIB([readline], [readline], [LIBS_READLINE="-lreadline $LIBS_READLINE"], [rl_found=no])
 	test x$READLINE:$rl_found = xyes:no &&
 	  AC_MSG_ERROR(
 GNU Readline could not be found which is required for the
@@ -1078,6 +1033,9 @@ AC_SUBST(INTL_PACKAGE)
 AC_SUBST(JOBS)
 AC_SUBST(LDDEPS)
 AC_SUBST(LIBS)
+AC_SUBST(LIBS_READLINE)
+AC_SUBST(LIBS_SELINUX)
+AC_SUBST(LIBS_SELINUX_STATIC)
 AC_SUBST(LIB_SUFFIX)
 AC_SUBST(LOCALEDIR)
 AC_SUBST(LVM1)
@@ -1105,7 +1063,6 @@ AC_SUBST(SNAPSHOTS)
 AC_SUBST(STATICDIR)
 AC_SUBST(STATIC_LINK)
 AC_SUBST(UDEV_RULES)
-AC_SUBST([LIB_PTHREAD])
 AC_SUBST(interface)
 AC_SUBST(kerneldir)
 AC_SUBST(missingkernel)
diff --git a/daemons/dmeventd/Makefile.in b/daemons/dmeventd/Makefile.in
index 207c0e2..2a14ba6 100644
--- a/daemons/dmeventd/Makefile.in
+++ b/daemons/dmeventd/Makefile.in
@@ -46,7 +46,7 @@ LIBS += -ldl -ldevmapper -lpthread
 
 dmeventd: $(LIB_SHARED) $(VERSIONED_SHLIB) dmeventd.o
 	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ dmeventd.o \
-	-L. -ldevmapper-event $(LIBS) -rdynamic
+	-L. -ldevmapper-event
 
 .PHONY: install_dynamic install_static install_include \
 	install_pkgconfig install_dmeventd
diff --git a/lib/misc/configure.h.in b/lib/misc/configure.h.in
index 4273eeb..f20ad5d 100644
--- a/lib/misc/configure.h.in
+++ b/lib/misc/configure.h.in
@@ -120,9 +120,6 @@
 /* Define to 1 if you have the <libintl.h> header file. */
 #undef HAVE_LIBINTL_H
 
-/* Define to 1 if you have the `readline' library (-lreadline). */
-#undef HAVE_LIBREADLINE
-
 /* Define to 1 if you have the <limits.h> header file. */
 #undef HAVE_LIMITS_H
 
@@ -185,9 +182,6 @@
 /* Define to 1 if you have the <readline/readline.h> header file. */
 #undef HAVE_READLINE_READLINE_H
 
-/* Define to 1 to include support for realtime clock. */
-#undef HAVE_REALTIME
-
 /* Define to 1 if you have the `rl_completion_matches' function. */
 #undef HAVE_RL_COMPLETION_MATCHES
 
@@ -206,9 +200,6 @@
 /* Define to 1 if you have the <selinux/selinux.h> header file. */
 #undef HAVE_SELINUX_SELINUX_H
 
-/* Define to 1 if sepol_check_context is available. */
-#undef HAVE_SEPOL
-
 /* Define to 1 if you have the `setlocale' function. */
 #undef HAVE_SETLOCALE
 
@@ -273,7 +264,7 @@
 /* Define to 1 if you have the `strtoul' function. */
 #undef HAVE_STRTOUL
 
-/* Define to 1 if `st_rdev' is member of `struct stat'. */
+/* Define to 1 if `struct stat' is a member of `st_rdev'. */
 #undef HAVE_STRUCT_STAT_ST_RDEV
 
 /* Define to 1 if you have the <syslog.h> header file. */
@@ -410,6 +401,9 @@
 /* Define to the one symbol short name of this package. */
 #undef PACKAGE_TARNAME
 
+/* Define to the home page for this package. */
+#undef PACKAGE_URL
+
 /* Define to the version of this package. */
 #undef PACKAGE_VERSION
 
diff --git a/libdm/Makefile.in b/libdm/Makefile.in
index 6dd25ff..191e2ae 100644
--- a/libdm/Makefile.in
+++ b/libdm/Makefile.in
@@ -35,9 +35,7 @@ SOURCES =\
 
 INCLUDES = -I$(srcdir)/$(interface) -I$(srcdir)
 
-ifeq ("@STATIC_LINK@", "yes")
 LIB_STATIC = $(interface)/libdevmapper.a
-endif
 
 ifeq ("@LIB_SUFFIX@","dylib")
   LIB_SHARED = $(interface)/libdevmapper.dylib
@@ -47,6 +45,8 @@ endif
 VERSIONED_SHLIB = libdevmapper.$(LIB_SUFFIX).$(LIB_VERSION_DM)
 LIB_VERSION = $(LIB_VERSION_DM)
 
+LDFLAGS += @LIBS_SELINUX@
+
 DEFS += -DDM_DEVICE_UID=@DM_DEVICE_UID@ -DDM_DEVICE_GID=@DM_DEVICE_GID@ \
 	-DDM_DEVICE_MODE=@DM_DEVICE_MODE@
 
diff --git a/make.tmpl.in b/make.tmpl.in
index 6d12920..5464188 100644
--- a/make.tmpl.in
+++ b/make.tmpl.in
@@ -105,7 +105,6 @@ endif
 #DEFS += -DBOUNDS_CHECK
 
 #CFLAGS += -pg
-#LDFLAGS += -pg
 
 STRIP=
 #STRIP = -s
@@ -209,13 +208,13 @@ $(TARGETS): $(OBJECTS)
 ifeq ("@LIB_SUFFIX@","so")
 $(LIB_SHARED): $(OBJECTS) $(LDDEPS)
 	$(CC) -shared -Wl,-soname,$(notdir $@).$(LIB_VERSION) \
-	$(CFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
+	$(CFLAGS) $(LDFLAGS) $(CLDFLAGS) $(OBJECTS) -o $@
 endif
 
 ifeq ("@LIB_SUFFIX@","dylib")
 $(LIB_SHARED): $(OBJECTS) $(LDDEPS)
 	$(CC) -dynamiclib -dylib_current_version,$(LIB_VERSION) \
-	$(CFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
+	$(CFLAGS) $(LDFLAGS) $(CLDFLAGS) $(OBJECTS) -o $@
 endif
 
 %.so: %.a
diff --git a/tools/Makefile.in b/tools/Makefile.in
index 5702f4f..4f8be22 100644
--- a/tools/Makefile.in
+++ b/tools/Makefile.in
@@ -17,8 +17,6 @@ top_srcdir = @top_srcdir@
 top_builddir = @top_builddir@
 VPATH = @srcdir@
 
-LIB_PTHREAD = @LIB_PTHREAD@
-
 SOURCES =\
 	dumpconfig.c \
 	formats.c \
@@ -105,6 +103,9 @@ endif
 
 LVMLIBS += -ldevmapper
 
+LDFLAGS_DMSETUP_STATIC = @LIBS_SELINUX_STATIC@
+LDFLAGS_LVM = @LIBS_READLINE@
+
 DEFS += -DLVM_SHARED_PATH=\"$(exec_prefix)/sbin/lvm\"
 
 include ../make.tmpl
@@ -113,22 +114,21 @@ device-mapper: $(TARGETS_DM)
 
 dmsetup: dmsetup.o $(top_builddir)/libdm/libdevmapper.$(LIB_SUFFIX)
 	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ dmsetup.o \
-	      -L$(top_builddir)/libdm -ldevmapper $(LIBS) $(LIB_PTHREAD)
+	      -L$(top_builddir)/libdm -ldevmapper $(LIBS)
 
 dmsetup.static: dmsetup.o $(interfacedir)/libdevmapper.a
 	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ dmsetup.o -static \
-	      -L$(interfacedir) -ldevmapper $(LIBS) \
-	      $(LIB_PTHREAD)
+	      -L$(interfacedir) -ldevmapper $(LIBS) $(LDFLAGS_DMSETUP_STATIC)
 
 all: device-mapper
 
 lvm: $(OBJECTS) lvm.o $(top_builddir)/lib/liblvm-internal.a
 	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJECTS) lvm.o \
-		$(LVMLIBS) $(LIBS) $(LIB_PTHREAD) -rdynamic
+		$(LDFLAGS) $(LVMLIBS) $(LIBS) $(LDFLAGS_LVM) -rdynamic
 
 lvm.static: $(OBJECTS) lvm-static.o $(top_builddir)/lib/liblvm-internal.a  $(interfacedir)/libdevmapper.a
 	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJECTS) lvm-static.o -static \
-		-L$(interfacedir) $(LVMLIBS) $(LIBS) $(LIB_PTHREAD) -rdynamic
+		-L$(interfacedir) $(LVMLIBS) $(LIBS) -rdynamic
 
 liblvm2cmd.a: $(top_builddir)/lib/liblvm-internal.a $(OBJECTS) lvmcmdlib.o lvm2cmd.o
 	cat $(top_builddir)/lib/liblvm-internal.a > $@
-- 
1.5.4.3



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

* [PATCH 10/11] debian: make the subdir recursion -j capable
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
                   ` (6 preceding siblings ...)
  2009-10-08 12:49 ` [PATCH 09/11] debian: libs cleanup Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-08 23:57   ` Alasdair G Kergon
  2009-10-08 12:49 ` [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions Fabio M. Di Nitto
  8 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

but it removes some dependencies on the way

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 556d1ff... 2e8a010... M	Makefile.in
:100644 100644 5464188... 56dfa8b... M	make.tmpl.in
:100644 100644 f0c98fd... f0acb84... M	man/Makefile.in
 Makefile.in     |   27 +----------------------
 make.tmpl.in    |   64 +++++++++++-------------------------------------------
 man/Makefile.in |    4 +--
 3 files changed, 15 insertions(+), 80 deletions(-)

diff --git a/Makefile.in b/Makefile.in
index 556d1ff..2e8a010 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -27,7 +27,7 @@ ifeq ("@INTL@", "yes")
   SUBDIRS += po
 endif
 
-SUBDIRS += lib tools daemons libdm
+SUBDIRS += libdm lib tools daemons
 
 ifeq ("@APPLIB@", "yes")
   SUBDIRS += liblvm
@@ -54,31 +54,6 @@ endif
 
 include make.tmpl
 
-libdm: include
-lib: libdm
-liblvm: lib
-daemons: lib tools
-tools: lib device-mapper
-po: tools daemons
-
-libdm.device-mapper: include.device-mapper
-daemons.device-mapper: libdm.device-mapper
-tools.device-mapper: libdm.device-mapper
-device-mapper: tools.device-mapper daemons.device-mapper man.device-mapper
-
-ifeq ("@INTL@", "yes")
-lib.pofile: include.pofile
-tools.pofile: lib.pofile
-daemons.pofile: lib.pofile
-po.pofile: tools.pofile daemons.pofile
-pofile: po.pofile
-endif
-
-ifneq ("@CFLOW_CMD@", "")
-tools.cflow: lib.cflow
-cflow: tools.cflow
-endif
-
 ifneq ("@CSCOPE_CMD@", "")
 cscope.out: tools
 	@CSCOPE_CMD@ -b -R
diff --git a/make.tmpl.in b/make.tmpl.in
index 5464188..56dfa8b 100644
--- a/make.tmpl.in
+++ b/make.tmpl.in
@@ -132,65 +132,27 @@ POTFILES = $(SOURCES:%.c=%.pot)
 
 .PHONY: all install install_cluster pofile distclean clean cflow device-mapper 
 .PHONY: install_device-mapper install_lvm2
-.PHONY: $(SUBDIRS) $(SUBDIRS.install) $(SUBDIRS.clean) $(SUBDIRS.distclean)
-.PHONY: $(SUBDIRS.pofile) $(SUBDIRS.install_cluster) $(SUBDIRS.cflow)
-.PHONY: $(SUBDIRS.device-mapper) $(SUBDIRS.install-device-mapper)
-
-SUBDIRS.device-mapper := $(SUBDIRS:=.device-mapper)
-SUBDIRS.install := $(SUBDIRS:=.install)
-SUBDIRS.install_cluster := $(SUBDIRS:=.install_cluster)
-SUBDIRS.install_device-mapper := $(SUBDIRS:=.install_device-mapper)
-SUBDIRS.install_lvm2 := $(SUBDIRS:=.install_lvm2)
-SUBDIRS.pofile := $(SUBDIRS:=.pofile)
-SUBDIRS.cflow := $(SUBDIRS:=.cflow)
-SUBDIRS.clean := $(SUBDIRS:=.clean)
-SUBDIRS.distclean := $(SUBDIRS:=.distclean)
 
 TARGETS += $(LIB_SHARED) $(LIB_STATIC) $(VERSIONED_SHLIB)
 
-all: $(SUBDIRS) $(TARGETS)
+all: subdirs-all $(TARGETS)
 
-install: all $(SUBDIRS.install)
-install_cluster: all $(SUBDIRS.install_cluster)
-install_device-mapper: $(SUBDIRS.install_device-mapper)
-install_lvm2: $(SUBDIRS.install_lvm2)
+install: subdirs-install
+install_cluster: subdirs-install_cluster
+install_device-mapper: subdirs-install_device-mapper
+install_lvm2: subdirs-install_lvm2
 
-$(SUBDIRS): $(SUBDIRS.device-mapper)
-	$(MAKE) -C $@
-
-$(SUBDIRS.device-mapper):
-	$(MAKE) -C $(@:.device-mapper=) device-mapper
-
-$(SUBDIRS.install): $(SUBDIRS)
-	$(MAKE) -C $(@:.install=) install
-
-$(SUBDIRS.install_cluster): $(SUBDIRS)
-	$(MAKE) -C $(@:.install_cluster=) install_cluster
-
-$(SUBDIRS.install_device-mapper): device-mapper
-	$(MAKE) -C $(@:.install_device-mapper=) install_device-mapper
-
-$(SUBDIRS.install_lvm2): $(SUBDIRS)
-	$(MAKE) -C $(@:.install_lvm2=) install_lvm2
-
-$(SUBDIRS.clean):
-	-$(MAKE) -C $(@:.clean=) clean
-
-$(SUBDIRS.distclean):
-	-$(MAKE) -C $(@:.distclean=) distclean
+subdirs-%:
+	+ at set -e; for subdir in $(SUBDIRS); do \
+		$(MAKE) -C $$subdir $(patsubst subdirs-%,%,$@); \
+	done
 
 ifeq ("@INTL@", "yes")
-pofile: $(SUBDIRS.pofile) $(POTFILES)
-
-$(SUBDIRS.pofile):
-	$(MAKE) -C $(@:.pofile=) pofile
+pofile: subdirs-pofile $(POTFILES)
 endif
 
 ifneq ("@CFLOW_CMD@", "")
-cflow: $(SUBDIRS.cflow)
-
-$(SUBDIRS.cflow):
-	$(MAKE) -C $(@:.cflow=) cflow
+cflow: subdirs-cflow
 endif
 
 $(TARGETS): $(OBJECTS)
@@ -238,12 +200,12 @@ $(LIB_STATIC): $(OBJECTS)
 %.mo: %.po
 	$(MSGFMT) -o $@ $<
 
-clean: $(SUBDIRS.clean)
+clean: subdirs-clean
 	$(RM) $(OBJECTS) $(TARGETS) $(CLEAN_TARGETS) $(SOURCES:%.c=%.d) \
 	      $(SOURCES2:%.c=%.d) $(SOURCES:%.c=%.pot) $(SOURCES:%.c=%.gcno) \
 	      $(SOURCES:%.c=%.gcda) $(LDDEPS)
 
-distclean: $(SUBDIRS.distclean)
+distclean: subdir-distclean
 	$(RM) -rf $(DISTCLEAN_DIRS)
 	$(RM) $(DISTCLEAN_TARGETS) \
 	      $(OBJECTS) $(TARGETS) $(CLEAN_TARGETS) $(SOURCES:%.c=%.d) \
diff --git a/man/Makefile.in b/man/Makefile.in
index f0c98fd..f0acb84 100644
--- a/man/Makefile.in
+++ b/man/Makefile.in
@@ -49,9 +49,7 @@ all: man
 
 .PHONY: man
 
-device-mapper: $(MAN8DM)
-
-man: $(MAN5) $(MAN8) $(MAN8CLUSTER)
+man: $(MAN5) $(MAN8) $(MAN8CLUSTER) $(MAN8DM)
 
 $(MAN5) $(MAN8) $(MAN8CLUSTER):	Makefile
 
-- 
1.5.4.3



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

* [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions
  2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
                   ` (7 preceding siblings ...)
  2009-10-08 12:49 ` [PATCH 10/11] debian: make the subdir recursion -j capable Fabio M. Di Nitto
@ 2009-10-08 12:49 ` Fabio M. Di Nitto
  2009-10-09  0:01   ` Alasdair G Kergon
  8 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-08 12:49 UTC (permalink / raw)
  To: lvm-devel

From: Fabio M. Di Nitto <fdinitto@redhat.com>

remove owner and group definitions and install anything writable as mendated
by the debian policy

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
---
:100644 100644 ad871fd... 6b93b77... M	configure.in
:100644 100644 dad568e... a6ecfe9... M	daemons/clvmd/Makefile.in
:100644 100644 debab27... fa08f03... M	daemons/cmirrord/Makefile.in
:100644 100644 2a14ba6... bf71fdb... M	daemons/dmeventd/Makefile.in
:100644 100644 581e5ec... b9f6974... M	daemons/dmeventd/plugins/mirror/Makefile.in
:100644 100644 823ca3f... a07558e... M	daemons/dmeventd/plugins/snapshot/Makefile.in
:100644 100644 b4689af... f589489... M	doc/Makefile.in
:100644 100644 e12cc6f... f70adf7... M	lib/format1/Makefile.in
:100644 100644 d67c982... 36230f4... M	lib/format_pool/Makefile.in
:100644 100644 584c8d6... 8fa8eb6... M	lib/locking/Makefile.in
:100644 100644 d5b678b... b7076f7... M	lib/mirror/Makefile.in
:100644 100644 3f960fb... 3de0373... M	lib/snapshot/Makefile.in
:100644 100644 191e2ae... dea2771... M	libdm/Makefile.in
:100644 100644 d9afc40... 5b37426... M	liblvm/Makefile.in
:100644 100644 56dfa8b... e4acf88... M	make.tmpl.in
:100644 100644 f0acb84... 647488d... M	man/Makefile.in
:100644 100644 c9f8400... 12d4489... M	po/Makefile.in
:100644 100644 33a10c1... 677f965... M	scripts/Makefile.in
:100644 100644 4f8be22... bd834b9... M	tools/Makefile.in
:100644 100644 341479f... 8c71c2b... M	udev/Makefile.in
 configure.in                                  |   29 -------------------------
 daemons/clvmd/Makefile.in                     |    4 +-
 daemons/cmirrord/Makefile.in                  |    2 +-
 daemons/dmeventd/Makefile.in                  |   10 ++++----
 daemons/dmeventd/plugins/mirror/Makefile.in   |    2 +-
 daemons/dmeventd/plugins/snapshot/Makefile.in |    2 +-
 doc/Makefile.in                               |    2 +-
 lib/format1/Makefile.in                       |    3 +-
 lib/format_pool/Makefile.in                   |    3 +-
 lib/locking/Makefile.in                       |    3 +-
 lib/mirror/Makefile.in                        |    3 +-
 lib/snapshot/Makefile.in                      |    3 +-
 libdm/Makefile.in                             |   16 ++++---------
 liblvm/Makefile.in                            |    8 +++---
 make.tmpl.in                                  |    9 +-------
 man/Makefile.in                               |    8 +++---
 po/Makefile.in                                |    4 +-
 scripts/Makefile.in                           |    6 ++--
 tools/Makefile.in                             |   16 +++++++-------
 udev/Makefile.in                              |    4 +-
 20 files changed, 45 insertions(+), 92 deletions(-)

diff --git a/configure.in b/configure.in
index ad871fd..6b93b77 100644
--- a/configure.in
+++ b/configure.in
@@ -141,33 +141,6 @@ dnl -- Prefix is /usr by default, the exec_prefix default is setup later
 AC_PREFIX_DEFAULT(/usr)
 
 ################################################################################
-dnl -- Setup the ownership of the files
-AC_MSG_CHECKING(file owner)
-OWNER="root"
-
-AC_ARG_WITH(user,
-  [  --with-user=USER        Set the owner of installed files [[USER=root]] ],
-  [ OWNER="$withval" ])
-AC_MSG_RESULT($OWNER)
-
-if test x$OWNER != x; then
-	OWNER="-o $OWNER"
-fi
-
-################################################################################
-dnl -- Setup the group ownership of the files
-AC_MSG_CHECKING(group owner)
-GROUP="root"
-AC_ARG_WITH(group,
-  [  --with-group=GROUP      Set the group owner of installed files [[GROUP=root]] ],
-  [ GROUP="$withval" ])
-AC_MSG_RESULT($GROUP)
-
-if test x$GROUP != x; then
-	GROUP="-g $GROUP"
-fi
-
-################################################################################
 dnl -- Setup device node ownership
 AC_MSG_CHECKING(device node uid)
 
@@ -1023,7 +996,6 @@ AC_SUBST(DM_IOCTLS)
 AC_SUBST(DM_LIB_VERSION)
 AC_SUBST(DM_LIB_PATCHLEVEL)
 AC_SUBST(FSADM)
-AC_SUBST(GROUP)
 AC_SUBST(GULM_CFLAGS)
 AC_SUBST(GULM_LIBS)
 AC_SUBST(HAVE_LIBDL)
@@ -1049,7 +1021,6 @@ AC_SUBST(LVM_RELEASE)
 AC_SUBST(LVM_RELEASE_DATE)
 AC_SUBST(MIRRORS)
 AC_SUBST(MSGFMT)
-AC_SUBST(OWNER)
 AC_SUBST(PKGCONFIG)
 AC_SUBST(POOL)
 AC_SUBST(QUORUM_CFLAGS)
diff --git a/daemons/clvmd/Makefile.in b/daemons/clvmd/Makefile.in
index dad568e..a6ecfe9 100644
--- a/daemons/clvmd/Makefile.in
+++ b/daemons/clvmd/Makefile.in
@@ -98,8 +98,8 @@ clvmd: $(OBJECTS) $(top_builddir)/lib/liblvm-internal.a
 .PHONY: install_clvmd
 
 install_clvmd: $(TARGETS)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) clvmd \
-		$(usrsbindir)/clvmd
+	$(INSTALL) -D clvmd \
+		$(sbindir)/clvmd
 
 install: $(INSTALL_TARGETS)
 
diff --git a/daemons/cmirrord/Makefile.in b/daemons/cmirrord/Makefile.in
index debab27..fa08f03 100644
--- a/daemons/cmirrord/Makefile.in
+++ b/daemons/cmirrord/Makefile.in
@@ -36,5 +36,5 @@ cmirrord: $(OBJECTS) $(top_builddir)/lib/liblvm-internal.a
 		$(LVMLIBS) $(LMLIBS) $(LIBS)
 
 install: $(TARGETS)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) cmirrord \
+	$(INSTALL) -D cmirrord \
 		$(usrsbindir)/cmirrord
diff --git a/daemons/dmeventd/Makefile.in b/daemons/dmeventd/Makefile.in
index 2a14ba6..bf71fdb 100644
--- a/daemons/dmeventd/Makefile.in
+++ b/daemons/dmeventd/Makefile.in
@@ -66,24 +66,24 @@ install: $(INSTALL_TYPE) install_include install_dmeventd
 install_device-mapper: $(INSTALL_TYPE) install_include install_dmeventd
 
 install_include:
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/libdevmapper-event.h \
+	$(INSTALL) -D -m 644 $(srcdir)/libdevmapper-event.h \
 		$(includedir)/libdevmapper-event.h
 
 install_dynamic: libdevmapper-event.$(LIB_SUFFIX)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/libdevmapper-event.$(LIB_SUFFIX).$(LIB_VERSION)
 	$(LN_S) -f libdevmapper-event.$(LIB_SUFFIX).$(LIB_VERSION) \
 		$(libdir)/libdevmapper-event.$(LIB_SUFFIX)
 
 install_dmeventd: dmeventd
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< $(sbindir)/$<
+	$(INSTALL) -D $< $(sbindir)/$<
 
 install_pkgconfig:
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 444 libdevmapper-event.pc \
+	$(INSTALL) -D -m 644 libdevmapper-event.pc \
 		$(usrlibdir)/pkgconfig/devmapper-event.pc
 
 install_static: libdevmapper-event.a
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/libdevmapper-event.a.$(LIB_VERSION)
 	$(LN_S) -f libdevmapper-event.a.$(LIB_VERSION) $(libdir)/libdevmapper-event.a
 
diff --git a/daemons/dmeventd/plugins/mirror/Makefile.in b/daemons/dmeventd/plugins/mirror/Makefile.in
index 581e5ec..b9f6974 100644
--- a/daemons/dmeventd/plugins/mirror/Makefile.in
+++ b/daemons/dmeventd/plugins/mirror/Makefile.in
@@ -34,7 +34,7 @@ LIB_VERSION = $(LIB_VERSION_LVM)
 include $(top_builddir)/make.tmpl
 
 install_lvm2: libdevmapper-event-lvm2mirror.$(LIB_SUFFIX)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/$<.$(LIB_VERSION)
 	$(LN_S) -f $<.$(LIB_VERSION) $(libdir)/$<
 
diff --git a/daemons/dmeventd/plugins/snapshot/Makefile.in b/daemons/dmeventd/plugins/snapshot/Makefile.in
index 823ca3f..a07558e 100644
--- a/daemons/dmeventd/plugins/snapshot/Makefile.in
+++ b/daemons/dmeventd/plugins/snapshot/Makefile.in
@@ -34,7 +34,7 @@ LIB_VERSION = $(LIB_VERSION_LVM)
 include $(top_builddir)/make.tmpl
 
 install_lvm2: libdevmapper-event-lvm2snapshot.$(LIB_SUFFIX)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/$<.$(LIB_VERSION)
 	$(LN_S) -f $<.$(LIB_VERSION) $(libdir)/$<
 
diff --git a/doc/Makefile.in b/doc/Makefile.in
index b4689af..f589489 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -24,7 +24,7 @@ include ../make.tmpl
 install_lvm2: $(CONFSRC)
 	@if [ ! -e $(confdir)/$(CONFDEST) ]; then \
 		echo "Installing $(CONFSRC) as $(confdir)/$(CONFDEST)"; \
-		@INSTALL@ -D $(OWNER) $(GROUP) -m 644 $< \
+		@INSTALL@ -D $< \
 			$(confdir)/$(CONFDEST); \
 	fi
 
diff --git a/lib/format1/Makefile.in b/lib/format1/Makefile.in
index e12cc6f..f70adf7 100644
--- a/lib/format1/Makefile.in
+++ b/lib/format1/Makefile.in
@@ -32,7 +32,6 @@ LIB_VERSION = $(LIB_VERSION_LVM)
 include ../../make.tmpl
 
 install: liblvm2format1.so
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
-		$(libdir)/liblvm2format1.so.$(LIB_VERSION)
+	$(INSTALL) -D $< $(libdir)/liblvm2format1.so.$(LIB_VERSION)
 	$(LN_S) -f liblvm2format1.so.$(LIB_VERSION) $(libdir)/liblvm2format1.so
 
diff --git a/lib/format_pool/Makefile.in b/lib/format_pool/Makefile.in
index d67c982..36230f4 100644
--- a/lib/format_pool/Makefile.in
+++ b/lib/format_pool/Makefile.in
@@ -29,8 +29,7 @@ LIB_VERSION = $(LIB_VERSION_LVM)
 include ../../make.tmpl
 
 install: liblvm2formatpool.so
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
-		$(libdir)/liblvm2formatpool.so.$(LIB_VERSION)
+	$(INSTALL) -D $< $(libdir)/liblvm2formatpool.so.$(LIB_VERSION)
 	$(LN_S) -f liblvm2formatpool.so.$(LIB_VERSION) \
 		$(libdir)/liblvm2formatpool.so
 
diff --git a/lib/locking/Makefile.in b/lib/locking/Makefile.in
index 584c8d6..8fa8eb6 100644
--- a/lib/locking/Makefile.in
+++ b/lib/locking/Makefile.in
@@ -25,8 +25,7 @@ LIB_VERSION = $(LIB_VERSION_LVM)
 include ../../make.tmpl
 
 install install_cluster: liblvm2clusterlock.so
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
-		$(libdir)/liblvm2clusterlock.so.$(LIB_VERSION)
+	$(INSTALL) -D $< $(libdir)/liblvm2clusterlock.so.$(LIB_VERSION)
 	$(LN_S) -f liblvm2clusterlock.so.$(LIB_VERSION) \
 		$(libdir)/liblvm2clusterlock.so
 
diff --git a/lib/mirror/Makefile.in b/lib/mirror/Makefile.in
index d5b678b..b7076f7 100644
--- a/lib/mirror/Makefile.in
+++ b/lib/mirror/Makefile.in
@@ -25,7 +25,6 @@ LIB_VERSION = $(LIB_VERSION_LVM)
 include ../../make.tmpl
 
 install: liblvm2mirror.so
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
-		$(libdir)/liblvm2mirror.so.$(LIB_VERSION)
+	$(INSTALL) -D $< $(libdir)/liblvm2mirror.so.$(LIB_VERSION)
 	$(LN_S) -f liblvm2mirror.so.$(LIB_VERSION) $(libdir)/liblvm2mirror.so
 
diff --git a/lib/snapshot/Makefile.in b/lib/snapshot/Makefile.in
index 3f960fb..3de0373 100644
--- a/lib/snapshot/Makefile.in
+++ b/lib/snapshot/Makefile.in
@@ -25,8 +25,7 @@ LIB_VERSION = $(LIB_VERSION_LVM)
 include ../../make.tmpl
 
 install: liblvm2snapshot.so
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
-		$(libdir)/liblvm2snapshot.so.$(LIB_VERSION)
+	$(INSTALL) -D $< $(libdir)/liblvm2snapshot.so.$(LIB_VERSION)
 	$(LN_S) -f liblvm2snapshot.so.$(LIB_VERSION) \
 		$(libdir)/liblvm2snapshot.so
 
diff --git a/libdm/Makefile.in b/libdm/Makefile.in
index 191e2ae..dea2771 100644
--- a/libdm/Makefile.in
+++ b/libdm/Makefile.in
@@ -58,11 +58,7 @@ device-mapper: all
 	install_ioctl install_ioctl_static \
 	install_pkgconfig
 
-INSTALL_TYPE = install_dynamic
-
-ifeq ("@STATIC_LINK@", "yes")
-  INSTALL_TYPE += install_static
-endif
+INSTALL_TYPE = install_dynamic install_static
 
 ifeq ("@PKGCONFIG@", "yes")
   INSTALL_TYPE += install_pkgconfig
@@ -73,7 +69,7 @@ install: $(INSTALL_TYPE) install_include
 install_device-mapper: install
 
 install_include:
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/libdevmapper.h \
+	$(INSTALL_DATA) -D $(srcdir)/libdevmapper.h \
 		$(includedir)/libdevmapper.h
 
 install_dynamic: install_ at interface@
@@ -81,19 +77,17 @@ install_dynamic: install_ at interface@
 		$(libdir)/libdevmapper.$(LIB_SUFFIX)
 
 install_static: install_@interface@_static
-	$(LN_S) -f libdevmapper.a.$(LIB_VERSION_DM) $(libdir)/libdevmapper.a
 
 install_ioctl: ioctl/libdevmapper.$(LIB_SUFFIX)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/libdevmapper.$(LIB_SUFFIX).$(LIB_VERSION_DM)
 
 install_pkgconfig:
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 444 libdevmapper.pc \
+	$(INSTALL_DATA) -D libdevmapper.pc \
 		$(usrlibdir)/pkgconfig/devmapper.pc
 
 install_ioctl_static: ioctl/libdevmapper.a
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
-		$(libdir)/libdevmapper.a.$(LIB_VERSION_DM)
+	$(INSTALL) -D $< $(usrlibdir)/libdevmapper.a
 
 $(VERSIONED_SHLIB): %.$(LIB_SUFFIX).$(LIB_VERSION_DM): $(interface)/%.$(LIB_SUFFIX)
 	rm -f $@
diff --git a/liblvm/Makefile.in b/liblvm/Makefile.in
index d9afc40..5b37426 100644
--- a/liblvm/Makefile.in
+++ b/liblvm/Makefile.in
@@ -67,21 +67,21 @@ endif
 install: $(INSTALL_TYPE) install_include
 
 install_include:
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/lvm2app.h $(includedir)/lvm2app.h
+	$(INSTALL_DATA) -D $(srcdir)/lvm2app.h $(includedir)/lvm2app.h
 
 install_dynamic: $(LIB_SHARED)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/$(LIB_SHARED).$(LIB_VERSION_APP)
 	$(LN_S) -f $(LIB_SHARED).$(LIB_VERSION_APP) \
 		$(libdir)/$(LIB_SHARED)
 
 install_static: $(LIB_STATIC)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/$(LIB_STATIC).$(LIB_VERSION_APP)
 	$(LN_S) -f $(LIB_STATIC).$(LIB_VERSION_APP) $(libdir)/$(LIB_STATIC)
 
 install_pkgconfig:
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(LIB_NAME).pc \
+	$(INSTALL_DATA) -D $(LIB_NAME).pc \
 		$(usrlibdir)/pkgconfig/lvm2app.pc
 
 liblvm.cflow: $(SOURCES)
diff --git a/make.tmpl.in b/make.tmpl.in
index 56dfa8b..e4acf88 100644
--- a/make.tmpl.in
+++ b/make.tmpl.in
@@ -21,6 +21,7 @@ CC = @CC@
 RANLIB = @RANLIB@
 SHELL = /bin/sh
 INSTALL = @INSTALL@
+INSTALL_DATA = $(INSTALL) -m 644
 MKDIR_P = @MKDIR_P@
 MSGFMT = @MSGFMT@
 LCOV = @LCOV@
@@ -56,11 +57,6 @@ udevdir = $(DESTDIR)@udevdir@
 interface = @interface@
 interfacedir = $(top_srcdir)/libdm/$(interface)
 
-# setup misc variables
-# define the ownership variables for the binaries and man pages
-OWNER = @OWNER@
-GROUP = @GROUP@
-
 # The number of jobs to run, if blank, defaults to the make standard
 ifndef MAKEFLAGS
 MAKEFLAGS = @JOBS@
@@ -106,9 +102,6 @@ endif
 
 #CFLAGS += -pg
 
-STRIP=
-#STRIP = -s
-
 LVM_VERSION := $(shell cat $(top_srcdir)/VERSION)
 
 LIB_VERSION_LVM := $(shell cat $(top_srcdir)/VERSION | \
diff --git a/man/Makefile.in b/man/Makefile.in
index f0acb84..647488d 100644
--- a/man/Makefile.in
+++ b/man/Makefile.in
@@ -61,14 +61,14 @@ install_lvm2:
 	@for f in $(MAN8); \
 	do \
 	   $(RM) $(MAN8DIR)/$$f; \
-	   @INSTALL@ -D $(OWNER) $(GROUP) -m 444 $$f $(MAN8DIR)/$$f; \
+	   $(INSTALL_DATA) -D $$f $(MAN8DIR)/$$f; \
 	done
 
 	@echo "Installing $(MAN5) in $(MAN5DIR)"
 	@for f in $(MAN5); \
 	do \
 	   $(RM) $(MAN5DIR)/$$f; \
-	   @INSTALL@ -D $(OWNER) $(GROUP) -m 444 $$f $(MAN5DIR)/$$f; \
+	   $(INSTALL_DATA) -D $$f $(MAN5DIR)/$$f; \
 	done
 
 install_cluster:
@@ -76,7 +76,7 @@ install_cluster:
 	@for f in $(MAN8CLUSTER); \
 	do \
 	   $(RM) $(MAN8DIR)/$$f; \
-	   @INSTALL@ -D $(OWNER) $(GROUP) -m 444 $$f $(MAN8DIR)/$$f; \
+	   $(INSTALL_DATA) -D $$f $(MAN8DIR)/$$f; \
 	done
 
 install_device-mapper:
@@ -84,7 +84,7 @@ install_device-mapper:
 	@for f in $(MAN8DM); \
 	do \
 	   $(RM) $(MAN8DIR)/$$f; \
-	   @INSTALL@ -D $(OWNER) $(GROUP) -m 444 $$f $(MAN8DIR)/$$f; \
+	   $(INSTALL_DATA) -D $$f $(MAN8DIR)/$$f; \
 	done
 
 install: install_lvm2 install_device-mapper
diff --git a/po/Makefile.in b/po/Makefile.in
index c9f8400..12d4489 100644
--- a/po/Makefile.in
+++ b/po/Makefile.in
@@ -54,13 +54,13 @@ install: $(TARGETS)
 	@echo Installing translation files in $(localedir)
 	@( \
 		for lang in $(LANGS); do \
-			$(INSTALL) -D $(OWNER) $(GROUP) -m 444 $$lang.mo \
+			$(INSTALL_DATA) -D $$lang.mo \
 			    $(localedir)/$$lang/LC_MESSAGES/lvm2.mo;\
 	  done; \
 	)
 	@( \
 		for lang in $(LANGS); do \
-			$(INSTALL) -D $(OWNER) $(GROUP) -m 444 $$lang.mo \
+			$(INSTALL_DATA) -D $$lang.mo \
 			    $(localedir)/$$lang/LC_MESSAGES/device-mapper.mo;\
 	  done; \
 	)
diff --git a/scripts/Makefile.in b/scripts/Makefile.in
index 33a10c1..677f965 100644
--- a/scripts/Makefile.in
+++ b/scripts/Makefile.in
@@ -19,12 +19,12 @@ VPATH = @srcdir@
 include ../make.tmpl
 
 install:
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(srcdir)/lvm_dump.sh \
+	$(INSTALL) -D $(srcdir)/lvm_dump.sh \
 		$(sbindir)/lvmdump
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(srcdir)/vgimportclone.sh \
+	$(INSTALL) -D $(srcdir)/vgimportclone.sh \
 		$(sbindir)/vgimportclone
 ifeq ("@FSADM@", "yes")
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(srcdir)/fsadm.sh \
+	$(INSTALL) -D $(srcdir)/fsadm.sh \
 		$(sbindir)/fsadm
 endif
 
diff --git a/tools/Makefile.in b/tools/Makefile.in
index 4f8be22..bd834b9 100644
--- a/tools/Makefile.in
+++ b/tools/Makefile.in
@@ -165,21 +165,21 @@ cflow: lvm.cflow lvm.xref lvm.tree lvm.rtree lvm.rxref
 endif
 
 install_cmdlib_dynamic: liblvm2cmd.$(LIB_SUFFIX)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/liblvm2cmd.$(LIB_SUFFIX).$(LIB_VERSION)
 	$(LN_S) -f liblvm2cmd.$(LIB_SUFFIX).$(LIB_VERSION) $(libdir)/liblvm2cmd.$(LIB_SUFFIX)
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/lvm2cmd.h \
+	$(INSTALL_DATA) -D $(srcdir)/lvm2cmd.h \
 		$(includedir)/lvm2cmd.h
 
 install_cmdlib_static: liblvm2cmd-static.a
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(libdir)/liblvm2cmd.a.$(LIB_VERSION)
 	$(LN_S) -f liblvm2cmd.a.$(LIB_VERSION) $(libdir)/liblvm2cmd.a
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 444 $(srcdir)/lvm2cmd.h \
+	$(INSTALL_DATA) -D $(srcdir)/lvm2cmd.h \
 		$(includedir)/lvm2cmd.h
 
 install_tools_dynamic: lvm .commands
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) lvm \
+	$(INSTALL) -D lvm \
 		$(sbindir)/lvm
 	@echo Creating symbolic links for individual commands in $(sbindir)
 	@( \
@@ -190,14 +190,14 @@ install_tools_dynamic: lvm .commands
 	)
 
 install_tools_static: lvm.static
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< \
+	$(INSTALL) -D $< \
 		$(staticdir)/lvm.static
 
 install_dmsetup_dynamic: dmsetup
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< $(sbindir)/$<
+	$(INSTALL) -D $< $(sbindir)/$<
 
 install_dmsetup_static: dmsetup.static
-	$(INSTALL) -D $(OWNER) $(GROUP) -m 555 $(STRIP) $< $(sbindir)/$<
+	$(INSTALL) -D $< $(sbindir)/$<
 
 install_device-mapper: $(INSTALL_DMSETUP_TARGETS)
 
diff --git a/udev/Makefile.in b/udev/Makefile.in
index 341479f..8c71c2b 100644
--- a/udev/Makefile.in
+++ b/udev/Makefile.in
@@ -32,7 +32,7 @@ install_lvm2: $(LVM_RULES)
 	@for f in $(LVM_RULES); \
 	do \
 	   $(RM) $(udevdir)/$$f; \
-	   $(INSTALL) -c -D $(OWNER) $(GROUP) -m 644 $(srcdir)/$$f $(udevdir)/$$f; \
+	   $(INSTALL_DATA) -c -D  $(srcdir)/$$f $(udevdir)/$$f; \
 	done
 
 install_device-mapper: $(DM_RULES)
@@ -40,7 +40,7 @@ install_device-mapper: $(DM_RULES)
 	@for f in $(DM_RULES); \
 	do \
 	   $(RM) $(udevdir)/$$f; \
-	   $(INSTALL) -c -D $(OWNER) $(GROUP) -m 644 $(srcdir)/$$f $(udevdir)/$$f; \
+	   $(INSTALL_DATA) -c -D $(srcdir)/$$f $(udevdir)/$$f; \
 	done
 
 install: install_lvm2 install_device-mapper
-- 
1.5.4.3



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

* [PATCH 01/11] debian: fix library search path in example.conf
  2009-10-08 11:58   ` Fabio M. Di Nitto
                     ` (2 preceding siblings ...)
  (?)
@ 2009-10-08 23:27   ` Alasdair G Kergon
  2009-10-11 17:09     ` Fabio M. Di Nitto
  -1 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:27 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 01:54:54PM +0200, Fabio M. Di Nitto wrote:
> this patch is debian specific and sets the library search path
> to /lib/lvm2 to avoid cluttering /lib
 
Add configure parm for this and generate example.conf from template?

In fact, it would be useful to know the current 'configure' line that
Debian uses.

Alasdair



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

* [PATCH 02/11] debian: drop realtime
  2009-10-08 12:49   ` Fabio M. Di Nitto
  (?)
@ 2009-10-08 23:28   ` Alasdair G Kergon
  2009-10-09 15:03     ` Bastian Blank
  -1 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:28 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:16:20PM +0200, Fabio M. Di Nitto wrote:
> the realtime support is completely unused and just includes another library
> dependency

Just fix the build so REALTIME=no really does exclude it completely.

Alasdair



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

* [PATCH 03/11] debian: force modprobe
  2009-10-08 12:49 ` [PATCH 03/11] debian: force modprobe Fabio M. Di Nitto
@ 2009-10-08 23:30   ` Alasdair G Kergon
  2009-10-09 15:02     ` Bastian Blank
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:30 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:49:10PM +0200, Fabio M. Di Nitto wrote:
> well, a linux system without modprobe can't use any modules.
> so this just assumes that it is available in a real system
 
I see no need for this one upstream.

(Things like this are there so the code can be used on some BSD-based systems.)

Alasdair



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

* [PATCH 04/11] debian: fix implicit pointer
  2009-10-08 12:49 ` [PATCH 04/11] debian: fix implicit pointer Fabio M. Di Nitto
@ 2009-10-08 23:34   ` Alasdair G Kergon
  2009-10-11 17:29     ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:34 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:49:11PM +0200, Fabio M. Di Nitto wrote:
> not sure why the ifdef does not fire, but this is a readline function
> and must not be redefined
 
This hack was needed for compilation on some systems (functions renamed
in library).

If there are other systems where it causes problems, then please
send details.

Alasdair



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

* [PATCH 05/11] debian: keep libdm-abi consistent
  2009-10-08 12:49 ` [PATCH 05/11] debian: keep libdm-abi consistent Fabio M. Di Nitto
@ 2009-10-08 23:35   ` Alasdair G Kergon
  2009-10-12  4:07     ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:35 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:49:12PM +0200, Fabio M. Di Nitto wrote:
> don't change the ABI of libdm on selinux enable, just make the selinux
> function a NOP
 
Clearly this needs fixing upstream.

Alasdair



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

* [PATCH 06/11] debian/ubuntu: make the device node creation more atomic
  2009-10-08 12:49 ` [PATCH 06/11] debian/ubuntu: make the device node creation more atomic Fabio M. Di Nitto
@ 2009-10-08 23:39   ` Alasdair G Kergon
  2009-10-12  6:11     ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:39 UTC (permalink / raw)
  To: lvm-devel

This one needs a fresh review.  (I think I bounced it for further changes
when it was originally submitted, but don't recall seeing a revised version.)

Alasdair



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

* [PATCH 07/11] debian: workaround for broken kernel headers
  2009-10-08 12:49 ` [PATCH 07/11] debian: workaround for broken kernel headers Fabio M. Di Nitto
@ 2009-10-08 23:41   ` Alasdair G Kergon
  2009-10-12  8:57   ` Fabio M. Di Nitto
  1 sibling, 0 replies; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:41 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:49:14PM +0200, Fabio M. Di Nitto wrote:
> this patch might be debian specific and needs more investigation.
 
Yes, I'm not sure whether or not it's something we can deal with upstream somehow.

Alasdair



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

* [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding
  2009-10-08 12:49 ` [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding Fabio M. Di Nitto
@ 2009-10-08 23:44   ` Alasdair G Kergon
  2009-10-09 14:58     ` Bastian Blank
  2009-10-12  9:06     ` Fabio M. Di Nitto
  0 siblings, 2 replies; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:44 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:49:15PM +0200, Fabio M. Di Nitto wrote:
> use selinux pkgconfig file instead of hardcoding the contents
 
I don't think this patch goes far enough...
The build should be using the pc file too (if present), as we now do for clvmd!

Alasdair



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

* [PATCH 10/11] debian: make the subdir recursion -j capable
  2009-10-08 12:49 ` [PATCH 10/11] debian: make the subdir recursion -j capable Fabio M. Di Nitto
@ 2009-10-08 23:57   ` Alasdair G Kergon
  2009-10-09 15:00     ` Bastian Blank
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-08 23:57 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:49:17PM +0200, Fabio M. Di Nitto wrote:
> but it removes some dependencies on the way
 
The tree isn't constructed for a basic recursion mechanism to work
properly at the moment, and the inter-dependencies all play a role in
coping with whatever configuration and make targets are thrown at it.
(Nor does the current setup work perfectly today.)

So let's park this one for now, then include the possibility of moving
some files/directories/targets around so a simple recursion mechanism
could perhaps be made to cope.

Alasdair



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

* [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions
  2009-10-08 12:49 ` [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions Fabio M. Di Nitto
@ 2009-10-09  0:01   ` Alasdair G Kergon
  2009-10-09 15:01     ` Bastian Blank
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-09  0:01 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:49:18PM +0200, Fabio M. Di Nitto wrote:
> remove owner and group definitions and install anything writable as mendated
> by the debian policy
 
--with-user= and --with-group= should already handle the owner and group
(i.e. set them to blank like we do in RHEL/Fedora)

The hard-coded perms in the makefiles probably need treating in a similar fashion.

Alasdair



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

* [PATCH 09/11] debian: libs cleanup
  2009-10-08 12:49 ` [PATCH 09/11] debian: libs cleanup Fabio M. Di Nitto
@ 2009-10-09  0:02   ` Alasdair G Kergon
  0 siblings, 0 replies; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-09  0:02 UTC (permalink / raw)
  To: lvm-devel

On Thu, Oct 08, 2009 at 02:49:16PM +0200, Fabio M. Di Nitto wrote:
> patch with several changes on how libs are found and used
> (selinux and readline)
> patch is not clean or ready for submission
 
Yes, this one needs picking through carefully to see what needs changing
and then to decide how.

Alasdair



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

* [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding
  2009-10-08 23:44   ` Alasdair G Kergon
@ 2009-10-09 14:58     ` Bastian Blank
  2009-10-12  9:06     ` Fabio M. Di Nitto
  1 sibling, 0 replies; 62+ messages in thread
From: Bastian Blank @ 2009-10-09 14:58 UTC (permalink / raw)
  To: lvm-devel

On Fri, Oct 09, 2009 at 12:44:50AM +0100, Alasdair G Kergon wrote:
> On Thu, Oct 08, 2009 at 02:49:15PM +0200, Fabio M. Di Nitto wrote:
> > use selinux pkgconfig file instead of hardcoding the contents
> I don't think this patch goes far enough...

This is the external view.

> The build should be using the pc file too (if present), as we now do for clvmd!

This is the internal view. This are different parts.

Bastian

-- 
Those who hate and fight must stop themselves -- otherwise it is not stopped.
		-- Spock, "Day of the Dove", stardate unknown



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

* [PATCH 10/11] debian: make the subdir recursion -j capable
  2009-10-08 23:57   ` Alasdair G Kergon
@ 2009-10-09 15:00     ` Bastian Blank
  0 siblings, 0 replies; 62+ messages in thread
From: Bastian Blank @ 2009-10-09 15:00 UTC (permalink / raw)
  To: lvm-devel

On Fri, Oct 09, 2009 at 12:57:09AM +0100, Alasdair G Kergon wrote:
> The tree isn't constructed for a basic recursion mechanism to work
> properly at the moment, and the inter-dependencies all play a role in
> coping with whatever configuration and make targets are thrown at it.
> (Nor does the current setup work perfectly today.)

Even the dependencies reduces it to a simple recursion model. make is
simply not able to provide something else if you don't use one large
makefile. And it works quite well.

Bastian

-- 
Killing is wrong.
		-- Losira, "That Which Survives", stardate unknown



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

* [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions
  2009-10-09  0:01   ` Alasdair G Kergon
@ 2009-10-09 15:01     ` Bastian Blank
  2009-10-09 16:29       ` Alasdair G Kergon
  0 siblings, 1 reply; 62+ messages in thread
From: Bastian Blank @ 2009-10-09 15:01 UTC (permalink / raw)
  To: lvm-devel

On Fri, Oct 09, 2009 at 01:01:34AM +0100, Alasdair G Kergon wrote:
> On Thu, Oct 08, 2009 at 02:49:18PM +0200, Fabio M. Di Nitto wrote:
> > remove owner and group definitions and install anything writable as mendated
> > by the debian policy
> --with-user= and --with-group= should already handle the owner and group
> (i.e. set them to blank like we do in RHEL/Fedora)

So noone uses that functionality. Why is it there and why is it used by
default? Every system where the defaults used by install (maybe *BSD)
have there own mechanism to solve this.

Bastian

-- 
Conquest is easy. Control is not.
		-- Kirk, "Mirror, Mirror", stardate unknown



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

* [PATCH 03/11] debian: force modprobe
  2009-10-08 23:30   ` Alasdair G Kergon
@ 2009-10-09 15:02     ` Bastian Blank
  0 siblings, 0 replies; 62+ messages in thread
From: Bastian Blank @ 2009-10-09 15:02 UTC (permalink / raw)
  To: lvm-devel

On Fri, Oct 09, 2009 at 12:30:16AM +0100, Alasdair G Kergon wrote:
> On Thu, Oct 08, 2009 at 02:49:10PM +0200, Fabio M. Di Nitto wrote:
> > well, a linux system without modprobe can't use any modules.
> > so this just assumes that it is available in a real system
> I see no need for this one upstream.
> (Things like this are there so the code can be used on some BSD-based systems.)

modprobe is Linux-only, so this useless.

Bastian

-- 
Earth -- mother of the most beautiful women in the universe.
		-- Apollo, "Who Mourns for Adonais?" stardate 3468.1



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

* [PATCH 02/11] debian: drop realtime
  2009-10-08 23:28   ` Alasdair G Kergon
@ 2009-10-09 15:03     ` Bastian Blank
  2009-10-09 16:24       ` Alasdair G Kergon
  0 siblings, 1 reply; 62+ messages in thread
From: Bastian Blank @ 2009-10-09 15:03 UTC (permalink / raw)
  To: lvm-devel

On Fri, Oct 09, 2009 at 12:28:25AM +0100, Alasdair G Kergon wrote:
> On Thu, Oct 08, 2009 at 02:16:20PM +0200, Fabio M. Di Nitto wrote:
> > the realtime support is completely unused and just includes another library
> > dependency
> Just fix the build so REALTIME=no really does exclude it completely.

The code is not used. Why is it there?

Bastian

-- 
Warp 7 -- It's a law we can live with.



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

* [PATCH 02/11] debian: drop realtime
  2009-10-09 15:03     ` Bastian Blank
@ 2009-10-09 16:24       ` Alasdair G Kergon
  2009-10-10  9:21         ` Bastian Blank
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-09 16:24 UTC (permalink / raw)
  To: lvm-devel

On Fri, Oct 09, 2009 at 05:03:11PM +0200, Bastian Blank wrote:
> The code is not used. Why is it there?
 
This is an upstream development tree and instead of having multiple
branches, we keep the code in one place but exclude or disable code that
is not used.  The code that needed to use that particular feature has
not been finished.

Alasdair



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

* [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions
  2009-10-09 15:01     ` Bastian Blank
@ 2009-10-09 16:29       ` Alasdair G Kergon
  2009-10-12  9:30         ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-09 16:29 UTC (permalink / raw)
  To: lvm-devel

On Fri, Oct 09, 2009 at 05:01:48PM +0200, Bastian Blank wrote:
> why is it used by
> default? 

I'm open to changing that default.

Alasdair



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

* [PATCH 02/11] debian: drop realtime
  2009-10-09 16:24       ` Alasdair G Kergon
@ 2009-10-10  9:21         ` Bastian Blank
  2009-10-11 17:20           ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Bastian Blank @ 2009-10-10  9:21 UTC (permalink / raw)
  To: lvm-devel

On Fri, Oct 09, 2009 at 05:24:48PM +0100, Alasdair G Kergon wrote:
> On Fri, Oct 09, 2009 at 05:03:11PM +0200, Bastian Blank wrote:
> > The code is not used. Why is it there?
> This is an upstream development tree and instead of having multiple
> branches, we keep the code in one place but exclude or disable code that
> is not used.

The code
* is enabled by default,
* is unused in the published code since a long time and
* is not marked in any way.
=> Can be removed.

>               The code that needed to use that particular feature has
> not been finished.

Then it can be handled as part of that particular feature.

Bastian

-- 
Well, Jim, I'm not much of an actor either.



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

* [PATCH 01/11] debian: fix library search path in example.conf
  2009-10-08 23:27   ` Alasdair G Kergon
@ 2009-10-11 17:09     ` Fabio M. Di Nitto
  2009-10-11 20:23       ` Bastian Blank
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-11 17:09 UTC (permalink / raw)
  To: lvm-devel

On Fri, 2009-10-09 at 00:27 +0100, Alasdair G Kergon wrote:
> On Thu, Oct 08, 2009 at 01:54:54PM +0200, Fabio M. Di Nitto wrote:
> > this patch is debian specific and sets the library search path
> > to /lib/lvm2 to avoid cluttering /lib
>  
> Add configure parm for this and generate example.conf from template?
> 
> In fact, it would be useful to know the current 'configure' line that
> Debian uses.

I think this patch is bogus even in Debian.

After some investigation "/lib/lvm2/" used to be the default for Debian
up to version 2.00.32-1 and then it was reverted to upstream default to
fix bug http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=287042

Other than the example config file there are no traces of /lib/lvm2
anywhere in the package.

I attached debian/rules anyway as it could be helpful for other patches.

Fabio
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rules
Type: text/x-makefile
Size: 9017 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/lvm-devel/attachments/20091011/542b5fd9/attachment.bin>

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

* [PATCH 02/11] debian: drop realtime
  2009-10-10  9:21         ` Bastian Blank
@ 2009-10-11 17:20           ` Fabio M. Di Nitto
  2009-10-12 17:03             ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-11 17:20 UTC (permalink / raw)
  To: lvm-devel

On Sat, 2009-10-10 at 11:21 +0200, Bastian Blank wrote:
> On Fri, Oct 09, 2009 at 05:24:48PM +0100, Alasdair G Kergon wrote:
> > On Fri, Oct 09, 2009 at 05:03:11PM +0200, Bastian Blank wrote:
> > > The code is not used. Why is it there?
> > This is an upstream development tree and instead of having multiple
> > branches, we keep the code in one place but exclude or disable code that
> > is not used.
> 
> The code
> * is enabled by default,
> * is unused in the published code since a long time and
> * is not marked in any way.
> => Can be removed.
> 
> >               The code that needed to use that particular feature has
> > not been finished.
> 
> Then it can be handled as part of that particular feature.
> 
> Bastian
> 

this patch should make everybody happy.

Sets realitime support off by default and still allow to have it
configurable for developers.

Fabio
-------------- next part --------------
A non-text attachment was scrubbed...
Name: realtime.diff
Type: text/x-patch
Size: 1313 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/lvm-devel/attachments/20091011/6d7b145c/attachment.bin>

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

* [PATCH 04/11] debian: fix implicit pointer
  2009-10-08 23:34   ` Alasdair G Kergon
@ 2009-10-11 17:29     ` Fabio M. Di Nitto
  2009-10-11 20:20       ` Bastian Blank
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-11 17:29 UTC (permalink / raw)
  To: lvm-devel

On Fri, 2009-10-09 at 00:34 +0100, Alasdair G Kergon wrote:
> On Thu, Oct 08, 2009 at 02:49:11PM +0200, Fabio M. Di Nitto wrote:
> > not sure why the ifdef does not fire, but this is a readline function
> > and must not be redefined
>  
> This hack was needed for compilation on some systems (functions renamed
> in library).
> 
> If there are other systems where it causes problems, then please
> send details.

This might very well be a bug in Debian toolchain/autotools/readline
because I can't trigger it on any of my systems.

Bastian, I'd like to investigate this further. Can you please me provide
me with details of your test machine? Debian SID? x86? x86_64? tool
chain version? etc.

Thanks
Fabio



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

* [PATCH 04/11] debian: fix implicit pointer
  2009-10-11 17:29     ` Fabio M. Di Nitto
@ 2009-10-11 20:20       ` Bastian Blank
  2009-10-12  8:07         ` Fabio M. Di Nitto
  2009-10-12  9:14         ` Fabio M. Di Nitto
  0 siblings, 2 replies; 62+ messages in thread
From: Bastian Blank @ 2009-10-11 20:20 UTC (permalink / raw)
  To: lvm-devel

On Sun, Oct 11, 2009 at 07:29:36PM +0200, Fabio M. Di Nitto wrote:
> Bastian, I'd like to investigate this further. Can you please me provide
> me with details of your test machine? Debian SID? x86? x86_64? tool
> chain version? etc.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=516867
https://buildd.debian.org/fetch.cgi?&pkg=lvm2&ver=2.02.44-1&arch=ia64&stamp=1235444991&file=log

Actually configure was not able to find rl_completion_matches but it was
usable.

Bastian

-- 
Warp 7 -- It's a law we can live with.



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

* [PATCH 01/11] debian: fix library search path in example.conf
  2009-10-11 17:09     ` Fabio M. Di Nitto
@ 2009-10-11 20:23       ` Bastian Blank
  2009-10-12  4:02         ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Bastian Blank @ 2009-10-11 20:23 UTC (permalink / raw)
  To: lvm-devel

On Sun, Oct 11, 2009 at 07:09:01PM +0200, Fabio M. Di Nitto wrote:
> Other than the example config file there are no traces of /lib/lvm2
> anywhere in the package.

Its currently unused. The cluster locking lib was the only used external
lib.

Bastian

-- 
The sight of death frightens them [Earthers].
		-- Kras the Klingon, "Friday's Child", stardate 3497.2



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

* [PATCH 01/11] debian: fix library search path in example.conf
  2009-10-11 20:23       ` Bastian Blank
@ 2009-10-12  4:02         ` Fabio M. Di Nitto
  2009-10-12 10:03           ` Alasdair G Kergon
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12  4:02 UTC (permalink / raw)
  To: lvm-devel

On Sun, 2009-10-11 at 22:23 +0200, Bastian Blank wrote:
> On Sun, Oct 11, 2009 at 07:09:01PM +0200, Fabio M. Di Nitto wrote:
> > Other than the example config file there are no traces of /lib/lvm2
> > anywhere in the package.
> 
> Its currently unused. The cluster locking lib was the only used external
> lib.

Alasdair, given that cluster locking lib is gone, do we have a use case
to keep this option configurable? If so I'll spend sometime to make it a
build option, otherwise I would suggest to simply drop it from the
example.conf.

Fabio



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

* [PATCH 05/11] debian: keep libdm-abi consistent
  2009-10-08 23:35   ` Alasdair G Kergon
@ 2009-10-12  4:07     ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12  4:07 UTC (permalink / raw)
  To: lvm-devel

On Fri, 2009-10-09 at 00:35 +0100, Alasdair G Kergon wrote:
> On Thu, Oct 08, 2009 at 02:49:12PM +0200, Fabio M. Di Nitto wrote:
> > don't change the ABI of libdm on selinux enable, just make the selinux
> > function a NOP
>  
> Clearly this needs fixing upstream.

I have merged this one in CVS.

It appears to be the only bit missing from libdm to retain ABI
consistency.

Fabio



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

* [PATCH 06/11] debian/ubuntu: make the device node creation more atomic
  2009-10-08 23:39   ` Alasdair G Kergon
@ 2009-10-12  6:11     ` Fabio M. Di Nitto
  2009-10-12 10:04       ` Alasdair G Kergon
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12  6:11 UTC (permalink / raw)
  To: lvm-devel

On Fri, 2009-10-09 at 00:39 +0100, Alasdair G Kergon wrote:
> This one needs a fresh review.  (I think I bounced it for further changes
> when it was originally submitted, but don't recall seeing a revised version.)

Do you have a reference to the original submission? I can't find it on
either lvm-devel or linux-lvm mailing lists.

Thanks
Fabio



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

* [PATCH 04/11] debian: fix implicit pointer
  2009-10-11 20:20       ` Bastian Blank
@ 2009-10-12  8:07         ` Fabio M. Di Nitto
  2009-10-12  9:14         ` Fabio M. Di Nitto
  1 sibling, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12  8:07 UTC (permalink / raw)
  To: lvm-devel

On Sun, 2009-10-11 at 22:20 +0200, Bastian Blank wrote:
> On Sun, Oct 11, 2009 at 07:29:36PM +0200, Fabio M. Di Nitto wrote:
> > Bastian, I'd like to investigate this further. Can you please me provide
> > me with details of your test machine? Debian SID? x86? x86_64? tool
> > chain version? etc.
> 
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=516867
> https://buildd.debian.org/fetch.cgi?&pkg=lvm2&ver=2.02.44-1&arch=ia64&stamp=1235444991&file=log
> 
> Actually configure was not able to find rl_completion_matches but it was
> usable.

This seems to be a bug introduced by Debian autoreconf.

Using upstream configure:

configure:13440: checking for rl_completion_matches
configure:13496: gcc -o conftest    -Wl,--export-dynamic conftest.c
-lreadline -lrt -lselinux -lsepol  -ldl -lncurses  >&5
configure:13503: $? = 0
configure:13525: result: yes

Using Debian regenerated configure:

configure:8220: checking for rl_completion_matches
configure:8220: gcc -o conftest -g -O2   conftest.c -ldl  >&5
/tmp/ccUvvocx.o: In function `main':
/root/lvm2-2.02.53/debian/build/build-deb/conftest.c:142: undefined
reference to
 `rl_completion_matches'
collect2: ld returned 1 exit status
configure:8220: $? = 1

Maybe it's a regression introduced by autoconf 2.64 that's not available
in Fedora yet.

Fabio



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

* [PATCH 07/11] debian: workaround for broken kernel headers
  2009-10-08 12:49 ` [PATCH 07/11] debian: workaround for broken kernel headers Fabio M. Di Nitto
  2009-10-08 23:41   ` Alasdair G Kergon
@ 2009-10-12  8:57   ` Fabio M. Di Nitto
  1 sibling, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12  8:57 UTC (permalink / raw)
  To: lvm-devel

On Thu, 2009-10-08 at 14:49 +0200, Fabio M. Di Nitto wrote:
> From: Fabio M. Di Nitto <fdinitto@redhat.com>
> 
> this patch might be debian specific and needs more investigation.
> 
> Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>

Hi Bastian,

do you recall what kernel version was triggering the issue?

Fabio



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

* [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding
  2009-10-08 23:44   ` Alasdair G Kergon
  2009-10-09 14:58     ` Bastian Blank
@ 2009-10-12  9:06     ` Fabio M. Di Nitto
  2009-10-12 10:18       ` Alasdair G Kergon
  1 sibling, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12  9:06 UTC (permalink / raw)
  To: lvm-devel

On Fri, 2009-10-09 at 00:44 +0100, Alasdair G Kergon wrote:
> On Thu, Oct 08, 2009 at 02:49:15PM +0200, Fabio M. Di Nitto wrote:
> > use selinux pkgconfig file instead of hardcoding the contents
>  
> I don't think this patch goes far enough...
> The build should be using the pc file too (if present), as we now do for clvmd!

We need to differentiate as Bastian said.

For the internal view, we can switch to use PKG_CONFIG inside our
configure.in, but that means:

1) it will be a hard dependency (and we recently agreed to avoid that).

2) we assume that lvm2 developers and packagers will build/ship with
recent enough build dependencies to guarantee working pkg-config files.

While I am generally ok with this approach as it will make our
configure.in a lot simpler, it will kill the option to build on older
distro (I believe we only lose RHEL4 at this point, but it would require
cross-checking).

For the external view, as it is now, we can create the correct .pc file.
If we detect that selinux has pkg-config support, then we use the
"Requires.private: libselinux" that will automatically expand via
pkg-config. If we don't have selinux pkg-config, then we can hardcode as
we do now.

Fabio



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

* [PATCH 04/11] debian: fix implicit pointer
  2009-10-11 20:20       ` Bastian Blank
  2009-10-12  8:07         ` Fabio M. Di Nitto
@ 2009-10-12  9:14         ` Fabio M. Di Nitto
  1 sibling, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12  9:14 UTC (permalink / raw)
  To: lvm-devel

On Sun, 2009-10-11 at 22:20 +0200, Bastian Blank wrote:
> On Sun, Oct 11, 2009 at 07:29:36PM +0200, Fabio M. Di Nitto wrote:
> > Bastian, I'd like to investigate this further. Can you please me provide
> > me with details of your test machine? Debian SID? x86? x86_64? tool
> > chain version? etc.
> 
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=516867
> https://buildd.debian.org/fetch.cgi?&pkg=lvm2&ver=2.02.44-1&arch=ia64&stamp=1235444991&file=log
> 
> Actually configure was not able to find rl_completion_matches but it was
> usable.

Found it...

The regression comes from libs-cleanup.patch:

-       AC_CHECK_LIB([readline], [readline], , [rl_found=no])
+       AC_CHECK_LIB([readline], [readline], [LIBS_READLINE="-lreadline
$LIBS_READLINE"], [rl_found=no])

by overriding default [ACTION-IF-FOUND], -lreadline is not part of LIBS=
that's used later on by AC_CHECK_FUNC and the test fails.

Fabio 



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

* [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions
  2009-10-09 16:29       ` Alasdair G Kergon
@ 2009-10-12  9:30         ` Fabio M. Di Nitto
  2009-10-12 10:14           ` Alasdair G Kergon
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12  9:30 UTC (permalink / raw)
  To: lvm-devel

On Fri, 2009-10-09 at 17:29 +0100, Alasdair G Kergon wrote:
> On Fri, Oct 09, 2009 at 05:01:48PM +0200, Bastian Blank wrote:
> > why is it used by
> > default? 
> 
> I'm open to changing that default.

Let's split this patch in 2:

1) OWNER/GROUP defaults, I'd say we should change the default to "".

Both Fedora and Debian drops it, all packaging systems I have seen
around expect to build/install as user and then convert to proper
owner/group as mandate by distribution policies.
I don't see a real good reason to force a default, and as upstream we
would still allow override via configure options.

2) install permissions.

I have more or less the same comment as #1. All distribution packaging
do a permission cleanup after "make install" by forcing distribution
policies.

Unless there is a real security concern behind it, I think we can
delegate such tasks to install and packagers.

The Debian defaults seem sane enough to me, but I am open to
suggestions.

Making it a configurable set of options seems a bit overkilling.

Fabio



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

* [PATCH 01/11] debian: fix library search path in example.conf
  2009-10-12  4:02         ` Fabio M. Di Nitto
@ 2009-10-12 10:03           ` Alasdair G Kergon
  2009-11-09 15:28             ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-12 10:03 UTC (permalink / raw)
  To: lvm-devel

On Mon, Oct 12, 2009 at 06:02:05AM +0200, Fabio M. Di Nitto wrote:
> On Sun, 2009-10-11 at 22:23 +0200, Bastian Blank wrote:
> > Its currently unused. The cluster locking lib was the only used external
> > lib.
 
> Alasdair, given that cluster locking lib is gone, do we have a use case
> to keep this option configurable? 

It's used for all lvm2 external libraries and needs to stay.  The
commented-out example is only worth making configurable if people are
actually installing libraries into private directories (and arguably it
should then be hard-coded into the source too).

We only stopped building the cluster locking library externally on Red
Hat distributions because of some complexities of the Red Hat build
system.  If they get resolved (as I hope they will be with RHEL6) then
we will probably reinstate it.  

Alasdair



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

* [PATCH 06/11] debian/ubuntu: make the device node creation more atomic
  2009-10-12  6:11     ` Fabio M. Di Nitto
@ 2009-10-12 10:04       ` Alasdair G Kergon
  2009-10-12 11:42         ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-12 10:04 UTC (permalink / raw)
  To: lvm-devel

On Mon, Oct 12, 2009 at 08:11:11AM +0200, Fabio M. Di Nitto wrote:
> Do you have a reference to the original submission? I can't find it on
> either lvm-devel or linux-lvm mailing lists.
 
Forwarded.  Debian bug 402132.

Alasdair



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

* [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions
  2009-10-12  9:30         ` Fabio M. Di Nitto
@ 2009-10-12 10:14           ` Alasdair G Kergon
  2009-10-12 10:54             ` Bastian Blank
  0 siblings, 1 reply; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-12 10:14 UTC (permalink / raw)
  To: lvm-devel

On Mon, Oct 12, 2009 at 11:30:30AM +0200, Fabio M. Di Nitto wrote:
> 1) OWNER/GROUP defaults, I'd say we should change the default to "".

Yes.
 
> 2) install permissions.
> 
> I have more or less the same comment as #1. All distribution packaging
> do a permission cleanup after "make install" by forcing distribution
> policies.
> 
> Unless there is a real security concern behind it, I think we can
> delegate such tasks to install and packagers.
> 
> Making it a configurable set of options seems a bit overkilling.
 
If I run this outside a packaging framework I still need the permissions
to be set.

So then leave this unchanged, and there is no point in Debian or any other
packaging system removing the existing permission setting because the packaging
system is going to override it afterwards anyway.

Alasdair



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

* [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding
  2009-10-12  9:06     ` Fabio M. Di Nitto
@ 2009-10-12 10:18       ` Alasdair G Kergon
  2009-10-12 10:45         ` Bastian Blank
  2009-10-12 14:07         ` Fabio M. Di Nitto
  0 siblings, 2 replies; 62+ messages in thread
From: Alasdair G Kergon @ 2009-10-12 10:18 UTC (permalink / raw)
  To: lvm-devel

On Mon, Oct 12, 2009 at 11:06:58AM +0200, Fabio M. Di Nitto wrote:
> For the internal view, we can switch to use PKG_CONFIG inside our
> configure.in, but that means:
> 1) it will be a hard dependency (and we recently agreed to avoid that).
> 2) we assume that lvm2 developers and packagers will build/ship with
> recent enough build dependencies to guarantee working pkg-config files.
 
So any switch would still need a fallback for when pkgconfig is not
available.  (The real question is whether pkgconfig was generally
available some time before selinux or not.  If it was, then you can
argue that everyone with access to selinux also has access to pkgconfig.)

> For the external view, as it is now, we can create the correct .pc file.
> If we detect that selinux has pkg-config support, then we use the
> "Requires.private: libselinux" that will automatically expand via
> pkg-config. If we don't have selinux pkg-config, then we can hardcode as
> we do now.
 
Yes.

Alasdair



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

* [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding
  2009-10-12 10:18       ` Alasdair G Kergon
@ 2009-10-12 10:45         ` Bastian Blank
  2009-10-12 14:07         ` Fabio M. Di Nitto
  1 sibling, 0 replies; 62+ messages in thread
From: Bastian Blank @ 2009-10-12 10:45 UTC (permalink / raw)
  To: lvm-devel

On Mon, Oct 12, 2009 at 11:18:38AM +0100, Alasdair G Kergon wrote:
> So any switch would still need a fallback for when pkgconfig is not
> available.  (The real question is whether pkgconfig was generally
> available some time before selinux or not.  If it was, then you can
> argue that everyone with access to selinux also has access to pkgconfig.)

According to the Debian changelog, pkg-config was first usable in 2001,
long before selinux was even considered a good idea.

> > For the external view, as it is now, we can create the correct .pc file.
> > If we detect that selinux has pkg-config support, then we use the
> > "Requires.private: libselinux" that will automatically expand via
> > pkg-config. If we don't have selinux pkg-config, then we can hardcode as
> > we do now.
> Yes.

Well, libselinux at least ship the file since 1.28.

Bastian

-- 
No one may kill a man.  Not for any purpose.  It cannot be condoned.
		-- Kirk, "Spock's Brain", stardate 5431.6



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

* [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions
  2009-10-12 10:14           ` Alasdair G Kergon
@ 2009-10-12 10:54             ` Bastian Blank
  0 siblings, 0 replies; 62+ messages in thread
From: Bastian Blank @ 2009-10-12 10:54 UTC (permalink / raw)
  To: lvm-devel

On Mon, Oct 12, 2009 at 11:14:57AM +0100, Alasdair G Kergon wrote:
> If I run this outside a packaging framework I still need the permissions
> to be set.

Hu? All it changes is to make them writable for the user. Having
unwritable files does not really make fun.

> So then leave this unchanged, and there is no point in Debian or any other
> packaging system removing the existing permission setting because the packaging
> system is going to override it afterwards anyway.

It still is, because it breaks my assumptions of the development process
to have unwritable files en masse.

Bastian

-- 
Each kiss is as the first.
		-- Miramanee, Kirk's wife, "The Paradise Syndrome",
		   stardate 4842.6



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

* [PATCH 06/11] debian/ubuntu: make the device node creation more atomic
  2009-10-12 10:04       ` Alasdair G Kergon
@ 2009-10-12 11:42         ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12 11:42 UTC (permalink / raw)
  To: lvm-devel

On Mon, 2009-10-12 at 11:04 +0100, Alasdair G Kergon wrote:
> On Mon, Oct 12, 2009 at 08:11:11AM +0200, Fabio M. Di Nitto wrote:
> > Do you have a reference to the original submission? I can't find it on
> > either lvm-devel or linux-lvm mailing lists.
>  
> Forwarded.  Debian bug 402132.

The old patch had hardcoded temporary file names.

This new one address the problem by using mktemp(3) and also the only
comment you had on the Debian bug.

I think it's safe to pull it in.

Fabio



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

* [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding
  2009-10-12 10:18       ` Alasdair G Kergon
  2009-10-12 10:45         ` Bastian Blank
@ 2009-10-12 14:07         ` Fabio M. Di Nitto
  1 sibling, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12 14:07 UTC (permalink / raw)
  To: lvm-devel

On Mon, 2009-10-12 at 11:18 +0100, Alasdair G Kergon wrote:
> On Mon, Oct 12, 2009 at 11:06:58AM +0200, Fabio M. Di Nitto wrote:
> > For the internal view, we can switch to use PKG_CONFIG inside our
> > configure.in, but that means:
> > 1) it will be a hard dependency (and we recently agreed to avoid that).
> > 2) we assume that lvm2 developers and packagers will build/ship with
> > recent enough build dependencies to guarantee working pkg-config files.
>  
> So any switch would still need a fallback for when pkgconfig is not
> available.  (The real question is whether pkgconfig was generally
> available some time before selinux or not.  If it was, then you can
> argue that everyone with access to selinux also has access to pkgconfig.)

Ok, this will take some more time to be done properly across the board.
I don't want to special case every library/pkgconfig in a different way.

Fabio



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

* [PATCH 02/11] debian: drop realtime
  2009-10-11 17:20           ` Fabio M. Di Nitto
@ 2009-10-12 17:03             ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-10-12 17:03 UTC (permalink / raw)
  To: lvm-devel

On Sun, 2009-10-11 at 19:20 +0200, Fabio M. Di Nitto wrote:

> this patch should make everybody happy.
> 
> Sets realitime support off by default and still allow to have it
> configurable for developers.

Committed to cvs with agk ACK.

Fabio



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

* [PATCH 01/11] debian: fix library search path in example.conf
  2009-10-12 10:03           ` Alasdair G Kergon
@ 2009-11-09 15:28             ` Fabio M. Di Nitto
  2009-11-10  5:26               ` Fabio M. Di Nitto
  0 siblings, 1 reply; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-11-09 15:28 UTC (permalink / raw)
  To: lvm-devel

Alasdair G Kergon wrote:
> On Mon, Oct 12, 2009 at 06:02:05AM +0200, Fabio M. Di Nitto wrote:
>> On Sun, 2009-10-11 at 22:23 +0200, Bastian Blank wrote:
>>> Its currently unused. The cluster locking lib was the only used external
>>> lib.
>  
>> Alasdair, given that cluster locking lib is gone, do we have a use case
>> to keep this option configurable? 
> 
> It's used for all lvm2 external libraries and needs to stay.  The
> commented-out example is only worth making configurable if people are
> actually installing libraries into private directories (and arguably it
> should then be hard-coded into the source too).
> 
> We only stopped building the cluster locking library externally on Red
> Hat distributions because of some complexities of the Red Hat build
> system.  If they get resolved (as I hope they will be with RHEL6) then
> we will probably reinstate it.  
> 

The patch in attachment:
- allows lvm2libdir to be configurable
- dynamically update docs and man pages
- changes get_shared_library_path to understand LVM2_LIB_DIR
- make get_shared_library_path returns error (void to int)
- update get_shared_library_path users

Fabio

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: lvm2libdir.diff
URL: <http://listman.redhat.com/archives/lvm-devel/attachments/20091109/2204a72c/attachment.ksh>

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

* [PATCH 01/11] debian: fix library search path in example.conf
  2009-11-09 15:28             ` Fabio M. Di Nitto
@ 2009-11-10  5:26               ` Fabio M. Di Nitto
  0 siblings, 0 replies; 62+ messages in thread
From: Fabio M. Di Nitto @ 2009-11-10  5:26 UTC (permalink / raw)
  To: lvm-devel

Fabio M. Di Nitto wrote:
> Alasdair G Kergon wrote:
>> On Mon, Oct 12, 2009 at 06:02:05AM +0200, Fabio M. Di Nitto wrote:
>>> On Sun, 2009-10-11 at 22:23 +0200, Bastian Blank wrote:
>>>> Its currently unused. The cluster locking lib was the only used external
>>>> lib.
>>  
>>> Alasdair, given that cluster locking lib is gone, do we have a use case
>>> to keep this option configurable? 
>> It's used for all lvm2 external libraries and needs to stay.  The
>> commented-out example is only worth making configurable if people are
>> actually installing libraries into private directories (and arguably it
>> should then be hard-coded into the source too).
>>
>> We only stopped building the cluster locking library externally on Red
>> Hat distributions because of some complexities of the Red Hat build
>> system.  If they get resolved (as I hope they will be with RHEL6) then
>> we will probably reinstate it.  
>>
> 
> The patch in attachment:
> - allows lvm2libdir to be configurable
> - dynamically update docs and man pages
> - changes get_shared_library_path to understand LVM2_LIB_DIR
> - make get_shared_library_path returns error (void to int)
> - update get_shared_library_path users
> 
> Fabio
> 
> 

I just realized that the patch doesn?t show properly the rename of
doc/example.conf to doc/example.conf.in. Just a minor detail.

Fabio



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

end of thread, other threads:[~2009-11-10  5:26 UTC | newest]

Thread overview: 62+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-08 11:54 RFC - Debian patches Fabio M. Di Nitto
2009-10-08 11:54 ` [PATCH 01/11] debian: fix library search path in example.conf Fabio M. Di Nitto
2009-10-08 12:49   ` Fabio M. Di Nitto
2009-10-08 12:16   ` Fabio M. Di Nitto
2009-10-08 11:58   ` Fabio M. Di Nitto
2009-10-08 23:27   ` Alasdair G Kergon
2009-10-11 17:09     ` Fabio M. Di Nitto
2009-10-11 20:23       ` Bastian Blank
2009-10-12  4:02         ` Fabio M. Di Nitto
2009-10-12 10:03           ` Alasdair G Kergon
2009-11-09 15:28             ` Fabio M. Di Nitto
2009-11-10  5:26               ` Fabio M. Di Nitto
2009-10-08 11:58 RFC - Debian patches (resend) Fabio M. Di Nitto
2009-10-08 12:16 RFC - Debian patches (resend - one more time) Fabio M. Di Nitto
2009-10-08 12:16 ` [PATCH 02/11] debian: drop realtime Fabio M. Di Nitto
2009-10-08 12:49   ` Fabio M. Di Nitto
2009-10-08 23:28   ` Alasdair G Kergon
2009-10-09 15:03     ` Bastian Blank
2009-10-09 16:24       ` Alasdair G Kergon
2009-10-10  9:21         ` Bastian Blank
2009-10-11 17:20           ` Fabio M. Di Nitto
2009-10-12 17:03             ` Fabio M. Di Nitto
2009-10-08 12:49 RFC - Debian patches (full set) Fabio M. Di Nitto
2009-10-08 12:49 ` [PATCH 03/11] debian: force modprobe Fabio M. Di Nitto
2009-10-08 23:30   ` Alasdair G Kergon
2009-10-09 15:02     ` Bastian Blank
2009-10-08 12:49 ` [PATCH 04/11] debian: fix implicit pointer Fabio M. Di Nitto
2009-10-08 23:34   ` Alasdair G Kergon
2009-10-11 17:29     ` Fabio M. Di Nitto
2009-10-11 20:20       ` Bastian Blank
2009-10-12  8:07         ` Fabio M. Di Nitto
2009-10-12  9:14         ` Fabio M. Di Nitto
2009-10-08 12:49 ` [PATCH 05/11] debian: keep libdm-abi consistent Fabio M. Di Nitto
2009-10-08 23:35   ` Alasdair G Kergon
2009-10-12  4:07     ` Fabio M. Di Nitto
2009-10-08 12:49 ` [PATCH 06/11] debian/ubuntu: make the device node creation more atomic Fabio M. Di Nitto
2009-10-08 23:39   ` Alasdair G Kergon
2009-10-12  6:11     ` Fabio M. Di Nitto
2009-10-12 10:04       ` Alasdair G Kergon
2009-10-12 11:42         ` Fabio M. Di Nitto
2009-10-08 12:49 ` [PATCH 07/11] debian: workaround for broken kernel headers Fabio M. Di Nitto
2009-10-08 23:41   ` Alasdair G Kergon
2009-10-12  8:57   ` Fabio M. Di Nitto
2009-10-08 12:49 ` [PATCH 08/11] debian: use selinux pkgconfig info instead of hardcoding Fabio M. Di Nitto
2009-10-08 23:44   ` Alasdair G Kergon
2009-10-09 14:58     ` Bastian Blank
2009-10-12  9:06     ` Fabio M. Di Nitto
2009-10-12 10:18       ` Alasdair G Kergon
2009-10-12 10:45         ` Bastian Blank
2009-10-12 14:07         ` Fabio M. Di Nitto
2009-10-08 12:49 ` [PATCH 09/11] debian: libs cleanup Fabio M. Di Nitto
2009-10-09  0:02   ` Alasdair G Kergon
2009-10-08 12:49 ` [PATCH 10/11] debian: make the subdir recursion -j capable Fabio M. Di Nitto
2009-10-08 23:57   ` Alasdair G Kergon
2009-10-09 15:00     ` Bastian Blank
2009-10-08 12:49 ` [PATCH 11/11] debian: drop concept of OWNER/GROUP and let install do it's job for permissions Fabio M. Di Nitto
2009-10-09  0:01   ` Alasdair G Kergon
2009-10-09 15:01     ` Bastian Blank
2009-10-09 16:29       ` Alasdair G Kergon
2009-10-12  9:30         ` Fabio M. Di Nitto
2009-10-12 10:14           ` Alasdair G Kergon
2009-10-12 10:54             ` Bastian Blank

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.