Changeset 5208
- Timestamp:
- Mar 14, 2010 10:25:03 PM (3 years ago)
- Location:
- trunk
- Files:
-
- 6 edited
-
. (modified) (1 prop)
-
Makefile (modified) (4 diffs)
-
src/Kconfig (modified) (1 diff)
-
src/arch/i386/Makefile.inc (modified) (1 diff)
-
src/cpu/x86/smm/Makefile.inc (modified) (1 diff)
-
util/abuild/abuild (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:ignore
-
old new 1 1 build 2 2 coreboot-builds 3 .ccwrap 3 4 .config 4 5 .config.old
-
- Property svn:ignore
-
trunk/Makefile
r5195 r5208 20 20 ## 21 21 22 ifeq ($(INNER_SCANBUILD),y) 23 CC_real:=$(CC) 24 endif 22 25 $(if $(wildcard .xcompile),,$(eval $(shell bash util/xcompile/xcompile > .xcompile))) 23 26 include .xcompile 27 ifeq ($(INNER_SCANBUILD),y) 28 CC:=$(CC_real) 29 HOSTCC:=$(CC_real) --hostcc 30 HOSTCXX:=$(CC_real) --hostcxx 31 endif 24 32 25 33 export top := $(PWD) … … 91 99 # other files 92 100 101 ifeq ($(INNER_SCANBUILD),y) 102 CONFIG_SCANBUILD_ENABLE:= 103 endif 104 105 ifeq ($(CONFIG_SCANBUILD_ENABLE),y) 106 ifneq ($(CONFIG_SCANBUILD_REPORT_LOCATION),) 107 CONFIG_SCANBUILD_REPORT_LOCATION:=-o $(CONFIG_SCANBUILD_REPORT_LOCATION) 108 endif 109 all: 110 echo '#!/bin/sh' > .ccwrap 111 echo 'CC="$(CC)"' >> .ccwrap 112 echo 'if [ "$$1" = "--hostcc" ]; then shift; CC="$(HOSTCC)"; fi' >> .ccwrap 113 echo 'if [ "$$1" = "--hostcxx" ]; then shift; CC="$(HOSTCXX)"; fi' >> .ccwrap 114 echo 'eval $$CC $$*' >> .ccwrap 115 chmod +x .ccwrap 116 scan-build $(CONFIG_SCANBUILD_REPORT_LOCATION) -analyze-headers --use-cc=$(top)/.ccwrap --use-c++=$(top)/.ccwrap $(MAKE) INNER_SCANBUILD=y 117 else 93 118 all: coreboot 119 endif 94 120 95 121 … … 111 137 112 138 $(obj)/mainboard/$(MAINBOARDDIR)/static.o: $(obj)/mainboard/$(MAINBOARDDIR)/static.c 113 # 139 @printf " CC $(subst $(obj)/,,$(@))\n" 140 $(CC) $(CFLAGS) -c -o $@ $< 141 142 $(obj)/arch/i386/../../option_table.o: $(obj)/arch/i386/../../option_table.c 143 @printf " CC $(subst $(obj)/,,$(@))\n" 144 $(CC) $(CFLAGS) -c -o $@ $< 114 145 115 146 objs:=$(obj)/mainboard/$(MAINBOARDDIR)/static.o … … 326 357 327 358 clean: clean-for-update 328 rm -f $(obj)/coreboot* 359 rm -f $(obj)/coreboot* .ccwrap 329 360 330 361 distclean: clean -
trunk/src/Kconfig
r5206 r5208 46 46 Select the prefix to all files put into the image. It's "fallback" 47 47 by default, "normal" is a common alternative. 48 49 config SCANBUILD_ENABLE 50 bool "build with scan-build for static analysis" 51 default n 52 help 53 Changes the build process to scan-build is used. 54 Requires scan-build in path. 55 56 config SCANBUILD_REPORT_LOCATION 57 string "directory to put scan-build report in" 58 default "" 59 depends on SCANBUILD_ENABLE 60 help 61 Where the scan-build report should be stored 48 62 49 63 endmenu -
trunk/src/arch/i386/Makefile.inc
r5206 r5208 61 61 $(obj)/coreboot_ram.o: $(obj)/arch/i386/lib/c_start.o $(drivers) $(obj)/coreboot.a $(LIBGCC_FILE_NAME) 62 62 @printf " CC $(subst $(obj)/,,$(@))\n" 63 $(CC) -nostdlib -r -o $@ $(obj)/arch/i386/lib/c_start.o $(drivers) -Wl,- \( $(obj)/coreboot.a $(LIBGCC_FILE_NAME) -Wl,-\)63 $(CC) -nostdlib -r -o $@ $(obj)/arch/i386/lib/c_start.o $(drivers) -Wl,--start-group $(obj)/coreboot.a $(LIBGCC_FILE_NAME) -Wl,--end-group 64 64 65 65 $(obj)/coreboot.a: $(objs) -
trunk/src/cpu/x86/smm/Makefile.inc
r5127 r5208 39 39 (echo 'unsigned char smm[] = {'; od -vtx1 $(obj)/cpu/x86/smm/smm | sed -e 's,^[0-9]* *,,' -e 's:[0-9a-f][0-9a-f] :0x&,:g' -e 's:[0-9a-f][0-9a-f]$$:0x&,:'; echo '}; unsigned int smm_len = '; wc -c $(obj)/cpu/x86/smm/smm |awk '{print $$1;}' ; echo ';') > $@ 40 40 41 $(obj)/cpu/x86/smm/smm_bin.o: $(obj)/cpu/x86/smm/smm_bin.c 42 @printf " CC $(subst $(obj)/,,$(@))\n" 43 $(CC) $(CFLAGS) -c -o $@ $< 44 41 45 endif 42 46 -
trunk/util/abuild/abuild
r5136 r5208 173 173 echo "CONFIG_DEFAULT_CONSOLE_LOGLEVEL_$loglevel=y" >> .config 174 174 echo "CONFIG_DEFAULT_CONSOLE_LOGLEVEL=$loglevel" >> .config 175 fi 176 177 if [ "$scanbuild" = "true" ]; then 178 printf "(scan-build enabled) " 179 echo "CONFIG_SCANBUILD_ENABLE=y" >> .config 180 echo "CONFIG_SCANBUILD_REPORT_LOCATION=\"$TARGET/scan-build-results-tmp\"" >> .config 175 181 fi 176 182 fi … … 363 369 if [ "$stackprotect" = "true" ]; then 364 370 CC="$CC -fno-stack-protector" 365 fi366 367 if [ "$scanbuild" = "true" ]; then368 ccwrap=`mktemp`369 mkdir -p $TARGET/${VENDOR}_${MAINBOARD}370 mkdir -p $TARGET/scan-build-results-tmp371 mv $ccwrap $TARGET/${VENDOR}_${MAINBOARD}372 ccwrap=$TARGET/${VENDOR}_${MAINBOARD}/`basename $ccwrap`373 echo '#!/bin/sh' > $ccwrap374 echo $CC' "$@"' >> $ccwrap375 chmod +x $ccwrap376 origMAKE=$MAKE377 MAKE="scan-build --use-cc=$ccwrap -o $TARGET/scan-build-results-tmp -analyze-headers $MAKE GCC=$ccwrap"378 CC="\$(CC)"379 HOSTCC="CCC_CC=$HOSTCC \$(CC)"380 371 fi 381 372
Note: See TracChangeset
for help on using the changeset viewer.
