summaryrefslogtreecommitdiff
path: root/package/vsftpd/patches/patch-Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'package/vsftpd/patches/patch-Makefile')
-rw-r--r--package/vsftpd/patches/patch-Makefile48
1 files changed, 15 insertions, 33 deletions
diff --git a/package/vsftpd/patches/patch-Makefile b/package/vsftpd/patches/patch-Makefile
index 83d21ca48..fecf5ff17 100644
--- a/package/vsftpd/patches/patch-Makefile
+++ b/package/vsftpd/patches/patch-Makefile
@@ -1,34 +1,28 @@
-$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
---- vsftpd-2.3.4.orig/Makefile 2009-05-22 21:44:52.000000000 +0200
-+++ vsftpd-2.3.4/Makefile 2011-10-13 21:01:57.600352003 +0200
-@@ -1,12 +1,12 @@
+--- vsftpd-3.0.2.orig/Makefile 2012-09-16 09:27:35.000000000 +0200
++++ vsftpd-3.0.2/Makefile 2013-11-09 11:38:47.000000000 +0100
+@@ -1,16 +1,16 @@
# Makefile for systems with GNU tools
-CC = gcc
+CC ?= gcc
INSTALL = install
IFLAGS = -idirafter dummyinc
#CFLAGS = -g
--CFLAGS = -O2 -Wall -W -Wshadow #-pedantic -Werror -Wconversion
-+CFLAGS ?= -O2 -Wall -W -Wshadow #-pedantic -Werror -Wconversion
+-CFLAGS = -O2 -fPIE -fstack-protector --param=ssp-buffer-size=4 \
++CFLAGS ?= -O2 -fPIE -fstack-protector --param=ssp-buffer-size=4 \
+ -Wall -W -Wshadow -Werror -Wformat-security \
+ -D_FORTIFY_SOURCE=2 \
+ #-pedantic -Wconversion
-LIBS = `./vsf_findlibs.sh`
--LINK = -Wl,-s
-+LIBS = -lcrypt
-+LINK =
++LIBS = -lcap -lcrypt
+ LINK = -Wl,-s
+-LDFLAGS = -fPIE -pie -Wl,-z,relro -Wl,-z,now
++LDFLAGS ?= -fPIE -pie -Wl,-z,relro -Wl,-z,now
OBJS = main.o utility.o prelogin.o ftpcmdio.o postlogin.o privsock.o \
tunables.o ftpdataio.o secbuf.o ls.o \
-@@ -17,6 +17,8 @@ OBJS = main.o utility.o prelogin.o ftpcm
- ssl.o sslslave.o ptracesandbox.o ftppolicy.o sysutil.o sysdeputil.o
-
-
-+DESTDIR =
-+
- .c.o:
- $(CC) -c $*.c $(CFLAGS) $(IFLAGS)
-
-@@ -24,21 +26,20 @@ vsftpd: $(OBJS)
- $(CC) -o vsftpd $(OBJS) $(LINK) $(LIBS) $(LDFLAGS)
+@@ -29,21 +29,8 @@ vsftpd: $(OBJS)
+ $(CC) -o vsftpd $(OBJS) $(LINK) $(LDFLAGS) $(LIBS)
install:
- if [ -x /usr/local/sbin ]; then \
@@ -47,19 +41,7 @@ $Id: update-patches 24 2008-08-31 14:56:13Z wbx $
- if [ -x /etc/xinetd.d ]; then \
- $(INSTALL) -m 644 xinetd.d/vsftpd /etc/xinetd.d/vsftpd; fi
+ mkdir -p $(DESTDIR)/usr/sbin
-+ $(INSTALL) -m 755 vsftpd $(DESTDIR)/usr/sbin/
-+ mkdir -p $(DESTDIR)/usr/share/man/man8
-+ $(INSTALL) -m 644 vsftpd.8 $(DESTDIR)/usr/share/man/man8/
-+ mkdir -p $(DESTDIR)/usr/share/man/man5
-+ $(INSTALL) -m 644 vsftpd.conf.5 $(DESTDIR)/usr/share/man/man5/
-+ mkdir -p $(DESTDIR)/etc/xinetd.d
-+ $(INSTALL) -m 644 xinetd.d/vsftpd $(DESTDIR)/etc/xinetd.d/
-+
-+uninstall:
-+ rm -f $(DESTDIR)/usr/sbin/vsftpd
-+ rm -f $(DESTDIR)/usr/share/man/man8/vsftpd.8
-+ rm -f $(DESTDIR)/usr/share/man/man5/vsftpd.conf.5
-+ rm -f $(DESTDIR)/etc/xinetd.d/vsftpd
++ $(INSTALL) -m 755 vsftpd $(DESTDIR)/usr/sbin/vsftpd
clean:
rm -f *.o *.swp vsftpd