[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] 01/02: Add the 'guild' and 'guile' variables to 'guile-2
From: |
Ludovic Courtès |
Subject: |
[Guile-commits] 01/02: Add the 'guild' and 'guile' variables to 'guile-2.0.pc'. |
Date: |
Wed, 03 Dec 2014 18:08:09 +0000 |
civodul pushed a commit to branch stable-2.0
in repository guile.
commit 5fac1a7ada362d78f13143acbc0ceca7f2f101de
Author: Ludovic Courtès <address@hidden>
Date: Wed Dec 3 18:59:00 2014 +0100
Add the 'guild' and 'guile' variables to 'guile-2.0.pc'.
* configure.ac: Remove meta/guile-2.0.pc and
meta/guile-2.0-uninstalled.pc from 'AC_CONFIG_FILES'.
* meta/Makefile.am (substitute): New variable.
(guile-2.0.pc, guile-2.0-uninstalled.pc): New targets.
(guile-config, guild): Use $(substitute) instead of duplicated sed
script.
(CLEANFILES): Add the .pc files.
* meta/guile-2.0.pc.in (bindir, guild, guile): New variables.
* doc/ref/libguile-parallel.texi (Parallel Installations): Document the
'guild' and 'guile' pkg-config variables.
---
configure.ac | 3 --
doc/ref/libguile-parallel.texi | 19 ++++++++++++++-
meta/Makefile.am | 49 +++++++++++++++++++++++++++++----------
meta/guile-2.0.pc.in | 7 +++++
4 files changed, 60 insertions(+), 18 deletions(-)
diff --git a/configure.ac b/configure.ac
index 4f40736..d3a27eb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1670,9 +1670,6 @@ AC_CONFIG_FILES([
module/Makefile
])
-AC_CONFIG_FILES([meta/guile-2.0.pc])
-AC_CONFIG_FILES([meta/guile-2.0-uninstalled.pc])
-
GUILE_CONFIG_SCRIPT([check-guile])
GUILE_CONFIG_SCRIPT([benchmark-guile])
GUILE_CONFIG_SCRIPT([meta/guile])
diff --git a/doc/ref/libguile-parallel.texi b/doc/ref/libguile-parallel.texi
index 37a7139..50b5339 100644
--- a/doc/ref/libguile-parallel.texi
+++ b/doc/ref/libguile-parallel.texi
@@ -1,7 +1,7 @@
@c -*-texinfo-*-
@c This is part of the GNU Guile Reference Manual.
address@hidden Copyright (C) 1996, 1997, 2000, 2001, 2002, 2003, 2004, 2005,
2010, 2011
address@hidden Free Software Foundation, Inc.
address@hidden Copyright (C) 1996, 1997, 2000, 2001, 2002, 2003, 2004, 2005,
2010, 2011,
address@hidden 2014 Free Software Foundation, Inc.
@c See the file guile.texi for copying conditions.
@node Parallel Installations
@@ -55,6 +55,21 @@ The default directory where Guile looks for
extensions---i.e., shared
libraries providing additional features (@pxref{Modules and
Extensions}). Run @command{pkg-config address@hidden
--variable=extensiondir} to see its value.
+
address@hidden guile
address@hidden guild
address@hidden program name transformations, dealing with
+The absolute file name of the @command{guile} and @command{guild}
address@hidden @code{guile} and @code{guild} variables defined
+starting from Guile version 2.0.12.}. Run @command{pkg-config
address@hidden --variable=guile} or
address@hidden to see their value.
+
+These variables allow users to deal with program name transformations
+that may be specified when configuring Guile with
address@hidden, @code{--program-suffix}, or
address@hidden (@pxref{Transformation Options,,, autoconf, GNU
+Autoconf Manual}).
@end table
@noindent
diff --git a/meta/Makefile.am b/meta/Makefile.am
index 57644bc..5f19db5 100644
--- a/meta/Makefile.am
+++ b/meta/Makefile.am
@@ -44,24 +44,47 @@ pkgconfig_DATA = guile-2.0.pc
aclocaldir = $(datadir)/aclocal
aclocal_DATA = guile.m4
+# Script to instantiate substitution variables found on the standard
+# input. We do this from the Makefile because we need things like
+# $(program_transform_name), which are not usable from 'configure.ac'.
+substitute = \
+ guile="`echo guile | $(SED) -e '$(program_transform_name)'`" ; \
+ guild="`echo guild | $(SED) -e '$(program_transform_name)'`" ; \
+ installed_guile="@bindir@/$$guile" ; \
+ $(SED) -e "s,address@hidden@],$(PACKAGE_NAME),g" \
+ -e "s,address@hidden@],$(PACKAGE_BUGREPORT),g" \
+ -e "s,address@hidden@],$(PKG_CONFIG),g" \
+ -e "s,address@hidden@],$(pkgconfigdir),g" \
+ -e "s,address@hidden@],$(prefix),g" \
+ -e "s,address@hidden@],$(exec_prefix),g" \
+ -e "s,address@hidden@],$(bindir),g" \
+ -e "s,address@hidden@],$(libdir),g" \
+ -e "s,address@hidden@],$(includedir),g" \
+ -e "s,address@hidden@],$(datarootdir),g" \
+ -e "s,address@hidden@],$(datadir),g" \
+ -e "s,address@hidden@],$(sitedir),g" \
+ -e "s,address@hidden@],$$guile,g"
\
+ -e "s,address@hidden@],$$guild,g"
\
+ -e "s,address@hidden@],$$installed_guile,g"
+
+guile-2.0.pc: guile-2.0.pc.in
+ $(substitute) < "$<" > "address@hidden"
+ mv "address@hidden" "$@"
+
+guile-2.0-uninstalled.pc: guile-2.0-uninstalled.pc.in
+ $(substitute) < "$<" > "address@hidden"
+ mv "address@hidden" "$@"
+
guile-config: $(srcdir)/guile-config.in $(top_builddir)/config.status
- guile="@bindir@/`echo guile | $(SED) -e '$(program_transform_name)'`" ;
\
- $(SED) -e "s,address@hidden@],$(pkgconfigdir),g"
\
- -e "s,address@hidden@],$(PKG_CONFIG),g"
\
- -e "s,address@hidden@],$$guile,g"
\
- < "$(srcdir)/guile-config.in"
\
- > "address@hidden"
+ $(substitute) < "$<" > "address@hidden"
chmod +x "address@hidden"
mv "address@hidden" "$@"
guild: $(srcdir)/guild.in $(top_builddir)/config.status
- guile="@bindir@/`echo guile | $(SED) -e '$(program_transform_name)'`" ;
\
- $(SED) -e "s,address@hidden@],$$guile,g"
\
- -e "s,address@hidden@],$(PACKAGE_NAME),g"
\
- -e "s,address@hidden@],$(PACKAGE_BUGREPORT),g" \
- < "$(srcdir)/guild.in"
\
- > "address@hidden"
+ $(substitute) < "$<" > "address@hidden"
chmod +x "address@hidden"
mv "address@hidden" "$@"
-CLEANFILES = guile-config guild
+CLEANFILES = \
+ guile-config guild \
+ guile-2.0.pc guile-2.0-uninstalled.pc
diff --git a/meta/guile-2.0.pc.in b/meta/guile-2.0.pc.in
index 1bda734..c8f485b 100644
--- a/meta/guile-2.0.pc.in
+++ b/meta/guile-2.0.pc.in
@@ -1,5 +1,6 @@
address@hidden@
address@hidden@
address@hidden@
address@hidden@
address@hidden@
address@hidden@
@@ -11,6 +12,12 @@ address@hidden@
address@hidden@/guile/@GUILE_EFFECTIVE_VERSION@/extensions
address@hidden@
+# Actual name of the 'guile' and 'guild' programs. This is
+# particularly useful when '--program-transform-name' or similar has
+# been used.
+guild=${bindir}/@guild@
+guile=${bindir}/@guile@
+
Name: GNU Guile
Description: GNU's Ubiquitous Intelligent Language for Extension
Version: @GUILE_VERSION@