1 --- a/backends/ChangeLog
2 +++ b/backends/ChangeLog
4 * ppc_attrs.c (ppc_check_object_attribute): Handle tag
5 GNU_Power_ABI_Struct_Return.
7 +2009-01-23 Roland McGrath <roland@redhat.com>
9 + * Makefile.am (libebl_%.so): Use $(LD_AS_NEEDED).
11 2008-10-04 Ulrich Drepper <drepper@redhat.com>
13 * i386_reloc.def: Fix entries for TLS_GOTDESC, TLS_DESC_CALL, and
15 * sparc_init.c: Likewise.
16 * x86_64_init.c: Likewise.
18 +2005-11-22 Roland McGrath <roland@redhat.com>
20 + * Makefile.am (LD_AS_NEEDED): New variable, substituted by configure.
21 + (libebl_%.so rule): Use it in place of -Wl,--as-needed.
23 2005-11-19 Roland McGrath <roland@redhat.com>
25 * ppc64_reloc.def: REL30 -> ADDR30.
27 * Makefile.am (uninstall): Don't try to remove $(pkgincludedir).
28 (CLEANFILES): Add libebl_$(m).so.
30 + * Makefile.am (WEXTRA): New variable, substituted by configure.
31 + (AM_CFLAGS): Use it in place of -Wextra.
33 * ppc_reloc.def: Update bits per Alan Modra <amodra@bigpond.net.au>.
34 * ppc64_reloc.def: Likewise.
36 --- a/backends/Makefile.am
37 +++ b/backends/Makefile.am
38 @@ -103,7 +103,7 @@ libebl_%.so libebl_%.map: libebl_%_pic.a
39 $(LINK) -shared -o $(@:.map=.so) \
40 -Wl,--whole-archive $< $(cpu_$*) -Wl,--no-whole-archive \
41 -Wl,--version-script,$(@:.so=.map) \
42 - -Wl,-z,defs -Wl,--as-needed $(libelf) $(libdw) $(libmudflap)
43 + -Wl,-z,defs $(LD_AS_NEEDED) $(libelf) $(libdw) $(libmudflap)
46 libebl_i386.so: $(cpu_i386)
47 --- a/backends/Makefile.in
48 +++ b/backends/Makefile.in
49 @@ -165,6 +165,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
50 INSTALL_SCRIPT = @INSTALL_SCRIPT@
51 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
53 +LD_AS_NEEDED = @LD_AS_NEEDED@
56 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
57 @@ -194,6 +195,7 @@ SHELL = @SHELL@
63 XGETTEXT_015 = @XGETTEXT_015@
64 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
65 @@ -257,7 +259,7 @@ INCLUDES = -I. -I$(srcdir) -I$(top_srcdi
66 -I$(top_srcdir)/libelf -I$(top_srcdir)/libdw
67 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
68 $($(*F)_no_Werror),,-Werror) $(if \
69 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
70 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
71 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
73 @MUDFLAP_FALSE@libmudflap =
74 @@ -698,7 +700,7 @@ libebl_%.so libebl_%.map: libebl_%_pic.a
75 $(LINK) -shared -o $(@:.map=.so) \
76 -Wl,--whole-archive $< $(cpu_$*) -Wl,--no-whole-archive \
77 -Wl,--version-script,$(@:.so=.map) \
78 - -Wl,-z,defs -Wl,--as-needed $(libelf) $(libdw) $(libmudflap)
79 + -Wl,-z,defs $(LD_AS_NEEDED) $(libelf) $(libdw) $(libmudflap)
82 libebl_i386.so: $(cpu_i386)
87 * configure.ac (LOCALEDIR, DATADIRNAME): Removed.
89 +2009-11-22 Roland McGrath <roland@redhat.com>
91 + * configure.ac: Use sed and expr instead of modern bash extensions.
93 2009-09-21 Ulrich Drepper <drepper@redhat.com>
95 * configure.ac: Update for more modern autoconf.
98 * configure.ac (zip_LIBS): Check for liblzma too.
100 +2009-08-17 Roland McGrath <roland@redhat.com>
102 + * configure.ac: Check for -fgnu89-inline; add it to WEXTRA if it works.
104 2009-04-19 Roland McGrath <roland@redhat.com>
106 * configure.ac (eu_version): Round down here, not in version.h macros.
109 2009-01-23 Roland McGrath <roland@redhat.com>
111 + * configure.ac: Check for __builtin_popcount.
113 * configure.ac (zlib check): Check for gzdirect, need zlib >= 1.2.2.3.
115 * configure.ac (__thread check): Use AC_LINK_IFELSE, in case of
117 * configure.ac: Add dummy automake conditional to get dependencies
118 for non-generic linker right. See src/Makefile.am.
120 +2005-11-22 Roland McGrath <roland@redhat.com>
122 + * configure.ac: Check for --as-needed linker option.
124 2005-11-18 Roland McGrath <roland@redhat.com>
126 * Makefile.am (DISTCHECK_CONFIGURE_FLAGS): New variable.
128 * Makefile.am (all_SUBDIRS): Add libdwfl.
129 * configure.ac: Write libdwfl/Makefile.
131 +2005-05-31 Roland McGrath <roland@redhat.com>
133 + * configure.ac (WEXTRA): Check for -Wextra and set this substitution.
135 + * configure.ac: Check for struct stat st_?tim members.
136 + * src/strip.c (process_file): Use st_?time if st_?tim are not there.
138 + * configure.ac: Check for futimes function.
139 + * src/strip.c (handle_elf) [! HAVE_FUTIMES]: Use utimes instead.
140 + (handle_ar) [! HAVE_FUTIMES]: Likewise.
142 2005-05-19 Roland McGrath <roland@redhat.com>
144 * configure.ac [AH_BOTTOM] (INTDECL, _INTDECL): New macros.
148 ## <http://www.openinventionnetwork.com>.
152 +LD_AS_NEEDED = @LD_AS_NEEDED@
154 DEFS = -D_GNU_SOURCE -DHAVE_CONFIG_H -DLOCALEDIR='"${localedir}"'
155 INCLUDES = -I. -I$(srcdir) -I$(top_srcdir)/lib -I..
156 AM_CFLAGS = -std=gnu99 -Wall -Wshadow \
157 $(if $($(*F)_no_Werror),,-Werror) \
158 - $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \
159 + $(if $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) \
160 $(if $($(*F)_no_Wformat),-Wno-format,-Wformat=2) \
163 --- a/config/Makefile.in
164 +++ b/config/Makefile.in
165 @@ -76,6 +76,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
166 INSTALL_SCRIPT = @INSTALL_SCRIPT@
167 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
169 +LD_AS_NEEDED = @LD_AS_NEEDED@
172 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
173 @@ -105,6 +106,7 @@ SHELL = @SHELL@
178 XGETTEXT = @XGETTEXT@
179 XGETTEXT_015 = @XGETTEXT_015@
180 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
184 /* config.h.in. Generated from configure.ac by autoheader. */
186 +/* Have __builtin_popcount. */
187 +#undef HAVE_BUILTIN_POPCOUNT
189 /* $libdir subdirectory containing libebl modules. */
193 /* Define for large files, on AIX-style hosts. */
196 +/* Stubbed out if missing compiler support. */
199 #include <eu-config.h>
202 @@ -602,6 +602,8 @@ NEVER_TRUE
211 @@ -3856,6 +3858,130 @@ if test "x$ac_cv_c99" != xyes; then :
212 as_fn_error $? "gcc with C99 support required" "$LINENO" 5
215 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wextra option to $CC" >&5
216 +$as_echo_n "checking for -Wextra option to $CC... " >&6; }
217 +if test "${ac_cv_cc_wextra+set}" = set; then :
218 + $as_echo_n "(cached) " >&6
220 + old_CFLAGS="$CFLAGS"
221 +CFLAGS="$CFLAGS -Wextra"
222 +cat confdefs.h - <<_ACEOF >conftest.$ac_ext
223 +/* end confdefs.h. */
226 +if ac_fn_c_try_compile "$LINENO"; then :
227 + ac_cv_cc_wextra=yes
231 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
232 +CFLAGS="$old_CFLAGS"
234 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_wextra" >&5
235 +$as_echo "$ac_cv_cc_wextra" >&6; }
237 +if test "x$ac_cv_cc_wextra" = xyes; then :
243 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fgnu89-inline option to $CC" >&5
244 +$as_echo_n "checking for -fgnu89-inline option to $CC... " >&6; }
245 +if test "${ac_cv_cc_gnu89_inline+set}" = set; then :
246 + $as_echo_n "(cached) " >&6
248 + old_CFLAGS="$CFLAGS"
249 +CFLAGS="$CFLAGS -fgnu89-inline -Werror"
250 +cat confdefs.h - <<_ACEOF >conftest.$ac_ext
251 +/* end confdefs.h. */
255 + inline void bar (void) {}
258 +extern inline void baz (void) {}
261 +if ac_fn_c_try_compile "$LINENO"; then :
262 + ac_cv_cc_gnu89_inline=yes
264 + ac_cv_cc_gnu89_inline=no
266 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
267 +CFLAGS="$old_CFLAGS"
269 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_gnu89_inline" >&5
270 +$as_echo "$ac_cv_cc_gnu89_inline" >&6; }
271 +if test "x$ac_cv_cc_gnu89_inline" = xyes; then :
272 + WEXTRA="${WEXTRA:+$WEXTRA }-fgnu89-inline"
275 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --as-needed linker option" >&5
276 +$as_echo_n "checking for --as-needed linker option... " >&6; }
277 +if test "${ac_cv_as_needed+set}" = set; then :
278 + $as_echo_n "(cached) " >&6
280 + cat > conftest.c <<EOF
281 +int main (void) { return 0; }
283 +if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
284 + -fPIC -shared -o conftest.so conftest.c
285 + -Wl,--as-needed 1>&5'
286 + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
287 + (eval $ac_try) 2>&5
289 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
290 + test $ac_status = 0; }; }
292 + ac_cv_as_needed=yes
298 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_as_needed" >&5
299 +$as_echo "$ac_cv_as_needed" >&6; }
300 +if test "x$ac_cv_as_needed" = xyes; then :
301 + LD_AS_NEEDED=-Wl,--as-needed
307 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_popcount" >&5
308 +$as_echo_n "checking for __builtin_popcount... " >&6; }
309 +if test "${ac_cv_popcount+set}" = set; then :
310 + $as_echo_n "(cached) " >&6
312 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext
313 +/* end confdefs.h. */
318 +exit (__builtin_popcount (127));
323 +if ac_fn_c_try_link "$LINENO"; then :
328 +rm -f core conftest.err conftest.$ac_objext \
329 + conftest$ac_exeext conftest.$ac_ext
331 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_popcount" >&5
332 +$as_echo "$ac_cv_popcount" >&6; }
333 +if test "x$ac_cv_popcount" = xyes; then :
335 +$as_echo "#define HAVE_BUILTIN_POPCOUNT 1" >>confdefs.h
339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __thread support" >&5
340 $as_echo_n "checking for __thread support... " >&6; }
341 if test "${ac_cv_tls+set}" = set; then :
342 @@ -3892,7 +4018,11 @@ fi
343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tls" >&5
344 $as_echo "$ac_cv_tls" >&6; }
345 if test "x$ac_cv_tls" != xyes; then :
346 - as_fn_error $? "__thread support required" "$LINENO" 5
347 + if test "$use_locks" = yes; then :
348 + as_fn_error "--enable-thread-safety requires __thread support" "$LINENO" 5
350 + as_echo "#define __thread /* empty: no multi-thread support */" >>confdefs.h
354 # Check whether --enable-largefile was given.
355 @@ -4878,7 +5008,7 @@ ac_config_files="$ac_config_files versio
357 # 1.234<whatever> -> 1234<whatever>
358 case "$PACKAGE_VERSION" in
359 -[0-9].*) eu_version="${PACKAGE_VERSION/./}" ;;
360 +[0-9].*) eu_version=`echo "$PACKAGE_VERSION" | sed 's@\.@@'` ;;
361 *) as_fn_error $? "confused by version number '$PACKAGE_VERSION'" "$LINENO" 5 ;;
363 case "$eu_version" in
364 @@ -4907,7 +5037,7 @@ case "$eu_version" in
367 # Round up to the next release API (x.y) version.
368 -eu_version=$[($eu_version + 999) / 1000]
369 +eu_version=`expr \( $eu_version + 999 \) / 1000`
371 cat >confcache <<\_ACEOF
372 # This file is a shell script that caches the results of configure
375 @@ -70,6 +70,54 @@ CFLAGS="$old_CFLAGS"])
376 AS_IF([test "x$ac_cv_c99" != xyes],
377 AC_MSG_ERROR([gcc with C99 support required]))
379 +AC_CACHE_CHECK([for -Wextra option to $CC], ac_cv_cc_wextra, [dnl
380 +old_CFLAGS="$CFLAGS"
381 +CFLAGS="$CFLAGS -Wextra"
382 +AC_COMPILE_IFELSE([void foo (void) { }],
383 + ac_cv_cc_wextra=yes, ac_cv_cc_wextra=no)
384 +CFLAGS="$old_CFLAGS"])
386 +AS_IF([test "x$ac_cv_cc_wextra" = xyes], [WEXTRA=-Wextra], [WEXTRA=-W])
388 +AC_CACHE_CHECK([for -fgnu89-inline option to $CC], ac_cv_cc_gnu89_inline, [dnl
389 +old_CFLAGS="$CFLAGS"
390 +CFLAGS="$CFLAGS -fgnu89-inline -Werror"
394 + inline void bar (void) {}
397 +extern inline void baz (void) {}
398 +], ac_cv_cc_gnu89_inline=yes, ac_cv_cc_gnu89_inline=no)
399 +CFLAGS="$old_CFLAGS"])
400 +AS_IF([test "x$ac_cv_cc_gnu89_inline" = xyes],
401 + [WEXTRA="${WEXTRA:+$WEXTRA }-fgnu89-inline"])
403 +AC_CACHE_CHECK([for --as-needed linker option],
404 + ac_cv_as_needed, [dnl
405 +cat > conftest.c <<EOF
406 +int main (void) { return 0; }
408 +if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
409 + -fPIC -shared -o conftest.so conftest.c
410 + -Wl,--as-needed 1>&AS_MESSAGE_LOG_FD])
412 + ac_cv_as_needed=yes
417 +AS_IF([test "x$ac_cv_as_needed" = xyes],
418 + [LD_AS_NEEDED=-Wl,--as-needed], [LD_AS_NEEDED=])
419 +AC_SUBST(LD_AS_NEEDED)
421 +AC_CACHE_CHECK([for __builtin_popcount], ac_cv_popcount, [dnl
422 +AC_LINK_IFELSE([AC_LANG_PROGRAM([], [[exit (__builtin_popcount (127));]])],
423 + ac_cv_popcount=yes, ac_cv_popcount=no)])
424 +AS_IF([test "x$ac_cv_popcount" = xyes],
425 + [AC_DEFINE([HAVE_BUILTIN_POPCOUNT], [1], [Have __builtin_popcount.])])
427 AC_CACHE_CHECK([for __thread support], ac_cv_tls, [dnl
428 # Use the same flags that we use for our DSOs, so the test is representative.
429 # Some old compiler/linker/libc combinations fail some ways and not others.
430 @@ -85,7 +133,10 @@ static __thread int a; int foo (int b) {
431 CFLAGS="$save_CFLAGS"
432 LDFLAGS="$save_LDFLAGS"])
433 AS_IF([test "x$ac_cv_tls" != xyes],
434 - AC_MSG_ERROR([__thread support required]))
435 + [AS_IF([test "$use_locks" = yes],
436 + [AC_MSG_ERROR([--enable-thread-safety requires __thread support])],
437 + [AC_DEFINE([__thread], [/* empty: no multi-thread support */],
438 + [Stubbed out if missing compiler support.])])])
440 dnl This test must come as early as possible after the compiler configuration
441 dnl tests, because the choice of the file model can (in principle) affect
442 @@ -248,7 +299,7 @@ AC_SUBST([eu_version])
444 # 1.234<whatever> -> 1234<whatever>
445 case "$PACKAGE_VERSION" in
446 -[[0-9]].*) eu_version="${PACKAGE_VERSION/./}" ;;
447 +[[0-9]].*) eu_version=`echo "$PACKAGE_VERSION" | sed 's@\.@@'` ;;
448 *) AC_MSG_ERROR([confused by version number '$PACKAGE_VERSION']) ;;
450 case "$eu_version" in
451 @@ -277,6 +328,6 @@ case "$eu_version" in
454 # Round up to the next release API (x.y) version.
455 -[eu_version=$[($eu_version + 999) / 1000]]
456 +eu_version=`expr \( $eu_version + 999 \) / 1000`
463 2009-01-23 Roland McGrath <roland@redhat.com>
465 + * eu-config.h [! HAVE_BUILTIN_POPCOUNT]
466 + (__builtin_popcount): New inline function.
468 * eu-config.h: Add multiple inclusion protection.
470 2009-01-17 Ulrich Drepper <drepper@redhat.com>
472 * Makefile.am (libeu_a_SOURCES): Add it.
473 * system.h: Declare crc32_file.
475 +2005-02-07 Roland McGrath <roland@redhat.com>
477 + * Makefile.am (WEXTRA): New variable, substituted by configure.
478 + (AM_CFLAGS): Use it in place of -Wextra.
480 2005-04-30 Ulrich Drepper <drepper@redhat.com>
482 * Makefile.am: Use -ffunction-sections for xmalloc.c.
483 --- a/lib/eu-config.h
484 +++ b/lib/eu-config.h
485 @@ -182,6 +182,17 @@ asm (".section predict_data, \"aw\"; .pr
486 /* This macro is used by the tests conditionalize for standalone building. */
487 #define ELFUTILS_HEADER(name) <lib##name.h>
489 +#ifndef HAVE_BUILTIN_POPCOUNT
490 +# define __builtin_popcount hakmem_popcount
491 +static inline unsigned int __attribute__ ((unused))
492 +hakmem_popcount (unsigned int x)
495 + unsigned int n = x - ((x >> 1) & 033333333333) - ((x >> 2) & 011111111111);
496 + return ((n + (n >> 3)) & 030707070707) % 63;
498 +#endif /* HAVE_BUILTIN_POPCOUNT */
502 # define OLD_VERSION(name, version) \
503 --- a/lib/Makefile.in
504 +++ b/lib/Makefile.in
505 @@ -99,6 +99,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
506 INSTALL_SCRIPT = @INSTALL_SCRIPT@
507 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
509 +LD_AS_NEEDED = @LD_AS_NEEDED@
512 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
513 @@ -128,6 +129,7 @@ SHELL = @SHELL@
518 XGETTEXT = @XGETTEXT@
519 XGETTEXT_015 = @XGETTEXT_015@
520 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
521 @@ -190,7 +192,7 @@ INCLUDES = -I. -I$(srcdir) -I$(top_srcdi
522 -I$(srcdir)/../libelf
523 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
524 $($(*F)_no_Werror),,-Werror) $(if \
525 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
526 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
527 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
528 $(am__append_1) -fpic
529 @MUDFLAP_FALSE@libmudflap =
530 --- a/libasm/ChangeLog
531 +++ b/libasm/ChangeLog
533 * asm_error.c: Add new error ASM_E_IOERROR.
534 * libasmP.h: Add ASM_E_IOERROR definition.
536 +2005-05-31 Roland McGrath <roland@redhat.com>
538 + * Makefile.am (WEXTRA): New variable, substituted by configure.
539 + (AM_CFLAGS): Use it in place of -Wextra.
541 2005-02-15 Ulrich Drepper <drepper@redhat.com>
543 * Makefile.am (AM_CFLAGS): Add -Wunused -Wextra -Wformat=2.
544 --- a/libasm/Makefile.in
545 +++ b/libasm/Makefile.in
546 @@ -147,6 +147,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
547 INSTALL_SCRIPT = @INSTALL_SCRIPT@
548 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
550 +LD_AS_NEEDED = @LD_AS_NEEDED@
553 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
554 @@ -176,6 +177,7 @@ SHELL = @SHELL@
559 XGETTEXT = @XGETTEXT@
560 XGETTEXT_015 = @XGETTEXT_015@
561 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
562 @@ -239,7 +241,7 @@ INCLUDES = -I. -I$(srcdir) -I$(top_srcdi
563 -I$(top_srcdir)/libdw
564 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
565 $($(*F)_no_Werror),,-Werror) $(if \
566 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
567 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
568 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
570 @MUDFLAP_FALSE@libmudflap =
571 --- a/libcpu/ChangeLog
572 +++ b/libcpu/ChangeLog
575 2009-01-23 Roland McGrath <roland@redhat.com>
577 + * i386_disasm.c (i386_disasm): Add abort after assert-constant for old
578 + compilers that don't realize it's noreturn.
580 * Makefile.am (i386_parse_CFLAGS): Use quotes around command
581 substitution that can produce leading whitespace.
584 * defs/i386.doc: New file.
585 * defs/x86_64: New file.
587 +2005-04-04 Roland McGrath <roland@redhat.com>
589 + * Makefile.am (WEXTRA): New variable, substituted by configure.
590 + (AM_CFLAGS): Use it instead of -Wextra.
592 2005-02-15 Ulrich Drepper <drepper@redhat.com>
594 * Makefile (AM_CFLAGS): Add -Wunused -Wextra -Wformat=2.
595 --- a/libcpu/i386_disasm.c
596 +++ b/libcpu/i386_disasm.c
597 @@ -791,6 +791,7 @@ i386_disasm (const uint8_t **startp, con
600 assert (! "INVALID not handled");
605 --- a/libcpu/Makefile.in
606 +++ b/libcpu/Makefile.in
607 @@ -116,6 +116,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
608 INSTALL_SCRIPT = @INSTALL_SCRIPT@
609 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
611 +LD_AS_NEEDED = @LD_AS_NEEDED@
614 LEX_OUTPUT_ROOT = lex.$(<F:lex.l=)
615 @@ -145,6 +146,7 @@ SHELL = @SHELL@
620 XGETTEXT = @XGETTEXT@
621 XGETTEXT_015 = @XGETTEXT_015@
622 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
623 @@ -208,7 +210,7 @@ INCLUDES = -I. -I$(srcdir) -I$(top_srcdi
624 -I$(srcdir)/../libdw -I$(srcdir)/../libasm
625 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
626 $($(*F)_no_Werror),,-Werror) $(if \
627 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
628 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
629 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
630 $(am__append_1) -fpic -fdollars-in-identifiers
631 @MUDFLAP_FALSE@libmudflap =
632 --- a/libdw/ChangeLog
633 +++ b/libdw/ChangeLog
636 * dwarf_hasattr_integrate.c: Integrate DW_AT_specification too.
638 +2009-08-17 Roland McGrath <roland@redhat.com>
640 + * libdw.h: Disable extern inlines for GCC 4.2.
642 2009-08-10 Roland McGrath <roland@redhat.com>
644 * dwarf_getscopevar.c: Use dwarf_diename.
645 @@ -1076,6 +1080,11 @@
647 2005-05-31 Roland McGrath <roland@redhat.com>
649 + * Makefile.am (WEXTRA): New variable, substituted by configure.
650 + (AM_CFLAGS): Use it in place of -Wextra.
652 +2005-05-31 Roland McGrath <roland@redhat.com>
654 * dwarf_formref_die.c (dwarf_formref_die): Add CU header offset to
659 @@ -852,7 +852,7 @@ extern Dwarf_OOM dwarf_new_oom_handler (
662 /* Inline optimizations. */
664 +#if defined __OPTIMIZE__ && !(__GNUC__ == 4 && __GNUC_MINOR__ == 2)
665 /* Return attribute code of given attribute. */
666 __libdw_extern_inline unsigned int
667 dwarf_whatattr (Dwarf_Attribute *attr)
668 --- a/libdw/Makefile.in
669 +++ b/libdw/Makefile.in
670 @@ -192,6 +192,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
671 INSTALL_SCRIPT = @INSTALL_SCRIPT@
672 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
674 +LD_AS_NEEDED = @LD_AS_NEEDED@
677 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
678 @@ -221,6 +222,7 @@ SHELL = @SHELL@
683 XGETTEXT = @XGETTEXT@
684 XGETTEXT_015 = @XGETTEXT_015@
685 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
686 @@ -283,7 +285,7 @@ INCLUDES = -I. -I$(srcdir) -I$(top_srcdi
687 -I$(srcdir)/../libelf
688 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
689 $($(*F)_no_Werror),,-Werror) $(if \
690 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
691 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
692 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
693 $(am__append_1) $(am__append_2)
694 @MUDFLAP_FALSE@libmudflap =
695 --- a/libdwfl/ChangeLog
696 +++ b/libdwfl/ChangeLog
697 @@ -1366,6 +1366,11 @@
699 2005-07-21 Roland McGrath <roland@redhat.com>
701 + * Makefile.am (WEXTRA): New variable, substituted by configure.
702 + (AM_CFLAGS): Use it in place of -Wextra.
704 +2005-07-21 Roland McGrath <roland@redhat.com>
706 * Makefile.am (noinst_HEADERS): Add loc2c.c.
708 * test2.c (main): Check sscanf result to quiet warning.
709 --- a/libdwfl/Makefile.in
710 +++ b/libdwfl/Makefile.in
711 @@ -182,6 +182,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
712 INSTALL_SCRIPT = @INSTALL_SCRIPT@
713 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
715 +LD_AS_NEEDED = @LD_AS_NEEDED@
718 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
719 @@ -211,6 +212,7 @@ SHELL = @SHELL@
724 XGETTEXT = @XGETTEXT@
725 XGETTEXT_015 = @XGETTEXT_015@
726 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
727 @@ -274,7 +276,7 @@ INCLUDES = -I. -I$(srcdir) -I$(top_srcdi
729 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
730 $($(*F)_no_Werror),,-Werror) $(if \
731 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
732 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
733 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
735 @MUDFLAP_FALSE@libmudflap =
736 --- a/libebl/ChangeLog
737 +++ b/libebl/ChangeLog
739 * Makefile.am (libebl_*_so_SOURCES): Set to $(*_SRCS) so dependency
740 tracking works right.
742 +2005-05-31 Roland McGrath <roland@redhat.com>
744 + * Makefile.am (WEXTRA): New variable, substituted by configure.
745 + (AM_CFLAGS): Use it in place of -Wextra.
747 2005-05-21 Ulrich Drepper <drepper@redhat.com>
749 * libebl_x86_64.map: Add x86_64_core_note.
750 --- a/libebl/Makefile.in
751 +++ b/libebl/Makefile.in
752 @@ -143,6 +143,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
753 INSTALL_SCRIPT = @INSTALL_SCRIPT@
754 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
756 +LD_AS_NEEDED = @LD_AS_NEEDED@
759 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
760 @@ -172,6 +173,7 @@ SHELL = @SHELL@
765 XGETTEXT = @XGETTEXT@
766 XGETTEXT_015 = @XGETTEXT_015@
767 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
768 @@ -235,7 +237,7 @@ INCLUDES = -I. -I$(srcdir) -I$(top_srcdi
769 -I$(srcdir)/../libasm
770 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
771 $($(*F)_no_Werror),,-Werror) $(if \
772 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
773 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
774 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
775 $(am__append_1) -fpic
776 @MUDFLAP_FALSE@libmudflap =
777 --- a/libelf/ChangeLog
778 +++ b/libelf/ChangeLog
781 * elf.h: Update from glibc.
783 +2005-05-31 Roland McGrath <roland@redhat.com>
785 + * Makefile.am (WEXTRA): New variable, substituted by configure.
786 + (AM_CFLAGS): Use it in place of -Wextra.
788 2005-05-08 Roland McGrath <roland@redhat.com>
790 * elf_begin.c (read_file) [_MUDFLAP]: Don't use mmap for now.
791 --- a/libelf/common.h
792 +++ b/libelf/common.h
793 @@ -160,7 +160,7 @@ libelf_release_all (Elf *elf)
794 (Var) = (sizeof (Var) == 1 \
795 ? (unsigned char) (Var) \
796 : (sizeof (Var) == 2 \
798 + ? (unsigned short int) bswap_16 (Var) \
799 : (sizeof (Var) == 4 \
802 @@ -169,7 +169,7 @@ libelf_release_all (Elf *elf)
803 (Dst) = (sizeof (Var) == 1 \
804 ? (unsigned char) (Var) \
805 : (sizeof (Var) == 2 \
807 + ? (unsigned short int) bswap_16 (Var) \
808 : (sizeof (Var) == 4 \
811 --- a/libelf/Makefile.in
812 +++ b/libelf/Makefile.in
813 @@ -189,6 +189,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
814 INSTALL_SCRIPT = @INSTALL_SCRIPT@
815 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
817 +LD_AS_NEEDED = @LD_AS_NEEDED@
820 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
821 @@ -218,6 +219,7 @@ SHELL = @SHELL@
826 XGETTEXT = @XGETTEXT@
827 XGETTEXT_015 = @XGETTEXT_015@
828 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
829 @@ -279,7 +281,7 @@ zip_LIBS = @zip_LIBS@
830 INCLUDES = -I. -I$(srcdir) -I$(top_srcdir)/lib -I..
831 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
832 $($(*F)_no_Werror),,-Werror) $(if \
833 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
834 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
835 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
836 $(am__append_1) $(am__append_2)
837 @MUDFLAP_FALSE@libmudflap =
840 @@ -75,6 +75,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
841 INSTALL_SCRIPT = @INSTALL_SCRIPT@
842 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
844 +LD_AS_NEEDED = @LD_AS_NEEDED@
847 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
848 @@ -104,6 +105,7 @@ SHELL = @SHELL@
853 XGETTEXT = @XGETTEXT@
854 XGETTEXT_015 = @XGETTEXT_015@
855 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
858 @@ -155,6 +155,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
859 INSTALL_SCRIPT = @INSTALL_SCRIPT@
860 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
862 +LD_AS_NEEDED = @LD_AS_NEEDED@
865 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
866 @@ -184,6 +185,7 @@ SHELL = @SHELL@
871 XGETTEXT = @XGETTEXT@
872 XGETTEXT_015 = @XGETTEXT_015@
873 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
874 --- a/src/addr2line.c
875 +++ b/src/addr2line.c
876 @@ -455,10 +455,10 @@ handle_address (const char *string, Dwfl
880 - if (sscanf (string, "(%m[^)])%" PRIiMAX "%n", &name, &addr, &i) == 2
881 + if (sscanf (string, "(%a[^)])%" PRIiMAX "%n", &name, &addr, &i) == 2
882 && string[i] == '\0')
883 parsed = adjust_to_section (name, &addr, dwfl);
884 - switch (sscanf (string, "%m[^-+]%n%" PRIiMAX "%n", &name, &i, &addr, &j))
885 + switch (sscanf (string, "%a[^-+]%n%" PRIiMAX "%n", &name, &i, &addr, &j))
892 * readelf.c (attr_callback): Use print_block only when we don't use
895 +2009-08-17 Roland McGrath <roland@redhat.com>
897 + * ld.h: Disable extern inlines for GCC 4.2.
899 2009-08-14 Roland McGrath <roland@redhat.com>
901 + * strings.c (read_block): Conditionalize posix_fadvise use
902 + on [POSIX_FADV_SEQUENTIAL].
903 + From Petr Salinger <Petr.Salinger@seznam.cz>.
905 * ar.c (do_oper_extract): Use pathconf instead of statfs.
907 2009-08-01 Ulrich Drepper <drepper@redhat.com>
909 * readelf.c (print_debug_frame_section): Use t instead of j formats
910 for ptrdiff_t OFFSET.
912 + * addr2line.c (handle_address): Use %a instead of %m for compatibility.
914 2009-01-21 Ulrich Drepper <drepper@redhat.com>
916 * elflint.c (check_program_header): Fix typo in .eh_frame_hdr section
918 that matches its PT_LOAD's p_flags &~ PF_W. On sparc, PF_X really
921 +2008-03-01 Roland McGrath <roland@redhat.com>
923 + * readelf.c (dump_archive_index): Tweak portability hack
924 + to match [__GNUC__ < 4] too.
926 2008-02-29 Roland McGrath <roland@redhat.com>
928 * readelf.c (print_attributes): Add a cast.
931 * readelf.c (hex_dump): Fix rounding error in whitespace calculation.
933 + * Makefile.am (readelf_no_Werror): New variable.
935 2007-10-15 Roland McGrath <roland@redhat.com>
937 * make-debug-archive.in: New file.
938 @@ -1298,6 +1315,10 @@
939 * elflint.c (valid_e_machine): Add EM_ALPHA.
940 Reported by Christian Aichinger <Greek0@gmx.net>.
942 + * strings.c (map_file): Define POSIX_MADV_SEQUENTIAL to
943 + MADV_SEQUENTIAL if undefined. Don't call posix_madvise
944 + if neither is defined.
946 2006-08-08 Ulrich Drepper <drepper@redhat.com>
948 * elflint.c (check_dynamic): Don't require DT_HASH for DT_SYMTAB.
949 @@ -1374,6 +1395,10 @@
950 * Makefile.am: Add hacks to create dependency files for non-generic
953 +2006-04-05 Roland McGrath <roland@redhat.com>
955 + * strings.c (MAP_POPULATE): Define to 0 if undefined.
957 2006-06-12 Ulrich Drepper <drepper@redhat.com>
959 * ldgeneric.c (ld_generic_generate_sections): Don't create .interp
960 @@ -1722,6 +1747,11 @@
961 * readelf.c (print_debug_loc_section): Fix indentation for larger
964 +2005-05-31 Roland McGrath <roland@redhat.com>
966 + * Makefile.am (WEXTRA): New variable, substituted by configure.
967 + (AM_CFLAGS): Use it in place of -Wextra.
969 2005-05-30 Roland McGrath <roland@redhat.com>
971 * readelf.c (print_debug_line_section): Print section offset of each
972 --- a/src/findtextrel.c
973 +++ b/src/findtextrel.c
974 @@ -504,7 +504,11 @@ ptrcompare (const void *p1, const void *
978 -check_rel (size_t nsegments, struct segments segments[nsegments],
979 +check_rel (size_t nsegments, struct segments segments[
984 GElf_Addr addr, Elf *elf, Elf_Scn *symscn, Dwarf *dw,
985 const char *fname, bool more_than_one, void **knownsrcs)
989 @@ -1122,6 +1122,7 @@ extern bool dynamically_linked_p (void);
991 /* Checked whether the symbol is undefined and referenced from a DSO. */
992 extern bool linked_from_dso_p (struct scninfo *scninfo, size_t symidx);
993 +#if defined __OPTIMIZE__ && !(__GNUC__ == 4 && __GNUC_MINOR__ == 2)
994 #ifdef __GNUC_STDC_INLINE__
995 __attribute__ ((__gnu_inline__))
997 @@ -1139,5 +1140,6 @@ linked_from_dso_p (struct scninfo *scnin
999 return sym->defined && sym->in_dso;
1001 +#endif /* Optimizing and not GCC 4.2. */
1004 --- a/src/Makefile.am
1005 +++ b/src/Makefile.am
1006 @@ -99,6 +99,9 @@ addr2line_no_Wformat = yes
1007 # XXX While the file is not finished, don't warn about this
1008 ldgeneric_no_Wunused = yes
1010 +# Buggy old compilers.
1011 +readelf_no_Werror = yes
1013 readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl
1014 nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl
1015 size_LDADD = $(libelf) $(libeu) $(libmudflap)
1016 --- a/src/Makefile.in
1017 +++ b/src/Makefile.in
1018 @@ -228,6 +228,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
1019 INSTALL_SCRIPT = @INSTALL_SCRIPT@
1020 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
1022 +LD_AS_NEEDED = @LD_AS_NEEDED@
1025 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
1026 @@ -257,6 +258,7 @@ SHELL = @SHELL@
1031 XGETTEXT = @XGETTEXT@
1032 XGETTEXT_015 = @XGETTEXT_015@
1033 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
1034 @@ -321,7 +323,7 @@ INCLUDES = -I. -I$(srcdir) -I$(top_srcdi
1035 -I$(srcdir)/../libasm
1036 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
1037 $($(*F)_no_Werror),,-Werror) $(if \
1038 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
1039 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
1040 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
1042 @MUDFLAP_FALSE@libmudflap =
1043 @@ -368,6 +370,9 @@ strings_no_Wformat = yes
1044 addr2line_no_Wformat = yes
1045 # XXX While the file is not finished, don't warn about this
1046 ldgeneric_no_Wunused = yes
1048 +# Buggy old compilers.
1049 +readelf_no_Werror = yes
1050 readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl
1051 nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl
1052 size_LDADD = $(libelf) $(libeu) $(libmudflap)
1055 @@ -4274,10 +4274,11 @@ struct listptr
1056 #define listptr_offset_size(p) ((p)->dwarf64 ? 8 : 4)
1057 #define listptr_address_size(p) ((p)->addr64 ? 8 : 4)
1059 +static const char *listptr_name;
1061 -compare_listptr (const void *a, const void *b, void *arg)
1062 +compare_listptr (const void *a, const void *b)
1064 - const char *name = arg;
1065 + const char *const name = listptr_name;
1066 struct listptr *p1 = (void *) a;
1067 struct listptr *p2 = (void *) b;
1069 @@ -4357,8 +4358,11 @@ static void
1070 sort_listptr (struct listptr_table *table, const char *name)
1073 - qsort_r (table->table, table->n, sizeof table->table[0],
1074 - &compare_listptr, (void *) name);
1076 + listptr_name = name;
1077 + qsort (table->table, table->n, sizeof table->table[0],
1078 + &compare_listptr);
1083 @@ -8098,7 +8102,7 @@ dump_archive_index (Elf *elf, const char
1084 if (unlikely (elf_rand (elf, as_off) == 0)
1085 || unlikely ((subelf = elf_begin (-1, ELF_C_READ_MMAP, elf))
1087 -#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 7)
1088 +#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 7) || __GNUC__ < 4
1091 error (EXIT_FAILURE, 0,
1098 +#ifndef MAP_POPULATE
1099 +# define MAP_POPULATE 0
1103 /* Prototypes of local functions. */
1104 static int read_fd (int fd, const char *fname, off64_t fdlen);
1105 @@ -491,8 +495,13 @@ map_file (int fd, off64_t start_off, off
1107 if (mem != MAP_FAILED)
1109 +#if !defined POSIX_MADV_SEQUENTIAL && defined MADV_SEQUENTIAL
1110 +# define POSIX_MADV_SEQUENTIAL MADV_SEQUENTIAL
1112 +#ifdef POSIX_MADV_SEQUENTIAL
1113 /* We will go through the mapping sequentially. */
1114 (void) posix_madvise (mem, map_size, POSIX_MADV_SEQUENTIAL);
1118 if (errno != EINVAL && errno != ENOMEM)
1119 @@ -584,9 +593,11 @@ read_block (int fd, const char *fname, o
1120 elfmap_off = from & ~(ps - 1);
1121 elfmap_base = elfmap = map_file (fd, elfmap_off, fdlen, &elfmap_size);
1123 +#ifdef POSIX_FADV_SEQUENTIAL
1124 if (unlikely (elfmap == MAP_FAILED))
1125 /* Let the kernel know we are going to read everything in sequence. */
1126 (void) posix_fadvise (fd, 0, 0, POSIX_FADV_SEQUENTIAL);
1130 if (unlikely (elfmap == MAP_FAILED))
1137 +#ifdef HAVE_FUTIMES
1138 +# define FUTIMES(fd, fname, tvp) futimes (fd, tvp)
1140 +# define FUTIMES(fd, fname, tvp) utimes (fname, tvp)
1144 /* Name and version of program. */
1145 static void print_version (FILE *stream, struct argp_state *state);
1146 @@ -311,8 +317,18 @@ process_file (const char *fname)
1148 /* If we have to preserve the timestamp, we need it in the
1149 format utimes() understands. */
1150 +#ifdef HAVE_STRUCT_STAT_ST_ATIM
1151 TIMESPEC_TO_TIMEVAL (&tv[0], &pre_st.st_atim);
1153 + tv[0].tv_sec = pre_st.st_atime;
1154 + tv[0].tv_usec = 0;
1156 +#ifdef HAVE_STRUCT_STAT_ST_MTIM
1157 TIMESPEC_TO_TIMEVAL (&tv[1], &pre_st.st_mtim);
1159 + tv[1].tv_sec = pre_st.st_atime;
1160 + tv[1].tv_usec = 0;
1164 /* Open the file. */
1165 @@ -1809,7 +1825,7 @@ while computing checksum for debug infor
1166 /* If requested, preserve the timestamp. */
1169 - if (futimes (fd, tvp) != 0)
1170 + if (FUTIMES (fd, output_fname, tvp) != 0)
1172 error (0, errno, gettext ("\
1173 cannot set access and modification date of '%s'"),
1174 @@ -1866,7 +1882,7 @@ handle_ar (int fd, Elf *elf, const char
1178 - if (unlikely (futimes (fd, tvp) != 0))
1179 + if (unlikely (FUTIMES (fd, fname, tvp) != 0))
1181 error (0, errno, gettext ("\
1182 cannot set access and modification date of '%s'"), fname);
1183 --- a/tests/ChangeLog
1184 +++ b/tests/ChangeLog
1187 2008-01-21 Roland McGrath <roland@redhat.com>
1189 + * line2addr.c (main): Revert last change.
1191 * testfile45.S.bz2: Add tests for cltq, cqto.
1192 * testfile45.expect.bz2: Adjust.
1194 @@ -913,6 +915,11 @@
1195 * Makefile.am (TESTS): Add run-elflint-test.sh.
1196 (EXTRA_DIST): Add run-elflint-test.sh and testfile18.bz2.
1198 +2005-05-31 Roland McGrath <roland@redhat.com>
1200 + * Makefile.am (WEXTRA): New variable, substituted by configure.
1201 + (AM_CFLAGS): Use it in place of -Wextra.
1203 2005-05-24 Ulrich Drepper <drepper@redhat.com>
1205 * get-files.c (main): Use correct format specifier.
1206 --- a/tests/line2addr.c
1207 +++ b/tests/line2addr.c
1208 @@ -132,7 +132,7 @@ main (int argc, char *argv[])
1210 struct args a = { .arg = argv[cnt] };
1212 - switch (sscanf (a.arg, "%m[^:]:%d", &a.file, &a.line))
1213 + switch (sscanf (a.arg, "%a[^:]:%d", &a.file, &a.line))
1217 --- a/tests/Makefile.in
1218 +++ b/tests/Makefile.in
1219 @@ -372,6 +372,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
1220 INSTALL_SCRIPT = @INSTALL_SCRIPT@
1221 INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
1223 +LD_AS_NEEDED = @LD_AS_NEEDED@
1226 LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
1227 @@ -401,6 +402,7 @@ SHELL = @SHELL@
1232 XGETTEXT = @XGETTEXT@
1233 XGETTEXT_015 = @XGETTEXT_015@
1234 XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@
1235 @@ -462,7 +464,7 @@ zip_LIBS = @zip_LIBS@
1236 INCLUDES = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. $(am__append_2)
1237 AM_CFLAGS = -std=gnu99 -Wall -Wshadow $(if \
1238 $($(*F)_no_Werror),,-Werror) $(if \
1239 - $($(*F)_no_Wunused),,-Wunused -Wextra) $(if \
1240 + $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) $(if \
1241 $($(*F)_no_Wformat),-Wno-format,-Wformat=2) $($(*F)_CFLAGS) \
1243 @MUDFLAP_FALSE@libmudflap =