diff options
-rw-r--r-- | regress/sys/arch/i386/ldt/Makefile | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/regress/sys/arch/i386/ldt/Makefile b/regress/sys/arch/i386/ldt/Makefile index 6d98c5a12f1..96990013340 100644 --- a/regress/sys/arch/i386/ldt/Makefile +++ b/regress/sys/arch/i386/ldt/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.5 2004/03/02 07:07:34 david Exp $ +# $OpenBSD: Makefile,v 1.6 2004/06/21 18:05:09 david Exp $ # $NetBSD: Makefile,v 1.3 1995/04/20 22:42:19 cgd Exp $ # # C Optimizer (-O) breaks this program - don't use !! @@ -8,11 +8,26 @@ PROG= testldt DPADD+= ${LIBARCH} LDADD+= -li386 -USERLDT!=sysctl -n machdep.userldt +USERLDT_ENABLE!=sysctl -n machdep.userldt -.if ${MACHINE_ARCH} != "i386" || $(USERLDT) == 0 +.ifmake !obj && !clean && !cleandir && !depend && !regress +.INTERRUPT: + -@${SUDO} sysctl -q machdep.userldt=${USERLDT_ENABLE} + +.END: + -@${SUDO} sysctl -q machdep.userldt=${USERLDT_ENABLE} +.endif + +.if ${MACHINE_ARCH} != "i386" REGRESS_SKIP="yes" .endif +do-testldt: ${PROG} + @${SUDO} sysctl -q machdep.userldt=1 + ./${PROG} + +REGRESS_TARGETS=do-testldt +.PHONY: ${REGRESS_TARGETS} + .include <bsd.regress.mk> |