[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Check for module alloca in func_emit_tests_Makefile_am
From: |
Bruno Haible |
Subject: |
Re: Check for module alloca in func_emit_tests_Makefile_am |
Date: |
Sun, 19 Aug 2012 14:13:30 +0200 |
User-agent: |
KMail/4.7.4 (Linux/3.1.10-1.9-desktop; KDE/4.7.4; x86_64; ; ) |
Hi Dmitriy,
> It seems I've found another small bug inside gnulib-tool.
>
> In func_emit_tests_Makefile_am at lines 3618-3620 we add two lines
> to emit if module is 'alloca' and we use perhapsLT variable. The problem
> is that it is always empty.
>
> BTW, there are no other places in func_emit_tests_Makefile_am where we
> need perhapsLT. I guess that it must be 'LT' if we use libtool and ''
> if not, like in func_emit_lib_Makefile_am, but I'm not sure.
The variable perhapsLT gets set in func_emit_lib_Makefile_am, which
*happens* to be invoked before func_emit_tests_Makefile_am. So it's
not a bug, only very sloppy and fragile coding style. Corrected as
follows:
2012-08-19 Bruno Haible <address@hidden>
gnulib-tool: Improve coding style.
* gnulib-tool (func_emit_tests_Makefile_am): Set perhapsLT, like in
func_emit_lib_Makefile_am.
Reported and fix suggested by Dmitriy Selyutin <address@hidden>.
--- gnulib-tool.orig Sun Aug 19 14:11:39 2012
+++ gnulib-tool Sun Aug 19 14:10:22 2012
@@ -3576,9 +3576,11 @@
witness_macro="$1"
if test "$libtool" = true; then
libext=la
+ perhapsLT=LT
sed_eliminate_LDFLAGS="$sed_noop"
else
libext=a
+ perhapsLT=
sed_eliminate_LDFLAGS='/^lib_LDFLAGS[ ]*+=/d'
fi
if $for_test; then