bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AM_GNU_GETTEXT(use-libtool) and Automake's "make distcheck"


From: Simon Josefsson
Subject: Re: AM_GNU_GETTEXT(use-libtool) and Automake's "make distcheck"
Date: Wed, 15 Jan 2003 18:36:48 +0100
User-agent: Gnus/5.090013 (Oort Gnus v0.13) Emacs/21.3.50 (i686-pc-linux-gnu)

Bruno Haible <address@hidden> writes:

> On Thursday 05 December 2002 05:10, Simon Josefsson wrote:
>> I'm having trouble getting this combination to work on Debian
>> woody(*), which has libintl natively.  Automake creates a target "make
>> distcheck" that contains:
>> 
>>        && ../configure --srcdir=.. --prefix="$$dc_install_base" \
>>          --with-included-gettext \
>>          $(DISTCHECK_CONFIGURE_FLAGS) \
>> 
>> and I think it is the --with-included-gettext that is causing trouble.
>
> This is fixed in automake-1.7.2. Thanks to Alexandre Duret-Lutz!

Still no luck though.  Unless I have

DISTCHECK_CONFIGURE_FLAGS = --without-included-gettext

in Makefile.am, then "make distcheck" fails with the error below [1],
which I think is the same as originally reported.

address@hidden:~/src/gsasl$ autoconf --version
autoconf (GNU Autoconf) 2.57
Written by David J. MacKenzie and Akim Demaille.

Copyright 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
address@hidden:~/src/gsasl$ automake --version
automake (GNU automake) 1.7.2
Written by Tom Tromey <address@hidden>.

Copyright 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
address@hidden:~/src/gsasl$ aclocal --version
aclocal (GNU automake) 1.7.2

Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Written by Tom Tromey <address@hidden>
address@hidden:~/src/gsasl$ autoreconf --version
autoreconf (GNU Autoconf) 2.57
Written by David J. MacKenzie and Akim Demaille.

Copyright 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
address@hidden:~/src/gsasl$ gettextize --version
/usr/bin/gettextize (GNU gettext) 0.11.5
Copyright (C) 1995-1998, 2000-2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Ulrich Drepper
address@hidden:~/src/gsasl$

>> As can be seen below, the intl/ directory is not installing libintl in
>> $prefix/lib directory. ... I think this is a
>> gettext/libintl bug: intl/Makefile should force an installation of
>> libintl.{,l}a when --with-included-gettext is specified.
>
> This is normal. Only the gettext package installs libintl. Some other
> packages compile their intl directory with "#define malloc rpl_malloc"
> or similar, and the resulting libintl.a is therefore useful only for
> this single package.
>
>> Then later on, relinking the application for
>> "make install" fails because -lintl is not found.
>
> If you get a link error for -lintl when --with-included-gettext is
> used, you should add -Lintl (or -L../intl or -L../../intl - depending
> where is your Makefile) to the LIBS or LDFLAGS variable.

I have @LTLIBINTL@ in place.  The problem seems to be that libtool
wants to relink the library and since --with-included-gettext was
specified, -lintl is added unconditionally, which it doesn't work
since the intl/ directory doesn't install that library.

Do I need newer gettext too?

Adding -L../intl does not help, see [2], but I'm not convinced linking
with $top_builddir/intl/libintl.la is such a good idea, as it would
make the library link with a library in the build directory.

To reproduce this, I think the keys are AM_GNU_GETTEXT(use-libtool)
and building a shared libtool library that uses gettext() and then
trying make distcheck.

[1]:
Making install in lib
make[2]: Entering directory `/home/jas/src/gsasl/libgsasl-0.0.5/=build/lib'
make[3]: Entering directory `/home/jas/src/gsasl/libgsasl-0.0.5/=build/lib'
/bin/sh ../../mkinstalldirs /home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib
mkdir -p -- /home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib
 /bin/sh ../libtool --mode=install /usr/bin/install -c  libgsasl.la 
/home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib/libgsasl.la
libtool: install: warning: relinking `libgsasl.la'
(cd /home/jas/src/gsasl/libgsasl-0.0.5/=build/lib; /bin/sh ../libtool 
--mode=relink gcc -g -O2 -o libgsasl.la -rpath 
/home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib -version-info 2:1:1 init.lo 
done.lo error.lo version.lo callback.lo supportp.lo suggest.lo listmech.lo 
hexdump.lo base64.lo md5pwd.lo xstart.lo xstep.lo xfinish.lo xcode.lo common.lo 
external.lo anonymous.lo plain.lo login.lo cram-md5.lo
digest-md5.lo ntlm.lo gssapi.lo securid.lo ../intl/libintl.la -L/usr/local/lib 
-lgcrypt -L/usr/local/lib -lntlm -L/usr/lib -lgssapi_krb5 -lkrb5 -lk5crypto 
-lcom_err -R/usr/local/lib -L/usr/local/lib -lidn -lm )
gcc -shared  init.lo done.lo error.lo version.lo callback.lo supportp.lo 
suggest.lo listmech.lo hexdump.lo base64.lo md5pwd.lo xstart.lo xstep.lo 
xfinish.lo xcode.lo common.lo external.lo anonymous.lo plain.lo login.lo 
cram-md5.lo digest-md5.lo ntlm.lo gssapi.lo securid.lo  -Wl,--rpath 
-Wl,/home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib -Wl,--rpath -Wl,/usr/local/lib 
 -L/home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib -lintl -L/usr/local/lib 
-lgcrypt -lntlm -L/usr/lib -lgssapi_krb5
-lkrb5 -lk5crypto -lcom_err -lidn -lm   -Wl,-soname -Wl,libgsasl.so.1 -o 
.libs/libgsasl.so.1.1.1
/usr/bin/ld: cannot find -lintl
collect2: ld returned 1 exit status
libtool: install: error: relink `libgsasl.la' with the above command before 
installing it
make[3]: *** [install-libLTLIBRARIES] Error 1
make[3]: Leaving directory `/home/jas/src/gsasl/libgsasl-0.0.5/=build/lib'
make[2]: *** [install-am] Error 2
make[2]: Leaving directory `/home/jas/src/gsasl/libgsasl-0.0.5/=build/lib'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/jas/src/gsasl/libgsasl-0.0.5/=build'
make: *** [distcheck] Error 2
address@hidden:~/src/gsasl$

[2]:
address@hidden:~/src/gsasl/libgsasl-0.0.5/=build/lib$ make install
make[1]: Entering directory `/home/jas/src/gsasl/libgsasl-0.0.5/=build/lib'
/bin/sh ../../mkinstalldirs /home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib
 /bin/sh ../libtool --mode=install /usr/bin/install -c  libgsasl.la 
/home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib/libgsasl.la
libtool: install: warning: relinking `libgsasl.la'
(cd /home/jas/src/gsasl/libgsasl-0.0.5/=build/lib; /bin/sh ../libtool 
--mode=relink gcc -g -O2 -o libgsasl.la -rpath 
/home/jas/src/gsasl/libgsasl-0.0.5/=inst/lib -version-info 2:1:1 init.lo 
done.lo error.lo version.lo callback.lo supportp.lo suggest.lo listmech.lo 
hexdump.lo base64.lo md5pwd.lo xstart.lo xstep.lo xfinish.lo xcode.lo common.lo 
external.lo anonymous.lo plain.lo login.lo cram-md5.lo
digest-md5.lo ntlm.lo gssapi.lo securid.lo -L../intl ../intl/libintl.la 
-L/usr/local/lib -lgcrypt -L/usr/local/lib -lntlm -L/usr/lib -lgssapi_krb5 
-lkrb5 -lk5crypto -lcom_err -R/usr/local/lib -L/usr/local/lib -lidn -lm )
mv: cannot stat `libgsasl.so.1.1.1': No such file or directory
libtool: install: error: relink `libgsasl.la' with the above command before 
installing it
make[1]: *** [install-libLTLIBRARIES] Error 1
make[1]: Leaving directory `/home/jas/src/gsasl/libgsasl-0.0.5/=build/lib'
make: *** [install-am] Error 2
address@hidden:~/src/gsasl/libgsasl-0.0.5/=build/lib$





reply via email to

[Prev in Thread] Current Thread [Next in Thread]