1# $OpenBSD: Makefile,v 1.46 2016/09/01 09:21:08 tedu Exp $ 2 3# Makefile for kernel tags files, init_sysent, etc. 4 5ARCH= alpha amd64 armv7 \ 6 hppa i386 landisk loongson \ 7 luna88k macppc octeon sgi socppc \ 8 sparc64 zaurus 9 10all: 11 @echo "Doing nothing. Did you want make syscalls?" 12 13syscalls: init_sysent.c 14 15SYSCALLSRC = makesyscalls.sh syscalls.conf syscalls.master 16init_sysent.c syscalls.c ../sys/syscall.h ../sys/syscallargs.h: ${SYSCALLSRC} 17 sh makesyscalls.sh syscalls.conf syscalls.master 18 19# Kernel tags: 20# tags files are built in the top-level directory for each architecture. 21# Links to the correct tags file are placed in each source directory. 22# We need to have links to tags files 23# from the generic directories that are relative to the machine type, even 24# via remote mounts; therefore we use symlinks to $SYSTAGS, which points at 25# ${SYSDIR}/${MACHINE}/tags. 26 27SYSTAGS=/var/db/sys_tags 28SYSDIR=/sys 29 30# Directories in which to place tags links (other than machine-dependent) 31DGEN= conf \ 32 ddb \ 33 dev dev/eisa dev/ic dev/isa dev/pci dev/pcmcia dev/cardbus \ 34 dev/sun dev/tc \ 35 isofs isofs/cd9660 \ 36 kern \ 37 lib/libkern lib/libkern/arch/${MACHINE} \ 38 lib/libkern/arch/${MACHINE_ARCH} \ 39 miscfs miscfs/deadfs miscfs/fifofs \ 40 msdosfs \ 41 net netinet netmpls \ 42 nfs \ 43 scsi \ 44 sys \ 45 ufs ufs/ffs ufs/mfs ufs/ufs \ 46 uvm 47 48tags:: 49 -for i in ${ARCH}; do \ 50 (cd ../arch/$$i && make ${MFLAGS} tags); done 51 52links:: 53 rm -f ${SYSTAGS} 54 ln -s ${SYSDIR}/arch/${MACHINE}/tags ${SYSTAGS} 55 -for i in ${DGEN}; do \ 56 (cd ../$$i && { rm -f tags; ln -s ${SYSTAGS} tags; }) done 57 -for i in ${ARCH}; do \ 58 (cd ../arch/$$i && make ${MFLAGS} SYSTAGS=${SYSTAGS} links); done 59