From: Andreas Schwab Date: Tue, 25 May 2010 13:09:20 +0000 (+0200) Subject: Avoid strict-aliasing issues X-Git-Tag: fedora/glibc-2.12.90-2~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=96aefb90e843648812d1832789f4a88ea5350605;p=thirdparty%2Fglibc.git Avoid strict-aliasing issues --- diff --git a/elf/Makefile b/elf/Makefile index e600cc39827..51b1c0f7541 100644 --- a/elf/Makefile +++ b/elf/Makefile @@ -129,6 +129,7 @@ include ../Makeconfig ifeq ($(unwind-find-fde),yes) routines += unwind-dw2-fde-glibc shared-only-routines += unwind-dw2-fde-glibc +CFLAGS-unwind-dw2-fde-glibc.c = -fno-strict-aliasing endif before-compile = $(objpfx)trusted-dirs.h diff --git a/inet/Makefile b/inet/Makefile index 37985940aed..0b4a35429c0 100644 --- a/inet/Makefile +++ b/inet/Makefile @@ -57,6 +57,8 @@ tests := htontest test_ifindex tst-ntoa tst-ether_aton tst-network \ include ../Rules +CFLAGS-tst-inet6_rth.c = -fno-strict-aliasing + ifeq ($(have-thread-library),yes) CFLAGS-gethstbyad_r.c = -DUSE_NSCD=1 -fexceptions diff --git a/nis/Makefile b/nis/Makefile index 8083ee80441..42f85dd291b 100644 --- a/nis/Makefile +++ b/nis/Makefile @@ -69,6 +69,8 @@ libnss_nisplus-inhibit-o = $(filter-out .os,$(object-suffixes)) include ../Rules +CFLAGS-nis_findserv.c = -fno-strict-aliasing +CFLAGS-ypclnt.c = -fno-strict-aliasing $(objpfx)libnss_compat.so: $(objpfx)libnsl.so$(libnsl.so-version) $(objpfx)libnss_nis.so: $(objpfx)libnsl.so$(libnsl.so-version) \ diff --git a/nss/Makefile b/nss/Makefile index 670e6b2f16d..323b24419ed 100644 --- a/nss/Makefile +++ b/nss/Makefile @@ -74,6 +74,7 @@ endif include ../Rules +CFLAGS-files-hosts.c = -fno-strict-aliasing ifeq (yes,$(build-static-nss)) $(objpfx)getent: $(objpfx)libnss_files.a diff --git a/resolv/Makefile b/resolv/Makefile index 42e35056469..cfac17b4744 100644 --- a/resolv/Makefile +++ b/resolv/Makefile @@ -77,6 +77,7 @@ CPPFLAGS += -Dgethostbyname=res_gethostbyname \ -Dgetnetbyaddr=res_getnetbyaddr CFLAGS-res_hconf.c = -fexceptions +CFLAGS-res_send.c = -fno-strict-aliasing # The BIND code elicits some harmless warnings. +cflags += -Wno-strict-prototypes -Wno-write-strings diff --git a/sunrpc/Makefile b/sunrpc/Makefile index 30f74dc135f..7eba7b7e850 100644 --- a/sunrpc/Makefile +++ b/sunrpc/Makefile @@ -129,6 +129,10 @@ CFLAGS-openchild.c = -fexceptions CPPFLAGS += -D_RPC_THREAD_SAFE_ +CFLAGS-clnt_tcp.c = -fno-strict-aliasing +CFLAGS-clnt_udp.c = -fno-strict-aliasing +CFLAGS-clnt_unix.c = -fno-strict-aliasing + include ../Rules $(objpfx)rpcgen: $(addprefix $(objpfx),$(rpcgen-objs)) \ diff --git a/sysdeps/powerpc/powerpc64/elf/Makefile b/sysdeps/powerpc/powerpc64/elf/Makefile index 6a77e116bd6..5ac2c057544 100644 --- a/sysdeps/powerpc/powerpc64/elf/Makefile +++ b/sysdeps/powerpc/powerpc64/elf/Makefile @@ -9,3 +9,5 @@ CFLAGS-rtld-mempcpy.os = $(no-special-regs) CFLAGS-rtld-memmove.os = $(no-special-regs) CFLAGS-rtld-memchr.os = $(no-special-regs) CFLAGS-rtld-strnlen.os = $(no-special-regs) + +CFLAGS-gmon-start.c = -fno-strict-aliasing