1 From 087874b15367a04fd482541d1832696d7163d1ac Mon Sep 17 00:00:00 2001
2 From: Mike Frysinger <vapier@gentoo.org>
3 Date: Fri, 19 Nov 2010 23:35:47 -0500
4 Subject: [PATCH 2/4] NO_PIE: make PIE support controllable
6 Signed-off-by: Mike Frysinger <vapier@gentoo.org>
10 2 files changed, 7 insertions(+), 2 deletions(-)
12 diff --git a/Makefile b/Makefile
13 index 5343428..cfcfdbb 100644
16 @@ -106,6 +106,10 @@ CPPFLAGS += -DIGNORE_SIGCHLD # AIX 4.x, HP-UX 9.x
19 # CFLAGS += -arch m68k -arch i386 -arch hppa
25 # Auxiliary libraries that you may have to specify
27 @@ -125,9 +129,9 @@ CFLAGS += -Wall -Wstrict-prototypes
28 all: portmap pmap_dump pmap_set portmap.man
30 CPPFLAGS += $(HOSTS_ACCESS)
31 -portmap: CFLAGS += -fpie
32 +portmap: CFLAGS += $(CFLAGS_PIE)
33 portmap: LDLIBS += $(WRAP_LIB)
34 -portmap: LDFLAGS += -pie
35 +portmap: LDFLAGS += $(LDFLAGS_PIE)
36 portmap: portmap.o pmap_check.o from_local.o
38 from_local: CPPFLAGS += -DTEST
39 diff --git a/README b/README
40 index 916de7e..e0b561a 100644
43 @@ -18,6 +18,7 @@ There is no "./configure", just use "make".
45 Some make variable can be used to control compilation.
47 + NO_PIE= if non-empty, don't build portmap as a PIE
48 NO_TCP_WRAPPER= if non-empty, don't use tcp_wrappers
49 USE_DNS= if set, tcp_wrappers can check peers based on hostname
50 as well as IP address. This should only be used if you