diff options
author | Wolfgang Denk <wd@pollux.denx.de> | 2005-10-04 22:38:24 +0200 |
---|---|---|
committer | Wolfgang Denk <wd@pollux.denx.de> | 2005-10-04 22:38:24 +0200 |
commit | 1820d4c73b78ebe5d08921b0b6249c6f72e45215 (patch) | |
tree | a09e00683cd1636369c05556a94f14643a78f7e4 /config.mk | |
parent | 9a8d82fd3c7822effe3226f97f9ef1f643498c89 (diff) | |
download | u-boot-1820d4c73b78ebe5d08921b0b6249c6f72e45215.tar.gz u-boot-1820d4c73b78ebe5d08921b0b6249c6f72e45215.tar.xz u-boot-1820d4c73b78ebe5d08921b0b6249c6f72e45215.zip |
Make sure only supported compiler options are used
Import "cc-option" shell function from kernel and
use it to get the correct ARM GCC options for individual CPUs
Patch by Peter Pearse, 30 Jun 2005
Diffstat (limited to 'config.mk')
-rw-r--r-- | config.mk | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -86,6 +86,12 @@ HOSTCFLAGS = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer HOSTSTRIP = strip ######################################################################### +# +# Option checker (courtesy linux kernel) to ensure +# only supported compiler options are used +# +cc-option = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \ + > /dev/null 2>&1; then echo "$(1)"; else echo "$(2)"; fi ;) # # Include the make variables (CC, etc...) |