blob: fecf5ff17209fc9f66b9cd8e83e55e04d3e70e85 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
--- 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 -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`
+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 \
@@ -29,21 +29,8 @@ vsftpd: $(OBJS)
$(CC) -o vsftpd $(OBJS) $(LINK) $(LDFLAGS) $(LIBS)
install:
- if [ -x /usr/local/sbin ]; then \
- $(INSTALL) -m 755 vsftpd /usr/local/sbin/vsftpd; \
- else \
- $(INSTALL) -m 755 vsftpd /usr/sbin/vsftpd; fi
- if [ -x /usr/local/man ]; then \
- $(INSTALL) -m 644 vsftpd.8 /usr/local/man/man8/vsftpd.8; \
- $(INSTALL) -m 644 vsftpd.conf.5 /usr/local/man/man5/vsftpd.conf.5; \
- elif [ -x /usr/share/man ]; then \
- $(INSTALL) -m 644 vsftpd.8 /usr/share/man/man8/vsftpd.8; \
- $(INSTALL) -m 644 vsftpd.conf.5 /usr/share/man/man5/vsftpd.conf.5; \
- else \
- $(INSTALL) -m 644 vsftpd.8 /usr/man/man8/vsftpd.8; \
- $(INSTALL) -m 644 vsftpd.conf.5 /usr/man/man5/vsftpd.conf.5; fi
- 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/vsftpd
clean:
rm -f *.o *.swp vsftpd
|