Browse Source

gcc: changed to define $gcc_ver being a comparable version number

stable/0.6
Christian Wiese 13 years ago
parent
commit
d49ee986a6
  1. 10
      base/gcc/gcc.conf

10
base/gcc/gcc.conf

@ -2,7 +2,7 @@
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/gcc.conf
# Copyright (C) 2006 - 2012 The OpenSDE Project
# Copyright (C) 2006 - 2013 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
@ -16,9 +16,15 @@
#exclude internal libffi, we have it packaged for g-wrap
hook_add preconf 1 'sed -i -e "s/@toolexeclibdir@/@toolexeclibdir@\/gcc/" libffi/Makefile.in'
# comparable version
gcc_ver=0
for x in $(echo "$ver" | cut -d- -f1 | cut -d. -f1-3 | tr '.' ' '); do
gcc_ver=$( expr $gcc_ver \* 1000 + $x )
done
# provide same settings we use for -m{arch,cpu,tune} via configure options
# so they are default compiler settings on the final target machine
if [ "${ver:0:3}" = "4.4" ]; then
if [ "${gcc_ver}" -ge 4004000 ]; then
for x in $GCC_WRAPPER_INSERT $GCC_WRAPPER_APPEND; do
case "$x" in
-mabi=*|-march=*|-mcpu=*|-mtune=*|-mfpu=*) var_append confopt " " "${x/-m/--with-}" ;;

Loading…
Cancel
Save