[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH] tools: don't expand prefix and exec_prefix too early
A comment in tools/configure says that it is intended for these to be command line overridable, so they shouldn't get expanded at configure time. The patch is fixing tools/m4/default_lib.m4 as far as I can see myself doing this, but imo it is flawed altogether and should rather be removed: - setting prefix and exec_prefix to default values is being done later in tools/configure anyway - setting LIB_PATH based on the (non-)existence of a lib64 directory underneath ${exec_prefix} is plain wrong (it can obviously exist on a 32-bit installation) - I wasn't able to locate any use of LIB_PATH (I did see IanC's comment in c/s 25594:ad08cd8e7097 that removing it supposedly causes other problems, but I don't see how that would happen). Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> --- This will require tools/configure to be re-generated. --- a/config/Tools.mk.in +++ b/config/Tools.mk.in @@ -1,5 +1,6 @@ # Prefix and install folder -PREFIX := @prefix@ +prefix := @prefix@ +PREFIX := $(prefix) exec_prefix := @exec_prefix@ LIBDIR := @libdir@ --- a/tools/m4/default_lib.m4 +++ b/tools/m4/default_lib.m4 @@ -1,14 +1,19 @@ AC_DEFUN([AX_DEFAULT_LIB], -[AS_IF([test "\${exec_prefix}/lib" = "$libdir"], - [AS_IF([test "$exec_prefix" = "NONE" && test "$prefix" != "NONE"], - [exec_prefix=$prefix]) - AS_IF([test "$exec_prefix" = "NONE"], [exec_prefix=$ac_default_prefix]) - AS_IF([test -d "${exec_prefix}/lib64"], [ +[AS_IF([test "\${exec_prefix}/lib" = "$libdir"], [ + AS_IF([test "$prefix" = "NONE"], [prefix=$ac_default_prefix]) + AS_IF([test "$exec_prefix" = "NONE"], [exec_prefix='${prefix}']) + AS_IF([eval test -d "${exec_prefix}/lib64"], [ LIB_PATH="lib64" ],[ LIB_PATH="lib" ]) ], [ LIB_PATH="${libdir:`expr length "$exec_prefix" + 1`}" + AS_IF([test -z "${libdir##\$\{exec_prefix\}/*}"], [ + LIB_PATH="${libdir:15}" + ]) + AS_IF([test -z "${libdir##\$exec_prefix/*}"], [ + LIB_PATH="${libdir:13}" + ]) ]) AC_SUBST(LIB_PATH)]) Attachment:
tools-cfg-libdir-x86_64.patch _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |