diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2011-05-02 21:13:08 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2011-05-02 21:13:08 +0000 |
commit | 3cd306b55544be48d0dc7eeaabe1a68efcc2a2f9 (patch) | |
tree | 1361e1fa6ee0c4b16ea2c22227f55e79b65e71ee /sys | |
parent | 565a81264871888990b5295766d2f76d99b09571 (diff) | |
download | src-3cd306b55544be48d0dc7eeaabe1a68efcc2a2f9.tar.gz src-3cd306b55544be48d0dc7eeaabe1a68efcc2a2f9.zip |
Clang r130700 can now compile sys/boot/i386/boot2 with room to spare.
Notes
Notes:
svn path=/head/; revision=221348
Diffstat (limited to 'sys')
-rw-r--r-- | sys/boot/i386/boot2/Makefile | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sys/boot/i386/boot2/Makefile b/sys/boot/i386/boot2/Makefile index 64d49ecd401f..6dc27d2dd410 100644 --- a/sys/boot/i386/boot2/Makefile +++ b/sys/boot/i386/boot2/Makefile @@ -2,9 +2,6 @@ .include <bsd.own.mk> -# XXX: clang can compile the boot code just fine, but boot2 gets too big -CC:=${CC:C/^(.*\/)?clang$/gcc/1} - FILES= boot boot1 boot2 NM?= nm @@ -45,6 +42,12 @@ CFLAGS= -Os \ -Wpointer-arith -Wshadow -Wstrict-prototypes -Wwrite-strings \ -Winline --param max-inline-insns-single=100 +.if ${CC:T:Mclang} == "clang" +CFLAGS+= -mllvm -stack-alignment=8 -mllvm -inline-threshold=3 +# XXX: clang integrated-as doesn't grok .codeNN directives yet +CFLAGS+= ${.IMPSRC:T:Mboot1.S:C/^.+$/-no-integrated-as/} +.endif + LDFLAGS=-static -N --gc-sections # Pick up ../Makefile.inc early. |