changeset 40103:a92075582b06

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 prefix).
author Akim Demaille <akim.demaille@gmail.com>
date Sun, 13 Jan 2019 19:48:35 +0100
parents c98985691335
children f9262966eef6
files ChangeLog doc/relocatable-maint.texi
diffstat 2 files changed, 16 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sun Jan 13 11:16:20 2019 +0100
+++ b/ChangeLog	Sun Jan 13 19:48:35 2019 +0100
@@ -1,3 +1,11 @@
+2019-01-13  Akim Demaille  <akim@lrde.epita.fr>
+
+	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
+	prefix).
+
 2019-01-13  Akim Demaille  <akim@lrde.epita.fr>
 
 	backup: update dependencies
--- a/doc/relocatable-maint.texi	Sun Jan 13 11:16:20 2019 +0100
+++ b/doc/relocatable-maint.texi	Sun Jan 13 19:48:35 2019 +0100
@@ -122,8 +122,12 @@
 
 @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 @@
 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