diff options
author | Ludovic Courtès <ludo@gnu.org> | 2019-06-25 16:44:39 +0200 |
---|---|---|
committer | Ricardo Wurmus <rekado@elephly.net> | 2019-06-25 21:40:02 +0200 |
commit | 00a51a23247f1edc4ae8eda72b30df5cd7d0015f (patch) | |
tree | c1f36aa158e34b478c756a8114f48e70e2ebbbf5 | |
parent | 058c596cd3886447da31171e1026d4d19f5f5313 (diff) |
Previously "@libdir@" would typically expand to "${exec_prefix}/…",
which wouldn't have the intended effect.
* modules/Makefile.am (python): New target.
(CLEANFILES): New variable.
* modules/configure.ac: Remove 'AC_CONFIG_FILES' for 'python'.
* modules/python.in: Use @datadir@ instead of @prefix@/share.
Signed-off-by: Ricardo Wurmus <rekado@elephly.net>
-rw-r--r-- | modules/Makefile.am | 11 | ||||
-rw-r--r-- | modules/configure.ac | 1 | ||||
-rwxr-xr-x | modules/python.in | 2 |
3 files changed, 12 insertions, 2 deletions
diff --git a/modules/Makefile.am b/modules/Makefile.am index 9d7ab54..f621dff 100644 --- a/modules/Makefile.am +++ b/modules/Makefile.am @@ -130,4 +130,15 @@ EXTRA_DIST += \ env.in \ COPYING +python: python.in + $(SED) -e 's|[@]GUILE[@]|$(GUILE)|g' \ + -e 's|[@]GUILE_EFFECTIVE_VERSION[@]|$(GUILE_EFFECTIVE_VERSION)|g' \ + -e 's|[@]VERSION[@]|$(VERSION)|g' \ + -e 's|[@]libdir[@]|$(libdir)|g' \ + -e 's|[@]datadir[@]|$(datadir)|g' \ + < "$^" > "$@.tmp" + mv "$@.tmp" "$@" + +CLEANFILES = python + nodist_bin_SCRIPTS = python diff --git a/modules/configure.ac b/modules/configure.ac index 9d483d0..5245123 100644 --- a/modules/configure.ac +++ b/modules/configure.ac @@ -13,7 +13,6 @@ GUILE_PKG([3.0 2.2 2.1 2.0]) GUILE_PROGS AC_CONFIG_FILES([Makefile]) -AC_CONFIG_FILES([python], [chmod +x python]) AC_CONFIG_FILES([env], [chmod +x env]) AC_OUTPUT diff --git a/modules/python.in b/modules/python.in index 6b57242..5d7849f 100755 --- a/modules/python.in +++ b/modules/python.in @@ -4,7 +4,7 @@ (eval-when (expand load eval) (set! %load-path - (cons "@prefix@/share/guile/site/@GUILE_EFFECTIVE_VERSION@" %load-path)) + (cons "@datadir@/guile/site/@GUILE_EFFECTIVE_VERSION@" %load-path)) (set! %load-compiled-path (cons "@libdir@/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache" %load-compiled-path))) |