GNU bug report logs -
#56798
Inconsistent locale settings between LT and non-LT $CC invocation
Previous Next
To reply to this bug, email your comments to 56798 AT debbugs.gnu.org.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-libtool <at> gnu.org
:
bug#56798
; Package
libtool
.
(Wed, 27 Jul 2022 16:08:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Jan Engelhardt <jengelh <at> inai.de>
:
New bug report received and forwarded. Copy sent to
bug-libtool <at> gnu.org
.
(Wed, 27 Jul 2022 16:08:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Greetings.
This is a bug report primarily against libtool 2.4.7. automake is Cc'ed.
libtool seems to reset locales, causing compiler output to differ
between libtool-based invocations and those without libtool. This
becomes in particular visible when an automake project invokes both
compile strategies.
Observed
========
$ make V=0
CXX foo.o
foo.cpp: In function ‘int main()’:
foo.cpp:1:36: warning: declaration of ‘foo’ shadows a previous local [-Wshadow]
1 | int main() { auto foo = 42; { auto foo = 43; }}
CXXLD foo
CXX bar.lo
bar.cpp: In function 'int main()':
bar.cpp:1:36: warning: declaration of 'foo' shadows a previous local [-Wshadow]
1 | int main() { auto foo = 42; { auto foo = 43; }}
Expected to see
===============
Do not mix '' and ‘’. Stick to one variant.
Either libtool should stop resetting the locale, or perhaps
automake should start resetting the locale.
Testcase
========
foo.cpp
-------
int main() { auto foo = 42; { auto foo = 43; }}
Makefile.am
-----------
BUILT_SOURCES = bar.cpp
bar.cpp: foo.cpp
cp foo.cpp bar.cpp
AM_CXXFLAGS = -Wshadow
bin_PROGRAMS = foo
foo_SOURCES = foo.cpp
lib_LTLIBRARIES = libbar.la
libbar_la_SOURCES = bar.cpp
configure.ac
------------
AC_INIT([blah], [0])
AM_INIT_AUTOMAKE([1.10 foreign subdir-objects])
LT_INIT([disable-static])
AC_PROG_CXX
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
This bug report was last modified 2 years and 101 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.