summaryrefslogtreecommitdiffstats
path: root/sys/modules/svr4/Makefile
blob: 0b8d774f0df46b44768d2840be6561596c542da9 (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
45
46
# $FreeBSD$

MAINTAINER=	newton@FreeBSD.org

TARGET_ARCH?=	${MACHINE_ARCH}

.PATH:	${.CURDIR}/../../${TARGET_ARCH}/svr4 ${.CURDIR}/../../svr4
KMOD=	svr4
SRCS=	svr4_sysent.c svr4_sysvec.c opt_compat.h opt_svr4.h opt_vmpage.h \
	vnode_if.h imgact_svr4.c svr4_signal.c svr4_fcntl.c svr4_misc.c \
	svr4_ioctl.c svr4_stat.c svr4_filio.c svr4_ttold.c svr4_termios.c \
	svr4_stream.c svr4_socket.c svr4_sockio.c svr4_machdep.c \
	svr4_resource.c svr4_ipc.c
OBJS=	svr4_locore.o 
MAN8=	svr4.8

EXPORT_SYMS=_svr4_mod
CLEANFILES= svr4_assym.h svr4_genassym.o

svr4_assym.h:	svr4_genassym.o
.if exists(@)
svr4_assym.h:	@/kern/genassym.sh
.endif
	sh @/kern/genassym.sh svr4_genassym.o > ${.TARGET}

svr4_locore.o:	svr4_locore.s svr4_assym.h
	${CC} -c -x assembler-with-cpp -DLOCORE ${CFLAGS} \
		${.IMPSRC} -o ${.TARGET}

svr4_genassym.o:	svr4_genassym.c svr4.h @ machine
	${CC} -c ${CFLAGS} ${.IMPSRC}

opt_compat.h:
	echo "#define COMPAT_43 1" > opt_compat.h

opt_svr4.h:
	touch opt_svr4.h
.if defined(DEBUG)
	echo "#define DEBUG_SVR4 1" >> opt_svr4.h
.endif

afterinstall:
	${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
		${.CURDIR}/svr4.sh ${DESTDIR}/usr/sbin/svr4

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