7 CLEANFILES+= makedevs.c rtermcap rtermcap.tmp dumpnlist
8 CLEANFILES+= keymap.tmp keymap.h
10 .PATH: ${.CURDIR}/../disklabel ${.CURDIR}/../../usr.bin/cksum
12 SRCS= anonFTP.c cdrom.c command.c config.c devices.c kget.c \
13 disks.c dispatch.c dist.c dmenu.c doc.c dos.c floppy.c \
14 ftp.c globals.c index.c install.c installUpgrade.c keymap.c \
15 label.c lndir.c main.c makedevs.c media.c menus.c misc.c mouse.c \
16 msg.c network.c nfs.c options.c package.c register.c system.c \
17 tape.c tcpip.c termcap.c ufs.c user.c variable.c wizard.c \
20 CFLAGS+= -Wall -I${.CURDIR}/../../gnu/lib/libdialog -I${.OBJDIR}
21 CFLAGS+= -I${.CURDIR}/../../sys
22 CFLAGS+= -DUC_PRIVATE -DKERN_NO_SYMBOLS
24 DPADD= ${LIBDIALOG} ${LIBNCURSES} ${LIBMYTINFO} ${LIBUTIL} ${LIBDISK} ${LIBFTPIO}
25 LDADD= -ldialog -lncurses -lmytinfo -lutil -ldisk -lftpio
27 makedevs.c: Makefile rtermcap keymap.h
29 echo '#include <sys/types.h>' > makedevs.tmp
31 file2c 'const char termcap_ansi[] = {' ',0};' \
34 file2c 'const char termcap_cons25[] = {' ',0};' \
36 ./rtermcap cons25-m | \
37 file2c 'const char termcap_cons25_m[] = {' ',0};' \
39 ./rtermcap cons25r | \
40 file2c 'const char termcap_cons25r[] = {' ',0};' \
42 ./rtermcap cons25r-m | \
43 file2c 'const char termcap_cons25r_m[] = {' ',0};' \
45 ./rtermcap cons25l1 | \
46 file2c 'const char termcap_cons25l1[] = {' ',0};' \
48 ./rtermcap cons25l1-m | \
49 file2c 'const char termcap_cons25l1_m[] = {' ',0};' \
52 file2c 'const char termcap_vt100[] = {' ',0};' \
54 .if ${MACHINE_ARCH} != "alpha"
55 file2c 'u_char boot0[] = {' '};' < /boot/boot0 >> makedevs.tmp
57 mv makedevs.tmp makedevs.c
59 rtermcap: ${.CURDIR}/rtermcap.c
60 ${CC} -o rtermcap ${.CURDIR}/rtermcap.c -ltermcap
63 KEYMAPS= be.iso br275.iso danish.iso fr.iso german.iso it.iso \
64 icelandic.iso jp.106 norwegian.iso ru.koi8-r si.iso spanish.iso \
65 swedish.iso swissgerman.iso uk.iso us.dvorak us.iso
70 for map in ${KEYMAPS} ; do \
71 kbdcontrol -L $$map | \
72 sed -e '/^static accentmap_t/,$$d' >> keymap.tmp ; \
74 echo "static struct keymapInfo keymapInfos[] = {" >> keymap.tmp
75 for map in ${KEYMAPS} ; do \
76 echo -n ' { "'$$map'", ' >> keymap.tmp ; \
77 echo "&keymap_$$map }," | tr '[-.]' '_' >> keymap.tmp ; \
79 ( echo " { 0 }"; echo "};" ; echo "" ) >> keymap.tmp
80 mv keymap.tmp keymap.h
83 .include <bsd.prog.mk>