summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPatrick Georgi <patrick.georgi@coresystems.de>2010-03-25 21:45:25 +0000
committerPatrick Georgi <patrick.georgi@coresystems.de>2010-03-25 21:45:25 +0000
commit516a2a7bfaee5d4aa4d1e7e5ff52d3038513c82f (patch)
tree5dc3dcc6d27c286af863850e2c88b796583ffe08 /src
parent0ab9d12e290ab79786d34fdf12c99922f5255aff (diff)
downloadcoreboot-516a2a7bfaee5d4aa4d1e7e5ff52d3038513c82f.tar.xz
Add support to build with ccache in the build system
Signed-off-by: Patrick Georgi <patrick.georgi@coresystems.de> Acked-by: Stefan Reinauer <stepan@coresystems.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@5297 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src')
-rw-r--r--src/Kconfig8
-rw-r--r--src/arch/i386/Makefile.bootblock.inc2
-rw-r--r--src/arch/i386/Makefile.inc2
3 files changed, 10 insertions, 2 deletions
diff --git a/src/Kconfig b/src/Kconfig
index 5da2973d07..d9c46076ae 100644
--- a/src/Kconfig
+++ b/src/Kconfig
@@ -62,6 +62,7 @@ endchoice
config SCANBUILD_ENABLE
bool "Build with scan-build for static analysis"
default n
+ depends on !CCACHE
help
Changes the build process to scan-build is used.
Requires scan-build in path.
@@ -73,6 +74,13 @@ config SCANBUILD_REPORT_LOCATION
help
Where the scan-build report should be stored
+config CCACHE
+ bool "ccache"
+ default n
+ help
+ Enables the use of ccache for faster builds.
+ Requires ccache in path.
+
endmenu
source src/mainboard/Kconfig
diff --git a/src/arch/i386/Makefile.bootblock.inc b/src/arch/i386/Makefile.bootblock.inc
index 365ef35fd1..e767f30458 100644
--- a/src/arch/i386/Makefile.bootblock.inc
+++ b/src/arch/i386/Makefile.bootblock.inc
@@ -71,7 +71,7 @@ $(obj)/mainboard/$(MAINBOARDDIR)/bootblock.inc: $(src)/arch/i386/init/$(subst ",
@printf " ROMCC $(subst $(obj)/,,$(@))\n"
$(CC) -MM -MT$(obj)/mainboard/$(MAINBOARDDIR)/bootblock.inc \
$< > $(obj)/mainboard/$(MAINBOARDDIR)/bootblock.inc.d
- $(obj)/romcc $(bootblock_romccflags) $(ROMCCFLAGS) $(INCLUDES) $< -o $@
+ $(ROMCC) -c -S $(bootblock_romccflags) $(ROMCCFLAGS) -I. $(INCLUDES) $< -o $@
$(obj)/bootblock.elf: $(obj)/mainboard/$(MAINBOARDDIR)/bootblock.o $(obj)/bootblock/ldscript.ld
@printf " LINK $(subst $(obj)/,,$(@))\n"
diff --git a/src/arch/i386/Makefile.inc b/src/arch/i386/Makefile.inc
index e09a70cda7..02fafba086 100644
--- a/src/arch/i386/Makefile.inc
+++ b/src/arch/i386/Makefile.inc
@@ -195,7 +195,7 @@ ROMCCFLAGS ?= -mcpu=p2 -O2
$(obj)/mainboard/$(MAINBOARDDIR)/romstage.inc: $(src)/mainboard/$(MAINBOARDDIR)/romstage.c $(obj)/romcc $(OPTION_TABLE_H) $(obj)/build.h
printf " ROMCC romstage.inc\n"
- $(obj)/romcc $(ROMCCFLAGS) -include $(obj)/build.h $(INCLUDES) $< -o $@
+ $(ROMCC) -c -S $(ROMCCFLAGS) -include $(obj)/build.h -I. $(INCLUDES) $< -o $@
else