diff options
author | Francesco Colista <fcolista@alpinelinux.org> | 2014-04-15 09:53:51 +0000 |
---|---|---|
committer | Francesco Colista <fcolista@alpinelinux.org> | 2014-04-15 10:47:40 +0000 |
commit | 886cdb13df9d53858fead63397547357770eb638 (patch) | |
tree | e7c16624b276727775cc39c39dc84fdc35134cf5 /main/iputils/net-misc_iputils_files_iputils-20121221-makefile.patch | |
parent | 0a7a893f64cb0bddefb5a7ca2593fd95bbf43e7b (diff) | |
download | aports-886cdb13df9d53858fead63397547357770eb638.tar.bz2 aports-886cdb13df9d53858fead63397547357770eb638.tar.xz |
main/iputils: fixes compilation with musl
Diffstat (limited to 'main/iputils/net-misc_iputils_files_iputils-20121221-makefile.patch')
-rw-r--r-- | main/iputils/net-misc_iputils_files_iputils-20121221-makefile.patch | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/main/iputils/net-misc_iputils_files_iputils-20121221-makefile.patch b/main/iputils/net-misc_iputils_files_iputils-20121221-makefile.patch new file mode 100644 index 0000000000..66424c85cf --- /dev/null +++ b/main/iputils/net-misc_iputils_files_iputils-20121221-makefile.patch @@ -0,0 +1,61 @@ +From c66609d2c830d6fe06f48f5d38c54eb5cc6f2975 Mon Sep 17 00:00:00 2001 +From: Mike Frysinger <vapier@gentoo.org> +Date: Thu, 24 Jan 2013 23:36:16 -0500 +Subject: [PATCH [iputils]] fix handling of CFLAGS + +This defaults CFLAGS to -O3 without clobbering settings people have set +up in the environment already. + +Signed-off-by: Mike Frysinger <vapier@gentoo.org> +--- + Makefile | 13 +++++-------- + 1 file changed, 5 insertions(+), 8 deletions(-) + +diff --git a/Makefile b/Makefile +index 2c49940..ecabac3 100644 +--- a/Makefile ++++ b/Makefile +@@ -2,8 +2,6 @@ + # Configuration + # + +-# CC +-CC=gcc + # Path to parent kernel include files directory + LIBC_INCLUDE=/usr/include + # Libraries +@@ -48,11 +46,10 @@ ENABLE_RDISC_SERVER=no + + # ------------------------------------- + # What a pity, all new gccs are buggy and -Werror does not work. Sigh. +-# CCOPT=-fno-strict-aliasing -Wstrict-prototypes -Wall -Werror -g +-CCOPT=-fno-strict-aliasing -Wstrict-prototypes -Wall -g +-CCOPTOPT=-O3 +-GLIBCFIX=-D_GNU_SOURCE +-DEFINES= ++# CFLAGS+=-fno-strict-aliasing -Wstrict-prototypes -Wall -Werror -g ++CFLAGS?=-O3 -g ++CFLAGS+=-fno-strict-aliasing -Wstrict-prototypes -Wall ++CPPFLAGS+=-D_GNU_SOURCE + LDLIB= + + FUNC_LIB = $(if $(filter static,$(1)),$(LDFLAG_STATIC) $(2) $(LDFLAG_DYNAMIC),$(2)) +@@ -113,7 +110,6 @@ IPV4_TARGETS=tracepath ping clockdiff rdisc arping tftpd rarpd + IPV6_TARGETS=tracepath6 traceroute6 ping6 + TARGETS=$(IPV4_TARGETS) $(IPV6_TARGETS) + +-CFLAGS=$(CCOPTOPT) $(CCOPT) $(GLIBCFIX) $(DEFINES) + LDLIBS=$(LDLIB) $(ADDLIB) + + UNAME_N:=$(shell uname -n) +@@ -132,6 +128,7 @@ all: $(TARGETS) + $(COMPILE.c) $< $(DEF_$(patsubst %.o,%,$@)) -S -o $@ + %.o: %.c + $(COMPILE.c) $< $(DEF_$(patsubst %.o,%,$@)) -o $@ ++LINK.o += $(CFLAGS) + $(TARGETS): %: %.o + $(LINK.o) $^ $(LIB_$@) $(LDLIBS) -o $@ + +-- +1.8.0.2 + |