|
@@ -123,10 +123,11 @@ MKTAGS=ctags -R .
|
|
|
|
|
|
ifneq (,$(findstring gcc, $(CC_LONGVER)))
|
|
|
CC_NAME=gcc
|
|
|
- CC_VER=$(CC) $(shell $(CC) --version)
|
|
|
+ CC_VER=$(CC) $(shell $(CC) --version|head -1| \
|
|
|
+ sed -e 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/')
|
|
|
MKDEP=$(CC) -MM $(DEFS)
|
|
|
#transform gcc version into 2.9x or 3.0
|
|
|
- CC_SHORTVER=$(shell $(CC) --version | \
|
|
|
+ CC_SHORTVER=$(shell echo $(CC_VER) | cut -d" " -f 2| \
|
|
|
sed -e 's/[^0-9]*-\(.*\)/\1/'| \
|
|
|
sed -e 's/2\.9.*/2.9x/' -e 's/3\..\..*/3.0/')
|
|
|
endif
|
|
@@ -190,7 +191,7 @@ ifeq ($(CC_NAME), gcc)
|
|
|
#if gcc 3.0
|
|
|
ifeq ($(CC_SHORTVER), 3.0)
|
|
|
CFLAGS+=-minline-all-stringops -malign-double \
|
|
|
- -malign-loops=4 \
|
|
|
+ -falign-loops \
|
|
|
-march=athlon \
|
|
|
#-mcpu=athlon
|
|
|
else
|
|
@@ -203,7 +204,7 @@ $(warning Old gcc detected ($(CC_SHORTVER)), use gcc 3.0.x \
|
|
|
else
|
|
|
#really old version
|
|
|
$(warning You are using an old and unsupported gcc \
|
|
|
- version ($(CC_SHORTVER)), compile at your own risk!)
|
|
|
+ version ($(CC_SHORTVER)), compile at your own risk!)
|
|
|
|
|
|
endif # CC_SHORTVER, 2.9x
|
|
|
endif # CC_SHORTVER, 3.0
|