summaryrefslogtreecommitdiffstats
path: root/release/picobsd/build/Makefile.crunch
blob: 248b76032251122d5bd9eb1fe914032a84cfd7d3 (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
#
# $FreeBSD$
#
SRC?=/usr/src
CRUNCHFLAGS+= -DNOPAM -DRELEASE_CRUNCH -DNOSECURE -DNOCRYPT -DNONETGRAPH -DNOIPSEC

all: crunch

crunch:
	@cat crunch.conf|sed -e "s@/usr/src@${SRC}@" >crunch1.conf
	@( if [ -f crunch.inc ] ; then \
		crunchgen -h ./crunch.inc ./crunch1.conf ; \
	else \
		crunchgen -h ../../build/crunch.inc ./crunch1.conf ; \
	fi )
	@${MAKE} -f crunch1.mk $(CRUNCHFLAGS) all \
	    "CFLAGS=${CFLAGS} ${CRUNCHFLAGS}" #2>&1 >/dev/null
	strip --remove-section=.note --remove-section=.comment crunch1


clean:
	rm  -f *.o *.stub *.lo *_stub.c *.mk \
		crunch.cache \
		crunch.mk \
		crunch.c \
		crunch1* \
		crunch \
		.tmp_* \
		*.gz

install: 
	cp crunch1 ${MFS_MOUNTPOINT}/stand/crunch
	chmod 555 ${MFS_MOUNTPOINT}/stand/crunch
	for i in `crunchgen -l crunch1.conf` ; \
	do \
		ln ${MFS_MOUNTPOINT}/stand/crunch ${MFS_MOUNTPOINT}/stand/$${i}; \
	done
	rm ${MFS_MOUNTPOINT}/stand/crunch
	# Install the MIB files
	#mkdir -p ${MFS_MOUNTPOINT}/usr/local/share/snmp/mibs
	#cp ../../net/crunch1/mibs/*.txt ${MFS_MOUNTPOINT}/usr/local/share/snmp/mibs/


.include <bsd.prog.mk>
OpenPOWER on IntegriCloud