* Ralf Wildenhues wrote on Wed, May 28, 2008 at 09:52:30PM CEST: > > Ahem, wasn't that necessary for argz_add and argz_count already, > which were added to Libtool in 2008-02-26?
OK like this? The test would have exposed the issue on, say, Solaris. The test will skip on systems where argz.o is not needed, or when Autoconf 2.59 was used for bootstrapping (in that case argz.o won't live below libltdl/); I don't particularly care to make the test precise, it only needs to fail somewhere. Thanks, Ralf 2008-05-28 Ralf Wildenhues <[EMAIL PROTECTED]> Ensure that all symbols from argz.c are properly renamed. * libltdl/libltdl/lt__glibc.h (argz_add, argz_count): #define them to lt__argz* namespace. * tests/ltdl-api.at (ltdl API): New file with new test. * Makefile.am: Adjust. * NEWS: Update. Bug report by David Lutterkort <[EMAIL PROTECTED]>. diff --git a/Makefile.am b/Makefile.am index 0085c7f..1417e84 100644 --- a/Makefile.am +++ b/Makefile.am @@ -454,6 +454,7 @@ TESTSUITE_AT = tests/testsuite.at \ tests/am-subdir.at \ tests/lt_dlexit.at \ tests/lt_dladvise.at \ + tests/ltdl-api.at \ tests/need_lib_prefix.at \ tests/standalone.at \ tests/subproject.at \ diff --git a/NEWS b/NEWS index 2b113fb..45d214a 100644 --- a/NEWS +++ b/NEWS @@ -4,7 +4,8 @@ New in 2.2.??: 2008-06-??: git version 2.2.5a, Libtool team: * Bug fixes: - - None yet + - Fix 2.2 regression that caused argz symbols to be exported from + libltdl unrenamed on systems that do not have working argz. New in 2.2.4: 2008-05-04: git version 2.2.3a, Libtool team: diff --git a/libltdl/libltdl/lt__glibc.h b/libltdl/libltdl/lt__glibc.h index f284773..010da3d 100644 --- a/libltdl/libltdl/lt__glibc.h +++ b/libltdl/libltdl/lt__glibc.h @@ -1,6 +1,6 @@ /* lt__glibc.h -- support for non glibc environments - Copyright (C) 2004, 2006, 2007 Free Software Foundation, Inc. + Copyright (C) 2004, 2006, 2007, 2008 Free Software Foundation, Inc. Written by Gary V. Vaughan, 2004 NOTE: The canonical source of this file is maintained with the @@ -44,6 +44,10 @@ or obtained by writing to the Free Software Foundation, Inc., from there in addition to libltdl. */ # undef argz_append # define argz_append lt__argz_append +# undef argz_add +# define argz_add lt__argz_add +# undef argz_count +# define argz_count lt__argz_count # undef argz_create_sep # define argz_create_sep lt__argz_create_sep # undef argz_insert diff --git a/tests/ltdl-api.at b/tests/ltdl-api.at new file mode 100644 index 0000000..b811ae3 --- /dev/null +++ b/tests/ltdl-api.at @@ -0,0 +1,36 @@ +# ltdl-api.at -- test libltdl API -*- Autotest -*- +# +# Copyright (C) 2008 Free Software Foundation, Inc. +# Written by Ralf Wildenhues, 2008. +# +# This file is part of GNU Libtool. +# +# GNU Libtool is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. +# +# GNU Libtool is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, +# or obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +#### + +AT_SETUP([ltdl API]) +AT_KEYWORDS([libltdl]) + +# Ensure that no symbols from argz are unrenamed. +eval `$LIBTOOL --config | $EGREP '^(NM|global_symbol_pipe|objext)='` +argz_o=$abs_top_builddir/libltdl/argz.$objext +AT_CHECK([test -f "$argz_o" || exit 77]) +AT_CHECK([eval "$NM \"\$argz_o\" | $global_symbol_pipe"], + [], [stdout], [ignore]) +AT_CHECK([grep "^T argz_" stdout], [1]) + +AT_CLEANUP