File: Makefile

package info (click to toggle)
netstd 3.07-7slink.3
  • links: PTS
  • area: main
  • in suites: slink
  • size: 6,312 kB
  • ctags: 9,027
  • sloc: ansic: 72,107; cpp: 6,144; makefile: 1,650; yacc: 1,614; sh: 1,164; perl: 308; awk: 46
file content (37 lines) | stat: -rw-r--r-- 779 bytes parent folder | download | duplicates (2)
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
include ../MCONFIG

CFLAGS+=-I../support
LIBS+=-L../support -lsupport

# for glibc use libcrypt (MD5 passwords)
ifeq ($(USE_GLIBC),1)
LIBS+=-lcrypt
endif


OBJS=ftpd.o ftpcmd.o logutmp.o logwtmp.o popen.o

all: ftpd

%.o: %.c
	$(CC) $(CFLAGS) -DHASSETPROCTITLE $< -c

ftpcmd.c: %.c: %.y
	$(YACC) $<
	-mv -f y.tab.c $@

ftpd: $(OBJS)
	$(CC) $(LDFLAGS) $^ $(LIBS) -o $@

install: ftpd
	install -s -o root -m$(DAEMONMODE) ftpd $(INSTALLROOT)$(SBINDIR)/in.ftpd
	install -m$(MANMODE) ftpd.8 $(INSTALLROOT)$(MANDIR)/man8/in.ftpd.8
	install -m$(MANMODE) ftpusers.5 $(INSTALLROOT)$(MANDIR)/man5/ftpusers.5
	ln -sf in.ftpd.8 $(INSTALLROOT)$(MANDIR)/man8/ftpd.8

clean:
	rm -f *.o ftpcmd.c y.tab.h ftpd


ftpd.o: pathnames.h
$(OBJS): extern.h ../support/daemon.h ../support/setproctitle.h