1 1.1.1.3 mrg # $eterna: Makefile,v 1.29 2010/05/10 02:24:30 mrg Exp $ 2 1.1 tls # 3 1.1 tls # berkeley (netbsd) makefile. see Makefile.boot for other systems. 4 1.1 tls 5 1.1 tls # compile-time options are: 6 1.1 tls # DEBUG /* include debugging support */ 7 1.1 tls # NO_USER_SUPPORT /* don't support /~user requests */ 8 1.1 tls # NO_CGIBIN_SUPPORT /* don't support cgi-bin requests */ 9 1.1 tls # NO_DIRINDEX_SUPPORT /* don't support directory indexing */ 10 1.1 tls # NO_DAEMON_MODE /* don't support daemon mode */ 11 1.1 tls # NO_DYNAMIC_CONTENT /* don't support dynamic content updates */ 12 1.1 tls # NO_SSL_SUPPORT /* don't support ssl (https) */ 13 1.1 tls # DO_HTPASSWD /* support .htpasswd files */ 14 1.1 tls # 15 1.1 tls # these are usually set via the "COPTS" variable, or some other method 16 1.1 tls # for setting CFLAGS relevant to your make, eg 17 1.1 tls # % make COPTS="-DDEBUG -DDO_HTPASSWD" 18 1.1 tls 19 1.1.1.2 mrg PROG?= bozohttpd 20 1.1 tls MAN= bozohttpd.8 21 1.1 tls SRCS= bozohttpd.c ssl-bozo.c auth-bozo.c cgi-bozo.c daemon-bozo.c \ 22 1.1 tls tilde-luzah-bozo.c dir-index-bozo.c content-bozo.c 23 1.1.1.3 mrg SRCS+= main.c 24 1.1 tls 25 1.1.1.3 mrg WARNS?= 4 26 1.1 tls 27 1.1 tls check: 28 1.1.1.2 mrg cd $(.CURDIR)/testsuite && $(MAKE) check 29 1.1 tls 30 1.1.1.2 mrg .if ${PROG} == "bozohttpd" 31 1.1 tls clean: 32 1.1.1.2 mrg cd $(.CURDIR)/testsuite && $(MAKE) clean 33 1.1.1.2 mrg .endif 34 1.1 tls 35 1.1 tls CRYPTOLIBS= -lcrypto -lssl 36 1.1 tls CRYPTODEPS= $(LIBCRYPTO) $(LIBSSL) 37 1.1 tls 38 1.1 tls NROFF?= nroff 39 1.1 tls 40 1.1 tls # if not defining -DNO_SSL_SUPPORT 41 1.1 tls LDADD= $(CRYPTOLIBS) 42 1.1 tls DPADD= $(CRYPTODEPS) 43 1.1 tls 44 1.1 tls PREHTMLFROB= sed \ 45 1.1 tls -e 's/&/\&/' \ 46 1.1 tls -e 's/</\</' \ 47 1.1 tls -e 's/>/\>/' 48 1.1 tls 49 1.1 tls HTMLFROB= sed \ 50 1.1 tls -e 's/\([MC] "[^"]*\)<dd>$$/\1<b>"<\/b><dd>/' \ 51 1.1 tls -e 's/'"''"'/\”/' \ 52 1.1 tls -e 's/""/\“/' \ 53 1.1 tls -e 's/<a href="\.\.\/html[^>]*>\(.*\)<\/a>/\1/' 54 1.1 tls 55 1.1 tls TXTFROB= col -b 56 1.1 tls 57 1.1 tls bozohttpd.8.html: bozohttpd.8 58 1.1 tls $(PREHTMLFROB) $> | $(NROFF) -mdoc2html | $(HTMLFROB) > $@ 59 1.1 tls 60 1.1 tls bozohttpd.8.txt: bozohttpd.8 61 1.1 tls $(NROFF) -mdoc -Tascii $> | $(TXTFROB) > $@ 62 1.1 tls 63 1.1 tls CLEANFILES+= bozohttpd.8.html bozohttpd.8.txt 64 1.1 tls 65 1.1 tls .include <bsd.prog.mk> 66