All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/9] Makefile and Require cleanups
@ 2010-05-07 14:14 Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 1/9] Not using pthread library functions here Zdenek Kabelac
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

This patchset tries to address few things:

it should be fixing Gentoo linkage bug
https://bugs.gentoo.org/show_bug.cgi?id=318513
But properly linking needed librarie to .so files.
Another part is cleanup Require.private in .pc file.
2 patches are touching pthread cleanups.
One patch cleans the 'extra' cat command call from Makefile.
And the last patch introduces pkgconfigdir so user could easily
overwrite his favourite locate of .pc installation dir.

Zdenek Kabelac (9):
  Not using pthread library functions here
  Link liblvm2cmd.so with their depending libraries
  Fix linking libdevmapper-event.so
  Plugins do not use pthread or lvm2cmd directly
  Skip unneeded 'cat' command
  Use Require.private: field
  Add UDEV_PC and SELINUX_PC subst variables
  Requires.private: update
  Use pkgconfigdir for placement of .pc files

 configure                                          |    8 +++++++-
 configure.in                                       |    8 +++++++-
 daemons/dmeventd/Makefile.in                       |    5 +++--
 daemons/dmeventd/libdevmapper-event.pc.in          |    3 +--
 daemons/dmeventd/plugins/mirror/Makefile.in        |    2 +-
 daemons/dmeventd/plugins/mirror/dmeventd_mirror.c  |    2 --
 daemons/dmeventd/plugins/snapshot/Makefile.in      |    2 +-
 .../dmeventd/plugins/snapshot/dmeventd_snapshot.c  |    3 +--
 libdm/Makefile.in                                  |    2 +-
 libdm/libdevmapper.pc.in                           |    2 +-
 liblvm/Makefile.in                                 |    2 +-
 liblvm/liblvm2app.pc.in                            |    2 +-
 make.tmpl.in                                       |   15 ++++-----------
 tools/Makefile.in                                  |    3 +++
 14 files changed, 32 insertions(+), 27 deletions(-)



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

* [PATCH 1/9] Not using pthread library functions here
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 2/9] Link liblvm2cmd.so with their depending libraries Zdenek Kabelac
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel


Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 daemons/dmeventd/plugins/mirror/dmeventd_mirror.c  |    2 --
 .../dmeventd/plugins/snapshot/dmeventd_snapshot.c  |    3 +--
 2 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/daemons/dmeventd/plugins/mirror/dmeventd_mirror.c b/daemons/dmeventd/plugins/mirror/dmeventd_mirror.c
index 4d2eee5..788f9f5 100644
--- a/daemons/dmeventd/plugins/mirror/dmeventd_mirror.c
+++ b/daemons/dmeventd/plugins/mirror/dmeventd_mirror.c
@@ -19,8 +19,6 @@
 #include "libdevmapper-event.h"
 #include "dmeventd_lvm.h"
 
-#include <pthread.h>
-
 #include <syslog.h> /* FIXME Replace syslog with multilog */
 /* FIXME Missing openlog? */
 /* FIXME Replace most syslogs with log_error() style messages and add complete context. */
diff --git a/daemons/dmeventd/plugins/snapshot/dmeventd_snapshot.c b/daemons/dmeventd/plugins/snapshot/dmeventd_snapshot.c
index 01bb2c2..3c85c6d 100644
--- a/daemons/dmeventd/plugins/snapshot/dmeventd_snapshot.c
+++ b/daemons/dmeventd/plugins/snapshot/dmeventd_snapshot.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2007-2008 Red Hat, Inc. All rights reserved.
+ * Copyright (C) 2007-2010 Red Hat, Inc. All rights reserved.
  *
  * This file is part of LVM2.
  *
@@ -21,7 +21,6 @@
 
 #include "lvm-string.h"
 
-#include <pthread.h>
 #include <syslog.h> /* FIXME Replace syslog with multilog */
 /* FIXME Missing openlog? */
 
-- 
1.7.0.1



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

* [PATCH 2/9] Link liblvm2cmd.so with their depending libraries
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 1/9] Not using pthread library functions here Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 3/9] Fix linking libdevmapper-event.so Zdenek Kabelac
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

Link liblvm2cmd.so with devmapper-event and devmapper libs.
Remove generic %.so: %.a target.

Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 make.tmpl.in      |    5 -----
 tools/Makefile.in |    3 +++
 2 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/make.tmpl.in b/make.tmpl.in
index 2375e18..69fab00 100644
--- a/make.tmpl.in
+++ b/make.tmpl.in
@@ -320,11 +320,6 @@ install_lvm2_plugin: $(LIB_SHARED)
 	$(LN_S) -f $(<F) $(libdir)/$(<F).$(LIB_VERSION)
 endif
 
-%.so: %.a
-	$(CC) -shared -Wl,-soname,$(notdir $@).$(LIB_VERSION) \
-	$(CFLAGS) $(CLDFLAGS) $(LIBS) -o $@ \
-	@CLDWHOLEARCHIVE@ $< @CLDNOWHOLEARCHIVE@
-
 $(LIB_STATIC): $(OBJECTS)
 	$(RM) $@
 	$(AR) rs $@ $(OBJECTS)
diff --git a/tools/Makefile.in b/tools/Makefile.in
index 47fa2db..e7b9b6a 100644
--- a/tools/Makefile.in
+++ b/tools/Makefile.in
@@ -145,6 +145,9 @@ liblvm2cmd-static.a: $(top_builddir)/lib/liblvm-internal.a $(OBJECTS) lvmcmdlib.
 	$(AR) rs $@ $(OBJECTS) lvmcmdlib.o lvm2cmd-static.o
 
 liblvm2cmd.$(LIB_SUFFIX): liblvm2cmd.a $(LDDEPS)
+	$(CC) -shared -Wl,-soname,$@.$(LIB_VERSION) \
+	$(CFLAGS) $(CLDFLAGS) -o $@ $(LVMLIBS) $(LIBS) \
+		@CLDWHOLEARCHIVE@ liblvm2cmd.a @CLDNOWHOLEARCHIVE@
 
 liblvm2cmd.$(LIB_SUFFIX).$(LIB_VERSION): liblvm2cmd.$(LIB_SUFFIX)
 	$(LN_S) -f $< $@
-- 
1.7.0.1



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

* [PATCH 3/9] Fix linking libdevmapper-event.so
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 1/9] Not using pthread library functions here Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 2/9] Link liblvm2cmd.so with their depending libraries Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 4/9] Plugins do not use pthread or lvm2cmd directly Zdenek Kabelac
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

As for now LIB_SHARED links $(LIBS) so use this to add .so dependency on
libdevmapper.so during creation of shared library.

Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 daemons/dmeventd/Makefile.in |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/daemons/dmeventd/Makefile.in b/daemons/dmeventd/Makefile.in
index fb4f8f5..f9afdb6 100644
--- a/daemons/dmeventd/Makefile.in
+++ b/daemons/dmeventd/Makefile.in
@@ -53,7 +53,8 @@ include $(top_builddir)/make.tmpl
 all: device-mapper
 device-mapper: $(TARGETS)
 
-LVMLIBS += -ldevmapper-event -ldevmapper $(PTHREAD_LIBS)
+LIBS += -ldevmapper
+LVMLIBS += -ldevmapper-event $(PTHREAD_LIBS)
 
 dmeventd: $(LIB_SHARED) dmeventd.o
 	$(CC) $(CFLAGS) $(LDFLAGS) -L. -o $@ dmeventd.o \
-- 
1.7.0.1



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

* [PATCH 4/9] Plugins do not use pthread or lvm2cmd directly
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
                   ` (2 preceding siblings ...)
  2010-05-07 14:14 ` [PATCH 3/9] Fix linking libdevmapper-event.so Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 5/9] Skip unneeded 'cat' command Zdenek Kabelac
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

Plugins are using pthread and lvm2cmd library indirectly
via devmapper-event-lvm2.

Thus skip the linkage of these libs to created .so plugins.

Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 daemons/dmeventd/plugins/mirror/Makefile.in   |    2 +-
 daemons/dmeventd/plugins/snapshot/Makefile.in |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/daemons/dmeventd/plugins/mirror/Makefile.in b/daemons/dmeventd/plugins/mirror/Makefile.in
index 5966f24..3c3d468 100644
--- a/daemons/dmeventd/plugins/mirror/Makefile.in
+++ b/daemons/dmeventd/plugins/mirror/Makefile.in
@@ -30,7 +30,7 @@ CFLOW_LIST_TARGET = $(LIB_NAME).cflow
 
 include $(top_builddir)/make.tmpl
 
-LIBS += @LVM2CMD_LIB@ -ldevmapper-event-lvm2 -ldevmapper $(PTHREAD_LIBS)
+LIBS += -ldevmapper-event-lvm2 -ldevmapper
 
 install_lvm2: install_dm_plugin
 
diff --git a/daemons/dmeventd/plugins/snapshot/Makefile.in b/daemons/dmeventd/plugins/snapshot/Makefile.in
index 32a74af..87a55e7 100644
--- a/daemons/dmeventd/plugins/snapshot/Makefile.in
+++ b/daemons/dmeventd/plugins/snapshot/Makefile.in
@@ -26,7 +26,7 @@ LIB_VERSION = $(LIB_VERSION_LVM)
 
 include $(top_builddir)/make.tmpl
 
-LIBS += @LVM2CMD_LIB@ -ldevmapper-event-lvm2 -ldevmapper $(PTHREAD_LIBS)
+LIBS += -ldevmapper-event-lvm2 -ldevmapper
 
 install_lvm2: install_dm_plugin
 
-- 
1.7.0.1



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

* [PATCH 5/9] Skip unneeded 'cat' command
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
                   ` (3 preceding siblings ...)
  2010-05-07 14:14 ` [PATCH 4/9] Plugins do not use pthread or lvm2cmd directly Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 6/9] Use Require.private: field Zdenek Kabelac
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 make.tmpl.in |    9 +++------
 1 files changed, 3 insertions(+), 6 deletions(-)

diff --git a/make.tmpl.in b/make.tmpl.in
index 69fab00..6d9f681 100644
--- a/make.tmpl.in
+++ b/make.tmpl.in
@@ -142,14 +142,11 @@ STRIP=
 
 LVM_VERSION := $(shell cat $(top_srcdir)/VERSION)
 
-LIB_VERSION_LVM := $(shell cat $(top_srcdir)/VERSION | \
-		     $(AWK) -F '.' '{printf "%s.%s",$$1,$$2}')
+LIB_VERSION_LVM := $(shell $(AWK) -F '.' '{printf "%s.%s",$$1,$$2}' $(top_srcdir)/VERSION)
 
-LIB_VERSION_DM := $(shell cat $(top_srcdir)/VERSION_DM | \
-		    $(AWK) -F '.' '{printf "%s.%s",$$1,$$2}')
+LIB_VERSION_DM := $(shell $(AWK) -F '.' '{printf "%s.%s",$$1,$$2}' $(top_srcdir)/VERSION_DM)
 
-LIB_VERSION_APP := $(shell cat $(top_srcdir)/VERSION | \
-		     $(AWK) -F '[(). ]' '{printf "%s.%s",$$1,$$4}')
+LIB_VERSION_APP := $(shell $(AWK) -F '[(). ]' '{printf "%s.%s",$$1,$$4}' $(top_srcdir)/VERSION)
 
 INCLUDES += -I. -I$(top_builddir)/include
 
-- 
1.7.0.1



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

* [PATCH 6/9] Use Require.private: field
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
                   ` (4 preceding siblings ...)
  2010-05-07 14:14 ` [PATCH 5/9] Skip unneeded 'cat' command Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 7/9] Add UDEV_PC and SELINUX_PC subst variables Zdenek Kabelac
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

Move devmapper to Require.private: field.
Remove unneeded libs from Libs.private:

Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 daemons/dmeventd/libdevmapper-event.pc.in |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/daemons/dmeventd/libdevmapper-event.pc.in b/daemons/dmeventd/libdevmapper-event.pc.in
index 49cad5a..839433f 100644
--- a/daemons/dmeventd/libdevmapper-event.pc.in
+++ b/daemons/dmeventd/libdevmapper-event.pc.in
@@ -6,7 +6,6 @@ includedir=@includedir@
 Name: devmapper-event
 Description: device-mapper event library
 Version: @DM_LIB_PATCHLEVEL@
-Requires: devmapper
 Cflags: -I${includedir}
 Libs: -L${libdir} -ldevmapper-event
-Libs.private: -lpthread -ldl
+Requires.private: devmapper
-- 
1.7.0.1



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

* [PATCH 7/9] Add UDEV_PC and SELINUX_PC subst variables
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
                   ` (5 preceding siblings ...)
  2010-05-07 14:14 ` [PATCH 6/9] Use Require.private: field Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 8/9] Requires.private: update Zdenek Kabelac
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

Use UDEV_PC and SELINUX_PC later in Requires.private: .pc files.

Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 configure    |    8 +++++++-
 configure.in |    8 +++++++-
 2 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/configure b/configure
index f0ce691..2f8781c 100755
--- a/configure
+++ b/configure
@@ -649,10 +649,12 @@ interface
 WRITE_INSTALL
 UDEV_SYNC
 UDEV_RULES
+UDEV_PC
 UDEV_LIBS
 STATIC_LINK
 STATICDIR
 SNAPSHOTS
+SELINUX_PC
 SELINUX_LIBS
 READLINE_LIBS
 PTHREAD_LIBS
@@ -12327,7 +12329,7 @@ fi
 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_udev_udev_queue_get_udev_is_active" >&5
 $as_echo "$ac_cv_lib_udev_udev_queue_get_udev_is_active" >&6; }
 if test "x$ac_cv_lib_udev_udev_queue_get_udev_is_active" = x""yes; then
-  UDEV_LIBS="-ludev"
+  UDEV_PC="libudev"; UDEV_LIBS="-ludev"
 else
   { { $as_echo "$as_me:$LINENO: error: bailing out... libudev library is required" >&5
 $as_echo "$as_me: error: bailing out... libudev library is required" >&2;}
@@ -13141,12 +13143,14 @@ cat >>confdefs.h <<\_ACEOF
 _ACEOF
 
 		SELINUX_LIBS="-lselinux $SELINUX_LIBS"
+		SELINUX_PC="libselinux"
 		HAVE_SELINUX=yes
 else
 
 		{ $as_echo "$as_me:$LINENO: WARNING: Disabling selinux" >&5
 $as_echo "$as_me: WARNING: Disabling selinux" >&2;}
 		SELINUX_LIBS=
+		SELINUX_PC=
 		HAVE_SELINUX=no
 fi
 
@@ -15610,6 +15614,8 @@ LVM_LIBAPI=`echo "$VER" | $AWK -F '[()]' '{print $2}'`
 
 
 
+
+
 ################################################################################
 ac_config_files="$ac_config_files Makefile make.tmpl daemons/Makefile daemons/clvmd/Makefile daemons/cmirrord/Makefile daemons/dmeventd/Makefile daemons/dmeventd/libdevmapper-event.pc daemons/dmeventd/plugins/Makefile daemons/dmeventd/plugins/lvm2/Makefile daemons/dmeventd/plugins/mirror/Makefile daemons/dmeventd/plugins/snapshot/Makefile doc/Makefile include/.symlinks include/Makefile lib/Makefile lib/format1/Makefile lib/format_pool/Makefile lib/locking/Makefile lib/mirror/Makefile lib/misc/lvm-version.h lib/snapshot/Makefile libdm/Makefile libdm/libdevmapper.pc liblvm/Makefile liblvm/liblvm2app.pc man/Makefile po/Makefile scripts/clvmd_init_red_hat scripts/cmirrord_init_red_hat scripts/lvm2_monitoring_init_red_hat scripts/Makefile test/Makefile test/api/Makefile tools/Makefile udev/Makefile"
 
diff --git a/configure.in b/configure.in
index 4594559..b2a6e0c 100644
--- a/configure.in
+++ b/configure.in
@@ -659,7 +659,9 @@ UDEV_SYNC=$enableval, UDEV_SYNC=no)
 AC_MSG_RESULT($UDEV_SYNC)
 
 if test x$UDEV_SYNC = xyes; then
-	AC_CHECK_LIB(udev, udev_queue_get_udev_is_active, UDEV_LIBS="-ludev", AC_MSG_ERROR(bailing out... libudev library is required))
+	AC_CHECK_LIB(udev, udev_queue_get_udev_is_active,
+		     [UDEV_PC="libudev"; UDEV_LIBS="-ludev"],
+		     [AC_MSG_ERROR([bailing out... libudev library is required])])
 	AC_DEFINE([UDEV_SYNC_SUPPORT], 1, [Define to 1 to enable synchronisation with udev processing.])
 fi
 
@@ -831,9 +833,11 @@ if test x$SELINUX = xyes; then
 		AC_CHECK_HEADERS([selinux/selinux.h],, hard_bailout)
 		AC_DEFINE([HAVE_SELINUX], 1, [Define to 1 to include support for selinux.])
 		SELINUX_LIBS="-lselinux $SELINUX_LIBS"
+		SELINUX_PC="libselinux"
 		HAVE_SELINUX=yes ], [
 		AC_MSG_WARN(Disabling selinux)
 		SELINUX_LIBS=
+		SELINUX_PC=
 		HAVE_SELINUX=no ])
 fi
 
@@ -1117,10 +1121,12 @@ AC_SUBST(SACKPT_LIBS)
 AC_SUBST(SALCK_CFLAGS)
 AC_SUBST(SALCK_LIBS)
 AC_SUBST(SELINUX_LIBS)
+AC_SUBST(SELINUX_PC)
 AC_SUBST(SNAPSHOTS)
 AC_SUBST(STATICDIR)
 AC_SUBST(STATIC_LINK)
 AC_SUBST(UDEV_LIBS)
+AC_SUBST(UDEV_PC)
 AC_SUBST(UDEV_RULES)
 AC_SUBST(UDEV_SYNC)
 AC_SUBST(WRITE_INSTALL)
-- 
1.7.0.1



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

* [PATCH 8/9] Requires.private: update
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
                   ` (6 preceding siblings ...)
  2010-05-07 14:14 ` [PATCH 7/9] Add UDEV_PC and SELINUX_PC subst variables Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 14:14 ` [PATCH 9/9] Use pkgconfigdir for placement of .pc files Zdenek Kabelac
  2010-05-07 16:42 ` [PATCH 0/9] Makefile and Require cleanups Alasdair G Kergon
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

Use Requires.private: instead of Libs.private:
Use UDEV_PC and SELINUX_PC for Require.private:

It looks like usage of Requires.private is prefered from Libs.private.
However pkg-config documentation is really poor here. But here is
short outcome:

There is a difference in Libs.private: and Requires.private: where
we specify libselinux instead of  -lselinux -lsepol
We essentially leave resolving of query  pkg-config --libs --static devmapper
on taking proper selinux and udev libs to their .pc files instead of
hardcoding them into our .pc file which is wrong - i.e. dependency of
libselinux package might change - but we may not return proper value for
static linking.

http://bugs.freedesktop.org/show_bug.cgi?id=4738
http://err.no/personal/blog/tech/2008-03-25-18-07_pkg-config,_sonames_and_Requires.private

Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 libdm/libdevmapper.pc.in |    2 +-
 liblvm/liblvm2app.pc.in  |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/libdm/libdevmapper.pc.in b/libdm/libdevmapper.pc.in
index 5910583..eb7071d 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@ @UDEV_LIBS@
+Requires.private: @SELINUX_PC@ @UDEV_PC@
diff --git a/liblvm/liblvm2app.pc.in b/liblvm/liblvm2app.pc.in
index 6bf8ecd..4c71c36 100644
--- a/liblvm/liblvm2app.pc.in
+++ b/liblvm/liblvm2app.pc.in
@@ -8,4 +8,4 @@ Description: lvm2 application library
 Version: @LVM_MAJOR at .@LVM_LIBAPI@
 Cflags: -I${includedir} 
 Libs: -L${libdir} -llvm2app
-Libs.private: -ldevmapper
+Requires.private: devmapper
-- 
1.7.0.1



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

* [PATCH 9/9] Use pkgconfigdir for placement of .pc files
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
                   ` (7 preceding siblings ...)
  2010-05-07 14:14 ` [PATCH 8/9] Requires.private: update Zdenek Kabelac
@ 2010-05-07 14:14 ` Zdenek Kabelac
  2010-05-07 16:42 ` [PATCH 0/9] Makefile and Require cleanups Alasdair G Kergon
  9 siblings, 0 replies; 11+ messages in thread
From: Zdenek Kabelac @ 2010-05-07 14:14 UTC (permalink / raw)
  To: lvm-devel

Use easily replaceable make install pkgconfigdir variable.

Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
---
 daemons/dmeventd/Makefile.in |    2 +-
 libdm/Makefile.in            |    2 +-
 liblvm/Makefile.in           |    2 +-
 make.tmpl.in                 |    1 +
 4 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/daemons/dmeventd/Makefile.in b/daemons/dmeventd/Makefile.in
index f9afdb6..0850a19 100644
--- a/daemons/dmeventd/Makefile.in
+++ b/daemons/dmeventd/Makefile.in
@@ -81,7 +81,7 @@ install_include: $(srcdir)/libdevmapper-event.h
 	$(INSTALL_DATA) -D $< $(includedir)/$(<F)
 
 install_pkgconfig: libdevmapper-event.pc
-	$(INSTALL_DATA) -D $< $(usrlibdir)/pkgconfig/devmapper-event.pc
+	$(INSTALL_DATA) -D $< $(pkgconfigdir)/devmapper-event.pc
 
 install_lib_dynamic: install_lib_shared
 
diff --git a/libdm/Makefile.in b/libdm/Makefile.in
index ba62984..6e24eb7 100644
--- a/libdm/Makefile.in
+++ b/libdm/Makefile.in
@@ -85,7 +85,7 @@ install_static: install_@interface@_static
 install_ioctl: install_lib_shared
 
 install_pkgconfig: libdevmapper.pc
-	$(INSTALL_DATA) -D $< $(usrlibdir)/pkgconfig/devmapper.pc
+	$(INSTALL_DATA) -D $< $(pkgconfigdir)/devmapper.pc
 
 install_ioctl_static: $(LIB_STATIC)
 	$(INSTALL_DATA) -D $< $(usrlibdir)/$(<F)
diff --git a/liblvm/Makefile.in b/liblvm/Makefile.in
index 6690429..197f1d1 100644
--- a/liblvm/Makefile.in
+++ b/liblvm/Makefile.in
@@ -65,7 +65,7 @@ install_static: $(LIB_STATIC)
 	$(INSTALL_DATA) -D $< $(usrlibdir)/$(<F)
 
 install_pkgconfig: $(LIB_NAME).pc
-	$(INSTALL_DATA) -D $< $(usrlibdir)/pkgconfig/lvm2app.pc
+	$(INSTALL_DATA) -D $< $(pkgconfigdir)/lvm2app.pc
 
 liblvm.cflow: $(SOURCES)
 	set -e; (echo -n "SOURCES += "; \
diff --git a/make.tmpl.in b/make.tmpl.in
index 6d9f681..c22a6d1 100644
--- a/make.tmpl.in
+++ b/make.tmpl.in
@@ -63,6 +63,7 @@ mandir = $(datarootdir)/man
 localedir = $(DESTDIR)@LOCALEDIR@
 staticdir = $(DESTDIR)@STATICDIR@
 udevdir = $(DESTDIR)@udevdir@
+pkgconfigdir = $(usrlibdir)/pkgconfig
 USRLIB_RELPATH = $(shell echo $(abspath $(usrlibdir) $(libdir)) | \
   $(AWK) -f $(top_srcdir)/scripts/relpath.awk)
 
-- 
1.7.0.1



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

* [PATCH 0/9] Makefile and Require cleanups
  2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
                   ` (8 preceding siblings ...)
  2010-05-07 14:14 ` [PATCH 9/9] Use pkgconfigdir for placement of .pc files Zdenek Kabelac
@ 2010-05-07 16:42 ` Alasdair G Kergon
  9 siblings, 0 replies; 11+ messages in thread
From: Alasdair G Kergon @ 2010-05-07 16:42 UTC (permalink / raw)
  To: lvm-devel

On Fri, May 07, 2010 at 04:14:47PM +0200, Zdenek Kabelac wrote:
> This patchset tries to address few things:
 
Ack.

Alasdair



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

end of thread, other threads:[~2010-05-07 16:42 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-05-07 14:14 [PATCH 0/9] Makefile and Require cleanups Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 1/9] Not using pthread library functions here Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 2/9] Link liblvm2cmd.so with their depending libraries Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 3/9] Fix linking libdevmapper-event.so Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 4/9] Plugins do not use pthread or lvm2cmd directly Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 5/9] Skip unneeded 'cat' command Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 6/9] Use Require.private: field Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 7/9] Add UDEV_PC and SELINUX_PC subst variables Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 8/9] Requires.private: update Zdenek Kabelac
2010-05-07 14:14 ` [PATCH 9/9] Use pkgconfigdir for placement of .pc files Zdenek Kabelac
2010-05-07 16:42 ` [PATCH 0/9] Makefile and Require cleanups Alasdair G Kergon

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.