On 2010-09-29 Brad Jorsch <[email protected]> wrote:
[...]
> The solution is to generate the files needing these paths from the
> Makefile rather than from ./configure, because make does fully expand
> all those levels.
[...]

Hello,

the sideffect of this generation is that pkgconfigfiles are not built
and installed anymore. Straightforward fix attached.

cu andreas

>From 1f3788ef0f047133ea6841c278099219375d8ca0 Mon Sep 17 00:00:00 2001
From: Andreas Metzler <[email protected]>
Date: Sat, 16 Oct 2010 15:59:41 +0200
Subject: [PATCH 2/2] Simplify/fix pkgconfig installation

Patch "Fix path substitutions" moved generation of pkgconfig files from
./configure to Makefiles. However the generation is not triggered since
the pkgconfig files are not listed as dependency. Fix by conversion to a
straightforward automake rule.
---
 WINGs/Makefile.am |   14 ++++----------
 wrlib/Makefile.am |   17 ++++-------------
 2 files changed, 8 insertions(+), 23 deletions(-)

diff --git a/WINGs/Makefile.am b/WINGs/Makefile.am
index 95f829b..8616ae4 100644
--- a/WINGs/Makefile.am
+++ b/WINGs/Makefile.am
@@ -86,7 +86,10 @@ AM_CFLAGS =
 INCLUDES = -I$(top_srcdir)/WINGs/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \
 	@XFTFLAGS@ @HEADER_SEARCH_PATH@
 
-DISTCLEANFILES = WINGs.pc get-wings-flags get-wutil-flags
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = WINGs.pc
+
+DISTCLEANFILES = $(pkgconfig_DATA) get-wings-flags get-wutil-flags
 
 WINGs.pc: Makefile
 	@echo "Generating $@"
@@ -114,12 +117,3 @@ get-wutil-flags: get-wutil-flags.in Makefile
 	        -e 's#$${INTLIBS}#$(INTLIBS)#;' < $< > $@
 	@chmod 755 $@
 
-install-exec-local:
-	@$(NORMAL_INSTALL)
-	$(mkinstalldirs) $(DESTDIR)$(libdir)/pkgconfig
-	@list='WINGs.pc'; for p in $$list; do \
-	  if test -f $$p; then \
-	    echo "$(INSTALL_DATA) $$p $(DESTDIR)$(libdir)/pkgconfig/"; \
-	    $(INSTALL_DATA) $$p $(DESTDIR)$(libdir)/pkgconfig/; \
-	  else :; fi; \
-	done
diff --git a/wrlib/Makefile.am b/wrlib/Makefile.am
index 4f6062b..01bcb80 100644
--- a/wrlib/Makefile.am
+++ b/wrlib/Makefile.am
@@ -49,7 +49,10 @@ INCLUDES = $(DFLAGS) @HEADER_SEARCH_PATH@
 
 libwraster_la_LIBADD = @LIBRARY_SEARCH_PATH@ @GFXLIBS@ @XLIBS@ @LIBXMU@ -lm
 
-DISTCLEANFILES = wrlib.pc get-wraster-flags
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = wrlib.pc
+
+DISTCLEANFILES = $(pkgconfig_DATA) get-wraster-flags
 
 wrlib.pc: Makefile
 	@echo "Generating $@"
@@ -67,15 +70,3 @@ get-wraster-flags: get-wraster-flags.in Makefile
 	        -e 's#$${XLIBS}#$(XLIBS)#;' < $< > $@
 	@chmod 755 $@
 
-
-install-exec-local:
-	@$(NORMAL_INSTALL)
-	$(mkinstalldirs) $(DESTDIR)$(libdir)/pkgconfig
-	@list='wrlib.pc'; for p in $$list; do \
-	  if test -f $$p; then \
-	    echo "$(INSTALL_DATA) $$p $(DESTDIR)$(libdir)/pkgconfig/"; \
-	    $(INSTALL_DATA) $$p $(DESTDIR)$(libdir)/pkgconfig/; \
-	  else :; fi; \
-	done
-
-
-- 
1.7.1

Reply via email to