From: Bruno Haible Date: Mon, 8 Aug 2005 11:05:03 +0000 (+0000) Subject: Make VPATH builds with $srcdir = $builddir work. X-Git-Tag: v0.15~434 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a7a60f4aaa2bfb19d641868724f6214127365fe0;p=thirdparty%2Fgettext.git Make VPATH builds with $srcdir = $builddir work. --- diff --git a/gettext-runtime/intl/ChangeLog b/gettext-runtime/intl/ChangeLog index f978ba1dc..921ff281a 100644 --- a/gettext-runtime/intl/ChangeLog +++ b/gettext-runtime/intl/ChangeLog @@ -1,3 +1,7 @@ +2005-08-03 Bruno Haible + + * Makefile.in: Add comments about VPATH. + 2005-07-31 Bruno Haible * lock.h (gl_lock_initializer): New macro. diff --git a/gettext-runtime/intl/Makefile.in b/gettext-runtime/intl/Makefile.in index 54d055abd..20ebd611d 100644 --- a/gettext-runtime/intl/Makefile.in +++ b/gettext-runtime/intl/Makefile.in @@ -24,6 +24,17 @@ SHELL = /bin/sh srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = .. + +# The VPATH variables allows builds with $builddir != $srcdir, assuming a +# 'make' program that supports VPATH (such as GNU make). This line is removed +# by autoconf automatically when "$(srcdir)" = ".". +# In this directory, the VPATH handling is particular: +# 1. If INTL_LIBTOOL_SUFFIX_PREFIX is 'l' (indicating a build with libtool), +# the .c -> .lo rules carefully use $(srcdir), so that VPATH can be omitted. +# 2. If PACKAGE = gettext-tools, VPATH _must_ be omitted, because otherwise +# 'make' does the wrong thing if GNU gettext was configured with +# "./configure --srcdir=`pwd`", namely it gets confused by the .lo and .la +# files it finds in srcdir = ../../gettext-runtime/intl. VPATH = $(srcdir) prefix = @prefix@ diff --git a/gettext-tools/ChangeLog b/gettext-tools/ChangeLog index 605292b88..864c5fffc 100644 --- a/gettext-tools/ChangeLog +++ b/gettext-tools/ChangeLog @@ -1,3 +1,8 @@ +2005-08-03 Bruno Haible + + * configure.ac (intl/Makefile): Remove the VPATH line. + Reported by Jason Keltz . + 2005-07-26 Bruno Haible * configure.ac: Move the AM_GNU_GETTEXT invocation early, since it diff --git a/gettext-tools/configure.ac b/gettext-tools/configure.ac index 4faaee36d..17f64f282 100644 --- a/gettext-tools/configure.ac +++ b/gettext-tools/configure.ac @@ -298,6 +298,7 @@ AC_CONFIG_FILES([doc/Makefile], AC_CONFIG_FILES([intl/Makefile:../gettext-runtime/intl/Makefile.in], [ # Change srcdir variable so that it points to ../gettext-runtime/intl. sed -e 's|^srcdir =.*$|srcdir = $(top_srcdir)/../gettext-runtime/intl|' \ + -e 's|^VPATH =.*$||' \ < intl/Makefile > intl/Makefile.tmp mv intl/Makefile.tmp intl/Makefile ])