kernel: Use hashdestroy() to free hash tables allocated with hashinit().
[dragonfly.git] / usr.bin / doscmd / Makefile
1 # from BSDI Makefile,v 2.6 1996/04/08 20:06:40 bostic Exp
2 #
3 # $FreeBSD: src/usr.bin/doscmd/Makefile,v 1.21.2.5 2002/08/07 16:32:01 ru Exp $
4 # $DragonFly: src/usr.bin/doscmd/Makefile,v 1.5 2007/08/27 16:50:53 pavalos Exp $
5
6 PROG=   doscmd
7 SRCS=   AsyncIO.c ParseBuffer.c bios.c callback.c cmos.c config.c cpu.c cwd.c \
8         debug.c disktab.c dos.c doscmd.c ems.c emuint.c exe.c i386-pinsn.c \
9         int.c int10.c int13.c int14.c int16.c int17.c int1a.c int2f.c intff.c \
10         mem.c mouse.c net.c port.c setver.c signal.c timer.c trace.c trap.c \
11         tty.c video.c xms.c ${FONTHDRS}
12 CFLAGS+=        -I. -DDISASSEMBLER
13 FONTFILES=      cp437-8x8.pcf.gz cp437-8x14.pcf.gz cp437-8x16.pcf.gz
14 FONTHDRS=       font8x8.h font8x14.h font8x16.h
15 CLEANFILES=     ${FONTFILES} ${FONTHDRS} emsdriv.sys redir.com
16
17 XINCDIR=        ${DESTDIR}${X11BASE}/include
18 XLIBDIR=        ${DESTDIR}${X11BASE}/lib
19
20 EXEGRP:=        ${BINGRP}
21 EXEMODE=        ${NOBINMODE}
22 #BINGRP=                kmem
23 #BINMODE=       2555
24 WARNS?= 1
25
26 .if !defined(NO_X) && exists(${XINCDIR}/X11/X.h) && exists(${XLIBDIR}/libX11.a)
27 CFLAGS+=        -I${XINCDIR}
28 LDADD+=         -L${XLIBDIR} -lX11
29 DPADD+=         ${XLIBDIR}/libX11.a
30 .else
31 CFLAGS+=        -DNO_X
32 .endif
33
34 beforeinstall:
35         ${INSTALL} -o ${BINOWN} -g ${EXEGRP} -m ${EXEMODE} \
36             emsdriv.sys redir.com ${DESTDIR}/usr/libdata/doscmd/
37         ${INSTALL} -o ${BINOWN} -g ${EXEGRP} -m ${SHAREMODE} \
38             ${FONTFILES} ${DESTDIR}/usr/libdata/doscmd/fonts
39         cd ${.CURDIR} && \
40             ${INSTALL} -o ${BINOWN} -g ${EXEGRP} -m ${SHAREMODE} \
41                 fonts.dir ${DESTDIR}/usr/libdata/doscmd/fonts
42
43 cp437-8x8.pcf.gz: cp437-8x8.pcf.gz.uu
44         uudecode ${.CURDIR}/cp437-8x8.pcf.gz.uu
45
46 cp437-8x14.pcf.gz: cp437-8x14.pcf.gz.uu
47         uudecode ${.CURDIR}/cp437-8x14.pcf.gz.uu
48
49 cp437-8x16.pcf.gz: cp437-8x16.pcf.gz.uu
50         uudecode ${.CURDIR}/cp437-8x16.pcf.gz.uu
51
52 emsdriv.sys: emsdriv.sys.uu
53         uudecode ${.CURDIR}/emsdriv.sys.uu
54
55 font8x8.h: ${.CURDIR}/../../share/syscons/fonts/cp437-8x8.fnt
56         uudecode -p ${.ALLSRC} | \
57                 file2c 'u_int8_t font8x8[] = {' '};' > ${.TARGET}
58
59 font8x14.h: ${.CURDIR}/../../share/syscons/fonts/cp437-8x14.fnt
60         uudecode -p ${.ALLSRC} | \
61                 file2c 'u_int8_t font8x14[] = {' '};' > ${.TARGET}
62
63 font8x16.h: ${.CURDIR}/../../share/syscons/fonts/cp437-8x16.fnt
64         uudecode -p ${.ALLSRC} | \
65                 file2c 'u_int8_t font8x16[] = {' '};' > ${.TARGET}
66
67 redir.com: redir.com.uu
68         uudecode ${.CURDIR}/redir.com.uu
69
70 # Make sure the library names are defined.  We want to specify the full
71 # path to the standard crt0.o, and building two binaries in one directory
72 # breaks the automatic generation of dependencies for binaries.
73 NEED_LIBNAMES=  yes
74
75 .include <bsd.prog.mk>
76
77 # add dependancy after inclusion so we do not override the ${PROG}: target.
78 #
79 doscmd: ${FONTFILES} ${FONTHDRS} emsdriv.sys redir.com
80