]> git.sesse.net Git - betaftpd/blob - Makefile.in
process_all_clients(): Fixed a bug (reporting and much tracing by Sean MacLennan...
[betaftpd] / Makefile.in
1 VERSION=0.0.8pre17-dev
2
3 # main target
4 all: betaftpd
5
6 # various defines
7 CC = @CC@
8 VPATH = @srcdir@
9 prefix = @prefix@
10
11 CFLAGS      = @CFLAGS@
12 REAL_CFLAGS = $(CFLAGS) @DEFS@ -I@srcdir@ -I. -DVERSION=\"$(VERSION)\"
13 LIBS        = @LIBS@
14 OBJS        = disp.o ftpd.o cmds.o nonroot.o ascii.o
15 ASSMS       = disp.s ftpd.s cmds.s nonroot.s ascii.s
16 CPPS        = disp.i ftpd.i cmds.i nonroot.i ascii.i
17
18 # Since we use VPATH, override .c.o rule
19 .c.o:   $*.c config.h
20         $(CC) $(REAL_CFLAGS) -c @srcdir@/$*.c
21 .c.s:   $*.c config.h
22         $(CC) $(REAL_CFLAGS) -S @srcdir@/$*.c
23
24 # deps
25 cmds.o:         @srcdir@/cmds.c @srcdir@/ftpd.h @srcdir@/cmds.h @srcdir@/nonroot.h config.h
26 ftpd.o:         @srcdir@/ftpd.c @srcdir@/ftpd.h @srcdir@/cmds.h config.h
27 disp.o:         @srcdir@/disp.c @srcdir@/ftpd.h config.h
28 nonroot.o:      @srcdir@/nonroot.c @srcdir@/nonroot.h config.h
29 ascii.o:        @srcdir@/ascii.c config.h
30
31 betaftpd: $(OBJS)
32         $(CC) $(REAL_CFLAGS) $(LIBS) -o betaftpd $(OBJS)
33 assembly-files: $(ASSMS)
34 betaftpd-from-assembly-files: $(ASSMS)
35         $(CC) $(LIBS) -o betaftpd -Wl,--sort-common $(ASSMS)
36
37 clean:
38         rm -f $(OBJS) $(ASSMS) $(CPPS)
39         rm -f core
40         rm -f betaftpd
41
42 distclean: clean
43         rm -f config.log config.cache config.status Makefile config.h
44
45 install: betaftpd
46         install betaftpd $(prefix)/sbin/betaftpd
47
48 #
49 # NOTE: This is not intended for end users, and should be run from a
50 # configured BetaFTPD in the source directory only.
51 #
52 package:
53 #       strip-exec
54         rm -rf betaftpd-$(VERSION)
55         mkdir betaftpd-$(VERSION)
56         mkdir betaftpd-$(VERSION)/doc
57 #       cp betaftpd betaftpd-$(VERSION)
58         make distclean
59         autoconf
60         autoheader configure.in > config.h.in
61         cp README Makefile.in acconfig.h cmds.c cmds.h betaftpd-$(VERSION)
62         cp config.h.in configure configure.in disp.c ftpd.c betaftpd-$(VERSION)
63         cp nonroot.c ascii.c ascii.h nonroot.h ftpd.h strip-exec betaftpd.lsm betaftpd-$(VERSION)
64         cp doc/CREDITS doc/CHANGES doc/CHANGES-0.0.8 doc/COPYING betaftpd-$(VERSION)/doc
65         cp doc/KNOWN-BUGS doc/RFC-COMPLIANCE doc/README.nonroot betaftpd-$(VERSION)/doc
66         cp doc/README.rights doc/README.platforms betaftpd-$(VERSION)/doc
67         tar cf - betaftpd-$(VERSION)/ | gzip -9vv > betaftpd-$(VERSION).tar.gz
68         tar cf - betaftpd-$(VERSION)/ | bzip2 -3vv > betaftpd-$(VERSION).tar.bz2