[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
relocatable: improve documentation
From: |
Akim Demaille |
Subject: |
relocatable: improve documentation |
Date: |
Sun, 13 Jan 2019 19:59:06 +0100 |
If we follow blindly the documentation, it won't work, as some variables
substituted by config.status depend on other variables.
Alternatively, @relocatable_sh@ could define these variables.
commit c3d916e5a4d4da2319c4d4eaf79cdc09fcfd6a36
Author: Akim Demaille <address@hidden>
Date: Sun Jan 13 19:48:35 2019 +0100
relocatable: improve documentation
* doc/relocatable-maint.texi (Supporting Relocation): For
substitutions performed by config.status, we need more variables
(for instance datarootdir defaults to '${prefix}/share' so we need
'${share}).
diff --git a/ChangeLog b/ChangeLog
index d49779499..9b7acd9e0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2019-01-13 Akim Demaille <address@hidden>
+
+ relocatable: improve documentation.
+ * doc/relocatable-maint.texi (Supporting Relocation): For
+ substitutions performed by config.status, we need more variables
+ (for instance datarootdir defaults to '${prefix}/share' so we need
+ '${share}).
+
2019-01-13 Akim Demaille <address@hidden>
backup: update dependencies
diff --git a/doc/relocatable-maint.texi b/doc/relocatable-maint.texi
index d1e7090bc..b95caaf7c 100644
--- a/doc/relocatable-maint.texi
+++ b/doc/relocatable-maint.texi
@@ -122,8 +122,12 @@ shell script that your package installs, add the following:
@smallexample
@@relocatable_sh@@
+
+prefix="@@prefix@@"
+exec_prefix="@@exec_prefix@@" # usually needs $prefix.
+datarootdir="@@datarootdir@@" # usually needs $prefix.
+
if test "@@RELOCATABLE@@" = yes; then
- exec_prefix="@@exec_prefix@@"
bindir="@@bindir@@"
orig_installdir="$bindir" # see Makefile.am's *_SCRIPTS variables
func_find_curr_installdir # determine curr_installdir
@@ -140,8 +144,9 @@ else
fi
# Get some relocated directory names.
-sysconfdir=`relocate "@@sysconfdir@@"`
-some_datadir=`relocate "@@datadir@@/something"`
+sysconfdir=`relocate "@@sysconfdir@@"` # usually needs $prefix.
+some_datadir=`relocate "@@datadir@@/something"` # usually needs $datarootdir.
+bindir=`relocate "@@bindir@@"` # usually needs $exec_prefix, hence
$prefix.
@end smallexample
You must adapt the definition of @code{orig_installdir}, depending on
- relocatable: improve documentation,
Akim Demaille <=