From: zrj Date: Tue, 9 Aug 2016 14:29:49 +0000 (+0300) Subject: sys/boot: Unbreak WORLD_CCVER=gcc47 X-Git-Tag: v4.8.0rc~1214 X-Git-Url: https://gitweb.dragonflybsd.org/dragonfly.git/commitdiff_plain/1f1a42b5d57dc9e15f35c982f896ade90adcae1f sys/boot: Unbreak WORLD_CCVER=gcc47 Fix -Ox flags mess that exploded boot2_32 image size, by ensuring that intended -Ox flags were used were needed (gcc50 unaffected). There is still compilation issue for buildkernel w/ gcc47 but that -Werror=maybe-uninitialized on i915_gem_stolen.c can wait a bit. --- diff --git a/sys/boot/common/Makefile.inc b/sys/boot/common/Makefile.inc index 617bd0e55b..1c1f30acba 100644 --- a/sys/boot/common/Makefile.inc +++ b/sys/boot/common/Makefile.inc @@ -28,6 +28,4 @@ SRCS+= do_dloader.c MAN+= loader.8 -# Force -O, -O2 implodes -# -CFLAGS+= -O +WORLD_CCOPTLEVEL= 1 # Force -O1, -O2 implodes diff --git a/sys/boot/dloader/Makefile b/sys/boot/dloader/Makefile index a271c85265..687431b940 100644 --- a/sys/boot/dloader/Makefile +++ b/sys/boot/dloader/Makefile @@ -4,9 +4,7 @@ SRCS= subs.c config.c cmds.c -# Force -O, -O2 implodes -# -CFLAGS+= -O +WORLD_CCOPTLEVEL= 1 # Force -O1, -O2 implodes # For i386, dloader32/Makefile takes care of the extra CFLAGS .if ${MACHINE_ARCH} != "i386" diff --git a/sys/boot/libstand32/Makefile b/sys/boot/libstand32/Makefile index 2da20a3415..68871fa40f 100644 --- a/sys/boot/libstand32/Makefile +++ b/sys/boot/libstand32/Makefile @@ -8,8 +8,6 @@ LIB= stand32 MAN= .PATH: ${LIBSTAND_SRC} -# Force -O, -O2 implodes -# -CFLAGS+= -O +WORLD_CCOPTLEVEL= 1 # Force -O1, -O2 implodes .include "${LIBSTAND_SRC}/Makefile" diff --git a/sys/boot/pc32/Makefile.inc b/sys/boot/pc32/Makefile.inc index 1834a99f25..d71e15c7b8 100644 --- a/sys/boot/pc32/Makefile.inc +++ b/sys/boot/pc32/Makefile.inc @@ -4,9 +4,7 @@ __pc32__: LOADER_ADDRESS?= 0x200000 -# Force -O, -O2 implodes -# -CFLAGS+= -O +WORLD_CCOPTLEVEL= 1 # Force -O1, -O2 implodes CFLAGS+= -ffreestanding CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float diff --git a/sys/boot/pc32/boot2/Makefile b/sys/boot/pc32/boot2/Makefile index 1a2704d4a5..b5330da1a8 100644 --- a/sys/boot/pc32/boot2/Makefile +++ b/sys/boot/pc32/boot2/Makefile @@ -42,6 +42,7 @@ ORG1D = `${.OBJDIR}/bootasmdef.nx -d MEM_BIOS_LADDR` # ORG2= `${.OBJDIR}/bootasmdef.nx BOOT2_VORIGIN` +WOLRD_CCOPTLEVEL= s # -Os for size constraints in boot2_32 CFLAGS= -Os \ -fomit-frame-pointer \ -fno-unwind-tables \