summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2003-05-13 22:45:12 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2003-05-13 22:45:12 +0000
commit0813bddc089dc1133696d2a9692366523cfa4015 (patch)
tree243d3845592d5261188bcdf116f9979bdc311805
parentd4d555e924e183fd9573e15c39d88d4bdd146f4d (diff)
Add option NO_PROPOLICE, which explicitely disables the use of the propolice
stack protection when building kernels. Intended to be used on installation media, with tight space constraints - currently, only added where SMALL_KERNEL was already defined. Not thoroughly tested, but requested by deraadt.
-rw-r--r--sys/arch/alpha/conf/Makefile.alpha5
-rw-r--r--sys/arch/alpha/conf/RAMDISK3
-rw-r--r--sys/arch/alpha/conf/RAMDISKB3
-rw-r--r--sys/arch/hp300/conf/Makefile.hp3005
-rw-r--r--sys/arch/i386/conf/Makefile.i3865
-rw-r--r--sys/arch/i386/conf/RAMDISK3
-rw-r--r--sys/arch/i386/conf/RAMDISKB3
-rw-r--r--sys/arch/i386/conf/RAMDISKC3
-rw-r--r--sys/arch/mac68k/conf/Makefile.mac68k5
-rw-r--r--sys/arch/mac68k/conf/RAMDISK3
-rw-r--r--sys/arch/mac68k/conf/RAMDISKSBC3
-rw-r--r--sys/arch/macppc/conf/Makefile.macppc5
-rw-r--r--sys/arch/mvme68k/conf/Makefile.mvme68k5
-rw-r--r--sys/arch/mvme68k/conf/RAMDISK3
-rw-r--r--sys/arch/mvme88k/conf/Makefile.mvme88k5
-rw-r--r--sys/arch/mvmeppc/conf/Makefile.mvmeppc5
-rw-r--r--sys/arch/sparc/conf/Makefile.sparc5
-rw-r--r--sys/arch/sparc/conf/RAMDISK3
-rw-r--r--sys/arch/sparc64/conf/Makefile.sparc643
-rw-r--r--sys/arch/sparc64/conf/RAMDISK3
-rw-r--r--sys/arch/sparc64/conf/RAMDISKU13
-rw-r--r--sys/arch/sparc64/conf/RAMDISKU53
-rw-r--r--sys/arch/vax/conf/Makefile.vax5
-rw-r--r--sys/kern/init_main.c8
-rw-r--r--sys/kern/kern_xxx.c5
25 files changed, 77 insertions, 25 deletions
diff --git a/sys/arch/alpha/conf/Makefile.alpha b/sys/arch/alpha/conf/Makefile.alpha
index 8c0096726cd..9e969b25857 100644
--- a/sys/arch/alpha/conf/Makefile.alpha
+++ b/sys/arch/alpha/conf/Makefile.alpha
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.alpha,v 1.28 2003/05/13 06:12:43 tedu Exp $
+# $OpenBSD: Makefile.alpha,v 1.29 2003/05/13 22:45:06 miod Exp $
# $NetBSD: Makefile.alpha,v 1.27 1996/12/01 06:12:25 jonathan Exp $
# Makefile for OpenBSD
@@ -35,6 +35,9 @@ CDIAGFLAGS?= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
-Wno-uninitialized -Wno-format -Wno-main
CMACHFLAGS= -mno-fp-regs
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
COPTS?= -O2
CFLAGS= ${DEBUG} ${CDIAGFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE}
AFLAGS= -traditional -D_LOCORE
diff --git a/sys/arch/alpha/conf/RAMDISK b/sys/arch/alpha/conf/RAMDISK
index b0702796c91..9884efb7969 100644
--- a/sys/arch/alpha/conf/RAMDISK
+++ b/sys/arch/alpha/conf/RAMDISK
@@ -1,9 +1,10 @@
-# $OpenBSD: RAMDISK,v 1.58 2002/06/30 16:24:40 miod Exp $
+# $OpenBSD: RAMDISK,v 1.59 2003/05/13 22:45:06 miod Exp $
# $NetBSD: RAMDISK,v 1.9 1996/12/03 17:25:33 cgd Exp $
machine alpha # architecture, used by config; REQUIRED
option SMALL_KERNEL
+option NO_PROPOLICE
# CPU Support; at least one is REQUIRED
#option DEC_3000_500 # Flamingo etc: 3000/[4-9]00*
diff --git a/sys/arch/alpha/conf/RAMDISKB b/sys/arch/alpha/conf/RAMDISKB
index 7596bba6aa0..1741340de60 100644
--- a/sys/arch/alpha/conf/RAMDISKB
+++ b/sys/arch/alpha/conf/RAMDISKB
@@ -1,9 +1,10 @@
-# $OpenBSD: RAMDISKB,v 1.21 2002/06/30 16:24:40 miod Exp $
+# $OpenBSD: RAMDISKB,v 1.22 2003/05/13 22:45:06 miod Exp $
# $NetBSD: RAMDISK,v 1.9 1996/12/03 17:25:33 cgd Exp $
machine alpha # architecture, used by config; REQUIRED
option SMALL_KERNEL
+option NO_PROPOLICE
# CPU Support; at least one is REQUIRED
#option DEC_3000_500 # Flamingo etc: 3000/[4-9]00*
diff --git a/sys/arch/hp300/conf/Makefile.hp300 b/sys/arch/hp300/conf/Makefile.hp300
index d3487f3490c..f329c738c49 100644
--- a/sys/arch/hp300/conf/Makefile.hp300
+++ b/sys/arch/hp300/conf/Makefile.hp300
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.hp300,v 1.31 2003/05/13 06:12:43 tedu Exp $
+# $OpenBSD: Makefile.hp300,v 1.32 2003/05/13 22:45:10 miod Exp $
# $NetBSD: Makefile.hp300,v 1.54 1997/04/01 23:16:41 scottr Exp $
# Makefile for OpenBSD
@@ -41,6 +41,9 @@ CPPFLAGS= ${INCLUDES} ${IDENT} ${PARAM} -D_KERNEL \
CWARNFLAGS= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
-Wno-uninitialized -Wno-format -Wno-main
CMACHFLAGS= -msoft-float
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
COPTS?= -O2
CFLAGS= ${DEBUG} ${COPTS} ${CWARNFLAGS} ${CMACHFLAGS} ${PIPE}
AFLAGS= -x assembler-with-cpp -traditional-cpp -D_LOCORE
diff --git a/sys/arch/i386/conf/Makefile.i386 b/sys/arch/i386/conf/Makefile.i386
index 0321b5a69f5..0c659a5d96a 100644
--- a/sys/arch/i386/conf/Makefile.i386
+++ b/sys/arch/i386/conf/Makefile.i386
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.i386,v 1.35 2003/05/13 06:12:43 tedu Exp $
+# $OpenBSD: Makefile.i386,v 1.36 2003/05/13 22:45:10 miod Exp $
# $NetBSD: Makefile.i386,v 1.67 1996/05/11 16:12:11 mycroft Exp $
# Makefile for OpenBSD
@@ -44,6 +44,9 @@ CMACHFLAGS= -march=i486
.else
CMACHFLAGS=
.endif
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
COPTS?= -O2
CFLAGS= ${DEBUG} ${CDIAGFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE}
diff --git a/sys/arch/i386/conf/RAMDISK b/sys/arch/i386/conf/RAMDISK
index 18d9a4bd5af..72bb89f34cc 100644
--- a/sys/arch/i386/conf/RAMDISK
+++ b/sys/arch/i386/conf/RAMDISK
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISK,v 1.116 2002/12/02 09:00:54 deraadt Exp $
+# $OpenBSD: RAMDISK,v 1.117 2003/05/13 22:45:10 miod Exp $
machine i386 # architecture, used by config; REQUIRED
@@ -12,6 +12,7 @@ option I686_CPU
option GPL_MATH_EMULATE # floating point emulation
option SMALL_KERNEL
+option NO_PROPOLICE
#option DUMMY_NOPS # speed hack; recommended
diff --git a/sys/arch/i386/conf/RAMDISKB b/sys/arch/i386/conf/RAMDISKB
index f357e070f6b..f34458d704b 100644
--- a/sys/arch/i386/conf/RAMDISKB
+++ b/sys/arch/i386/conf/RAMDISKB
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISKB,v 1.57 2003/01/12 18:05:01 deraadt Exp $
+# $OpenBSD: RAMDISKB,v 1.58 2003/05/13 22:45:10 miod Exp $
machine i386 # architecture, used by config; REQUIRED
@@ -12,6 +12,7 @@ option I686_CPU
option GPL_MATH_EMULATE # floating point emulation
option SMALL_KERNEL
+option NO_PROPOLICE
#option DUMMY_NOPS # speed hack; recommended
diff --git a/sys/arch/i386/conf/RAMDISKC b/sys/arch/i386/conf/RAMDISKC
index f12fe3b6fdd..c83b0cb5fd7 100644
--- a/sys/arch/i386/conf/RAMDISKC
+++ b/sys/arch/i386/conf/RAMDISKC
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISKC,v 1.29 2002/09/03 16:43:13 mickey Exp $
+# $OpenBSD: RAMDISKC,v 1.30 2003/05/13 22:45:10 miod Exp $
machine i386 # architecture, used by config; REQUIRED
@@ -12,6 +12,7 @@ option I686_CPU
option GPL_MATH_EMULATE # floating point emulation
option SMALL_KERNEL
+option NO_PROPOLICE
#option DUMMY_NOPS # speed hack; recommended
diff --git a/sys/arch/mac68k/conf/Makefile.mac68k b/sys/arch/mac68k/conf/Makefile.mac68k
index c3ccb0d7084..698e11f74ee 100644
--- a/sys/arch/mac68k/conf/Makefile.mac68k
+++ b/sys/arch/mac68k/conf/Makefile.mac68k
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.mac68k,v 1.30 2003/05/13 06:12:43 tedu Exp $
+# $OpenBSD: Makefile.mac68k,v 1.31 2003/05/13 22:45:10 miod Exp $
# $NetBSD: Makefile.mac68k,v 1.53 1997/04/15 06:11:38 scottr Exp $
# Makefile for OpenBSD
@@ -41,6 +41,9 @@ CPPFLAGS= ${INCLUDES} ${IDENT} ${PARAM} -D_KERNEL \
CWARNFLAGS= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
-Wno-uninitialized -Wno-format -Wno-main
CMACHFLAGS= -msoft-float
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
COPTS?= -O2
CFLAGS= ${DEBUG} ${COPTS} ${CWARNFLAGS} ${CMACHFLAGS} ${PIPE}
AFLAGS= -x assembler-with-cpp -traditional-cpp -D_LOCORE
diff --git a/sys/arch/mac68k/conf/RAMDISK b/sys/arch/mac68k/conf/RAMDISK
index d51f2646108..ef232619480 100644
--- a/sys/arch/mac68k/conf/RAMDISK
+++ b/sys/arch/mac68k/conf/RAMDISK
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISK,v 1.11 2003/05/05 13:59:38 miod Exp $
+# $OpenBSD: RAMDISK,v 1.12 2003/05/13 22:45:10 miod Exp $
#
# RAMDISK - bsd.rd configuration file (non-SBC version)
@@ -10,6 +10,7 @@ option RAMDISK_HOOKS
option SCSITERSE
option SMALL_KERNEL
+option NO_PROPOLICE
option TIMEZONE=0
option DST=0
option FFS # UFS
diff --git a/sys/arch/mac68k/conf/RAMDISKSBC b/sys/arch/mac68k/conf/RAMDISKSBC
index 01cdd0f9076..0ebdd89ef4e 100644
--- a/sys/arch/mac68k/conf/RAMDISKSBC
+++ b/sys/arch/mac68k/conf/RAMDISKSBC
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISKSBC,v 1.2 2003/05/05 13:59:38 miod Exp $
+# $OpenBSD: RAMDISKSBC,v 1.3 2003/05/13 22:45:10 miod Exp $
#
# RAMDISKSBC - bsd.rd configuration file (SBC version)
@@ -10,6 +10,7 @@ option RAMDISK_HOOKS
option SCSITERSE
option SMALL_KERNEL
+option NO_PROPOLICE
option TIMEZONE=0
option DST=0
option FFS # UFS
diff --git a/sys/arch/macppc/conf/Makefile.macppc b/sys/arch/macppc/conf/Makefile.macppc
index ad9dbd10b06..d8f9a99f177 100644
--- a/sys/arch/macppc/conf/Makefile.macppc
+++ b/sys/arch/macppc/conf/Makefile.macppc
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.macppc,v 1.12 2003/05/13 06:12:43 tedu Exp $
+# $OpenBSD: Makefile.macppc,v 1.13 2003/05/13 22:45:10 miod Exp $
#
# Makefile for OpenBSD PowerPC
#
@@ -41,6 +41,9 @@ CPPFLAGS= ${INCLUDES} ${IDENT} -D_KERNEL \
CWARNFLAGS= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
-Wno-uninitialized -Wno-format -Wno-main
CMACHFLAGS= -msoft-float -Wa,-m7400
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
COPTS?= -O2
CFLAGS= ${DEBUG} ${CWARNFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE}
AFLAGS= -D_LOCORE
diff --git a/sys/arch/mvme68k/conf/Makefile.mvme68k b/sys/arch/mvme68k/conf/Makefile.mvme68k
index 413fe78a888..abda7ba1f02 100644
--- a/sys/arch/mvme68k/conf/Makefile.mvme68k
+++ b/sys/arch/mvme68k/conf/Makefile.mvme68k
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.mvme68k,v 1.20 2003/05/13 06:12:43 tedu Exp $
+# $OpenBSD: Makefile.mvme68k,v 1.21 2003/05/13 22:45:10 miod Exp $
# This makefile is constructed from a machine description:
# config machineid
@@ -44,6 +44,9 @@ CMACHFLAGS= -m68020
CMACHFLAGS= -m68060 -Wa,-m68030
.endif
CMACHFLAGS+= -msoft-float
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
COPTS?= -O2
CFLAGS= ${DEBUG} ${COPTS} ${CWARNFLAGS} ${CMACHFLAGS} ${PIPE}
diff --git a/sys/arch/mvme68k/conf/RAMDISK b/sys/arch/mvme68k/conf/RAMDISK
index 0f6b464ffc8..423bfe49364 100644
--- a/sys/arch/mvme68k/conf/RAMDISK
+++ b/sys/arch/mvme68k/conf/RAMDISK
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISK,v 1.2 2002/04/28 14:47:09 miod Exp $
+# $OpenBSD: RAMDISK,v 1.3 2003/05/13 22:45:10 miod Exp $
machine mvme68k m68k
@@ -23,6 +23,7 @@ maxusers 32
option SCSITERSE
option SMALL_KERNEL
+option NO_PROPOLICE
option TIMEZONE=0 # time zone to adjust RTC time by
option DST=0 # daylight saving time used by RTC
#makeoptions DEBUG="-g" # compile full symbol table
diff --git a/sys/arch/mvme88k/conf/Makefile.mvme88k b/sys/arch/mvme88k/conf/Makefile.mvme88k
index 90a03dd42e9..a9e34cf2b79 100644
--- a/sys/arch/mvme88k/conf/Makefile.mvme88k
+++ b/sys/arch/mvme88k/conf/Makefile.mvme88k
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.mvme88k,v 1.24 2003/05/13 06:12:43 tedu Exp $
+# $OpenBSD: Makefile.mvme88k,v 1.25 2003/05/13 22:45:10 miod Exp $
#
# Makefile for OpenBSD
#
@@ -37,6 +37,9 @@ INCLUDES= -nostdinc -I. -I$S/arch -I$S
CPPFLAGS= ${INCLUDES} ${IDENT} ${PARAM} -D_KERNEL -Dmvme88k -Dm88k
CWARNFLAGS= -Wall -Werror -Wmissing-prototypes \
-Wno-uninitialized -Wno-format -Wno-main -Wstrict-prototypes
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
COPTS?= -O
CFLAGS= ${DEBUG} ${CWARNFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE}
AFLAGS= -x assembler-with-cpp -traditional-cpp -D_LOCORE ${CMACHFLAGS}
diff --git a/sys/arch/mvmeppc/conf/Makefile.mvmeppc b/sys/arch/mvmeppc/conf/Makefile.mvmeppc
index ea7d63d7ad3..a8ab50925f7 100644
--- a/sys/arch/mvmeppc/conf/Makefile.mvmeppc
+++ b/sys/arch/mvmeppc/conf/Makefile.mvmeppc
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.mvmeppc,v 1.12 2003/05/13 06:12:44 tedu Exp $
+# $OpenBSD: Makefile.mvmeppc,v 1.13 2003/05/13 22:45:11 miod Exp $
#
# Makefile for OpenBSD PowerPC
#
@@ -41,6 +41,9 @@ CPPFLAGS= ${INCLUDES} ${IDENT} -D_KERNEL \
CWARNFLAGS= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
-Wno-uninitialized -Wno-format -Wno-main
CMACHFLAGS= -msoft-float -Wa,-m7400
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
COPTS?= -O2
CFLAGS= ${DEBUG} ${CWARNFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE}
AFLAGS= -D_LOCORE
diff --git a/sys/arch/sparc/conf/Makefile.sparc b/sys/arch/sparc/conf/Makefile.sparc
index 2dd476952a5..33328bfaced 100644
--- a/sys/arch/sparc/conf/Makefile.sparc
+++ b/sys/arch/sparc/conf/Makefile.sparc
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.sparc,v 1.29 2003/05/13 06:12:44 tedu Exp $
+# $OpenBSD: Makefile.sparc,v 1.30 2003/05/13 22:45:11 miod Exp $
# $NetBSD: Makefile.sparc,v 1.32.4.1 1996/06/12 20:26:32 pk Exp $
# Makefile for OpenBSD
@@ -45,6 +45,9 @@ CMACHFLAGS= -mcpu=supersparc
.else
CMACHFLAGS=
.endif
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
CFLAGS= ${DEBUG} -O2 ${CDIAGFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE}
# add `-mno-fpu' to work around gcc (last noticed in v2.7.2) bug
diff --git a/sys/arch/sparc/conf/RAMDISK b/sys/arch/sparc/conf/RAMDISK
index 6989de60626..3d50b4ceb6d 100644
--- a/sys/arch/sparc/conf/RAMDISK
+++ b/sys/arch/sparc/conf/RAMDISK
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISK,v 1.40 2003/05/13 17:24:10 miod Exp $
+# $OpenBSD: RAMDISK,v 1.41 2003/05/13 22:45:11 miod Exp $
# $NetBSD: GENERIC,v 1.28.2.1 1996/07/02 23:55:22 jtc Exp $
# Machine architecture; required by config(8)
@@ -17,6 +17,7 @@ option TIMEZONE=0 # time zone to adjust RTC time by
option DST=0 # daylight saving time used by RTC
option SMALL_KERNEL
+option NO_PROPOLICE
option DIAGNOSTIC # internal consistency checks
option FFS # UFS
#option NFSCLIENT # Network File System client
diff --git a/sys/arch/sparc64/conf/Makefile.sparc64 b/sys/arch/sparc64/conf/Makefile.sparc64
index 5a2f723a14e..2b0fa99ec51 100644
--- a/sys/arch/sparc64/conf/Makefile.sparc64
+++ b/sys/arch/sparc64/conf/Makefile.sparc64
@@ -19,6 +19,9 @@ CDIAGFLAGS= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
-Wno-uninitialized -Wno-format -Wno-main
CMACHFLAGS= -Wa,-Av9a, -mno-fpu
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
CFLAGS= ${DEBUG} -O2 ${CDIAGFLAGS} ${CMACHFLAGS} ${COPTS} ${PIPE}
AFLAGS= -x assembler-with-cpp -traditional-cpp -D_LOCORE -Wa,-Av9a
diff --git a/sys/arch/sparc64/conf/RAMDISK b/sys/arch/sparc64/conf/RAMDISK
index e0658951d90..3eeaa290fcb 100644
--- a/sys/arch/sparc64/conf/RAMDISK
+++ b/sys/arch/sparc64/conf/RAMDISK
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISK,v 1.21 2003/02/12 20:54:45 jason Exp $
+# $OpenBSD: RAMDISK,v 1.22 2003/05/13 22:45:11 miod Exp $
# Machine architecture; required by config(8)
machine sparc64
@@ -18,6 +18,7 @@ option TIMEZONE=0 # time zone to adjust RTC time by
option DST=0 # daylight saving time used by RTC
option SMALL_KERNEL
+option NO_PROPOLICE
option DIAGNOSTIC # internal consistency checks
option FFS # UFS
option NFSCLIENT # Network File System client
diff --git a/sys/arch/sparc64/conf/RAMDISKU1 b/sys/arch/sparc64/conf/RAMDISKU1
index 028b9711020..c57d0a9fced 100644
--- a/sys/arch/sparc64/conf/RAMDISKU1
+++ b/sys/arch/sparc64/conf/RAMDISKU1
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISKU1,v 1.3 2001/10/10 04:24:12 deraadt Exp $
+# $OpenBSD: RAMDISKU1,v 1.4 2003/05/13 22:45:11 miod Exp $
# Machine architecture; required by config(8)
machine sparc64
@@ -18,6 +18,7 @@ option TIMEZONE=0 # time zone to adjust RTC time by
option DST=0 # daylight saving time used by RTC
option SMALL_KERNEL
+option NO_PROPOLICE
#option DIAGNOSTIC # internal consistency checks
option FFS # UFS
#option NFSCLIENT # Network File System client
diff --git a/sys/arch/sparc64/conf/RAMDISKU5 b/sys/arch/sparc64/conf/RAMDISKU5
index 1410d27a397..425fcf0f5f5 100644
--- a/sys/arch/sparc64/conf/RAMDISKU5
+++ b/sys/arch/sparc64/conf/RAMDISKU5
@@ -1,4 +1,4 @@
-# $OpenBSD: RAMDISKU5,v 1.3 2001/10/15 18:44:56 jason Exp $
+# $OpenBSD: RAMDISKU5,v 1.4 2003/05/13 22:45:11 miod Exp $
# Machine architecture; required by config(8)
machine sparc64
@@ -18,6 +18,7 @@ option TIMEZONE=0 # time zone to adjust RTC time by
option DST=0 # daylight saving time used by RTC
option SMALL_KERNEL
+option NO_PROPOLICE
#option DIAGNOSTIC # internal consistency checks
option FFS # UFS
#option NFSCLIENT # Network File System client
diff --git a/sys/arch/vax/conf/Makefile.vax b/sys/arch/vax/conf/Makefile.vax
index 6a7a5e891e2..55a23f35bf0 100644
--- a/sys/arch/vax/conf/Makefile.vax
+++ b/sys/arch/vax/conf/Makefile.vax
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile.vax,v 1.22 2003/05/13 06:12:44 tedu Exp $
+# $OpenBSD: Makefile.vax,v 1.23 2003/05/13 22:45:11 miod Exp $
# $NetBSD: Makefile.vax,v 1.49 1999/07/26 05:20:49 cgd Exp $
# Makefile for OpenBSD/vax
@@ -66,6 +66,9 @@ INCLUDES= -I. -I$S/arch -I$S -nostdinc
CPPFLAGS= ${INCLUDES} ${IDENT} ${PARAM} -D_KERNEL \
-D_VAX_INLINE_
CWARNFLAGS?= -Werror -Wall -Wno-main -Wno-format -Wno-uninitialized
+.if ${IDENT:M-DNO_PROPOLICE}
+CMACHFLAGS+= -fno-stack-protector
+.endif
CFLAGS= ${DEBUG} ${COPTS} ${CWARNFLAGS} ${CMACHFLAGS} ${PIPE}
AFLAGS= -x assembler-with-cpp -traditional-cpp -D_LOCORE
LINKFLAGS= -N -Ttext 80000000 -e start
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c
index 6124b421e33..cdd9d4f0917 100644
--- a/sys/kern/init_main.c
+++ b/sys/kern/init_main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: init_main.c,v 1.103 2003/05/13 06:11:11 tedu Exp $ */
+/* $OpenBSD: init_main.c,v 1.104 2003/05/13 22:45:11 miod Exp $ */
/* $NetBSD: init_main.c,v 1.84.4.1 1996/06/02 09:08:06 mrg Exp $ */
/*
@@ -127,7 +127,9 @@ int boothowto;
struct timeval boottime;
struct timeval runtime;
+#if !defined(NO_PROPOLICE)
long __guard[8];
+#endif
/* XXX return int so gcc -Werror won't complain */
int main(void *);
@@ -180,7 +182,9 @@ main(framep)
quad_t lim;
int s, i;
register_t rval[2];
+#if !defined(NO_PROPOLICE)
int *guard = (int *)&__guard[0];
+#endif
extern struct pdevinit pdevinit[];
extern void scheduler_start(void);
extern void disk_init(void);
@@ -368,8 +372,10 @@ main(framep)
kmstartup();
#endif
+#if !defined(NO_PROPOLICE)
for (i = 0; i < sizeof(__guard) / 4; i++)
guard[i] = arc4random();
+#endif
/* Start the scheduler */
scheduler_start();
diff --git a/sys/kern/kern_xxx.c b/sys/kern/kern_xxx.c
index 0988b29c726..ff09dc8de82 100644
--- a/sys/kern/kern_xxx.c
+++ b/sys/kern/kern_xxx.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kern_xxx.c,v 1.6 2003/05/13 06:11:11 tedu Exp $ */
+/* $OpenBSD: kern_xxx.c,v 1.7 2003/05/13 22:45:11 miod Exp $ */
/* $NetBSD: kern_xxx.c,v 1.32 1996/04/22 01:38:41 christos Exp $ */
/*
@@ -64,6 +64,7 @@ sys_reboot(p, v, retval)
return (0);
}
+#if !defined(NO_PROPOLICE)
void __stack_smash_handler(char [], int __attribute__((unused)));
void
@@ -71,7 +72,7 @@ __stack_smash_handler(char func[], int damaged)
{
panic("smashed stack in %s", func);
}
-
+#endif
#ifdef SYSCALL_DEBUG
#define SCDEBUG_CALLS 0x0001 /* show calls */