blob: 4a2a4d0ec7b7a488938c2d5e4f44c82f5d13eb22 (
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
|
# $NetBSD: Makefile,v 1.6 2021/04/08 06:52:42 rillig Exp $
# $eterna: Makefile,v 1.1 2009/05/22 21:51:39 mrg Exp $
# build a 100% lean bozohttpd-small.c
PROG= bozohttpd-small
NOMAN= # defined
SRCS= bozohttpd-small.c content-bozo-small.c ssl-bozo.c main.c
LEAN_IFDEF_FLAGS= -UDEBUG -DNO_USER_SUPPORT \
-DNO_CGIBIN_SUPPORT -DNO_DIRINDEX_SUPPORT \
-DNO_DAEMON_MODE -DNO_DYNAMIC_CONTENT \
-DNO_SSL_SUPPORT -UDO_HTPASSWD \
-DNO_LUA_SUPPORT -DNO_BLOCKLIST_SUPPORT
CPPFLAGS= -I$(.CURDIR)/.. ${LEAN_IFDEF_FLAGS}
bozohttpd-small.c: bozohttpd.c
unifdef $(LEAN_IFDEF_FLAGS) < $> > $@.tmp; \
status=$$?; \
if [ $$status -ne 1 ]; then \
echo "unifdef returned $$status, expecting 1" 2>&1; \
false; \
fi
mv -f $@.tmp $@
content-bozo-small.c: content-bozo.c
unifdef $(LEAN_IFDEF_FLAGS) < $> > $@.tmp; \
status=$$?; \
if [ $$status -ne 1 ]; then \
echo "unifdef returned $$status, expecting 1" 2>&1; \
false; \
fi
mv -f $@.tmp $@
CLEANFILES+= content-bozo-small.c bozohttpd-small.c
.PATH: $(.CURDIR)/..
.include <bsd.prog.mk>
|