From: Bruno Haible Date: Mon, 7 Apr 2003 10:47:22 +0000 (+0000) Subject: Emit a "checking whether to activate relocatable installation" message. X-Git-Tag: v0.12~92 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=11ef312a92d1a180c825685cfb2c9d7766c5105d;p=thirdparty%2Fgettext.git Emit a "checking whether to activate relocatable installation" message. New macro AC_RELOCATABLE_NOP. --- diff --git a/gettext-tools/m4/ChangeLog b/gettext-tools/m4/ChangeLog index 41af4536f..23a206d0a 100644 --- a/gettext-tools/m4/ChangeLog +++ b/gettext-tools/m4/ChangeLog @@ -1,3 +1,8 @@ +2003-04-06 Bruno Haible + + * relocatable.m4 (AC_RELOCATABLE_NOP): New macro. + (AC_RELOCATABLE_LIBRARY): Use it. + 2003-04-05 Bruno Haible * canonicalize.m4 (gl_CANONICALIZE): Use AC_CHECK_FUNCS, so that diff --git a/gettext-tools/m4/relocatable.m4 b/gettext-tools/m4/relocatable.m4 index d8888989e..febd0f5e4 100644 --- a/gettext-tools/m4/relocatable.m4 +++ b/gettext-tools/m4/relocatable.m4 @@ -54,6 +54,21 @@ AC_DEFUN([AC_RELOCATABLE], dnl Support for relocatable libraries. AC_DEFUN([AC_RELOCATABLE_LIBRARY], [ + AC_REQUIRE([AC_RELOCATABLE_NOP]) + dnl Easier to put this here once, instead of into the DEFS of each Makefile. + if test "X$prefix" = "XNONE"; then + reloc_final_prefix="$ac_default_prefix" + else + reloc_final_prefix="$prefix" + fi + AC_DEFINE_UNQUOTED([INSTALLPREFIX], ["${reloc_final_prefix}"], + [Define to the value of ${prefix}, as a string.]) +]) + +dnl Support for relocatable packages for which it is a nop. +AC_DEFUN([AC_RELOCATABLE_NOP], +[ + AC_MSG_CHECKING([whether to activate relocatable installation]) AC_ARG_ENABLE(relocatable, [ --enable-relocatable install a package that can be moved in the filesystem], [if test "$enableval" != no; then @@ -63,14 +78,7 @@ AC_DEFUN([AC_RELOCATABLE_LIBRARY], fi ], RELOCATABLE=no) AC_SUBST(RELOCATABLE) - dnl Easier to put this here once, instead of into the DEFS of each Makefile. - if test "X$prefix" = "XNONE"; then - reloc_final_prefix="$ac_default_prefix" - else - reloc_final_prefix="$prefix" - fi - AC_DEFINE_UNQUOTED([INSTALLPREFIX], ["${reloc_final_prefix}"], - [Define to the value of ${prefix}, as a string.]) + AC_MSG_RESULT([$RELOCATABLE]) ]) dnl Determine the platform dependent parameters needed to use relocatability: