Browse Source

gcc: moved per-architecture options into $confdir/arch/options.$arch.in

karasz/new-early
Alejandro Mery 16 years ago committed by Alejandro Mery
parent
commit
0ac32e12df
  1. 19
      base/gcc/arch/options.alpha.in
  2. 21
      base/gcc/arch/options.arm.in
  3. 19
      base/gcc/arch/options.hppa.in
  4. 19
      base/gcc/arch/options.hppa64.in
  5. 19
      base/gcc/arch/options.mips.in
  6. 19
      base/gcc/arch/options.mips64.in
  7. 22
      base/gcc/arch/options.powerpc.in
  8. 21
      base/gcc/arch/options.powerpc64.in
  9. 26
      base/gcc/arch/options.sh.in
  10. 23
      base/gcc/arch/options.sh64.in
  11. 26
      base/gcc/arch/options.sparc.in
  12. 21
      base/gcc/arch/options.sparc64.in
  13. 23
      base/gcc/arch/options.x86-64.in
  14. 31
      base/gcc/arch/options.x86.in
  15. 11
      base/gcc/parse-config

19
base/gcc/arch/options.alpha.in

@ -0,0 +1,19 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.alpha.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ $SDECFG_ALPHA_OPT != generic ] ; then
var_append GCC3_WRAPPER_INSERT " " \
"-mtune=$SDECFG_ALPHA_OPT"
fi

21
base/gcc/arch/options.arm.in

@ -0,0 +1,21 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.arm.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
[ "$SDECFG_ARM_OPT" != generic ] &&
var_append GCC_WRAPPER_INSERT " " "-mcpu=$SDECFG_ARM_OPT"
[ "$SDECFG_ARM_THUMB" = 1 ] &&
var_append GCC_WRAPPER_INSERT " " "-mthumb -mthumb-interwork -D__arm__"

19
base/gcc/arch/options.hppa.in

@ -0,0 +1,19 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.hppa.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ "$SDECFG_HPPA_OPT" != "generic" ] ; then
var_append GCC_WRAPPER_INSERT " " "-mcpu=$SDECFG_HPPA_OPT"
fi

19
base/gcc/arch/options.hppa64.in

@ -0,0 +1,19 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.hppa64.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ "$SDECFG_HPPA64_OPT" != "generic" ] ; then
var_append GCC_WRAPPER_INSERT " " "-mcpu=$SDECFG_HPPA64_OPT"
fi

19
base/gcc/arch/options.mips.in

@ -0,0 +1,19 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.mips.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ $SDECFG_MIPS_OPT != generic ] ; then
var_append GCC_WRAPPER_INSERT " " "-march=$SDECFG_MIPS_OPT"
fi

19
base/gcc/arch/options.mips64.in

@ -0,0 +1,19 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.mips64.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ $SDECFG_MIPS64_OPT != generic ] ; then
var_append GCC_WRAPPER_INSERT " " "-march=$SDECFG_MIPS64_OPT"
fi

22
base/gcc/arch/options.powerpc.in

@ -0,0 +1,22 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.powerpc.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ "$SDECFG_POWERPC_ISA" ] ; then
var_append GCC_WRAPPER_INSERT " " "-mcpu=$SDECFG_POWERPC_ISA"
fi
if [ "$SDECFG_POWERPC_OPT" != "generic" ] ; then
var_append GCC_WRAPPER_INSERT " " "-mtune=$SDECFG_POWERPC_OPT"
fi

21
base/gcc/arch/options.powerpc64.in

@ -0,0 +1,21 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.powerpc64.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ "$SDECFG_POWERPC64_OPT" != "generic" ] ; then
var_append GCC_WRAPPER_INSERT " " "-mcpu=$SDECFG_POWERPC64_OPT"
else
var_append GCC_WRAPPER_INSERT " " "-mcpu=powerpc64"
fi

26
base/gcc/arch/options.sh.in

@ -0,0 +1,26 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.sh.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ "$SDECFG_SH_OPT" ] ; then
opt=
case "$SDECFG_SH_OPT" in
sh) opt="-m1" ;;
sh2) opt="-m2" ;;
sh3) opt="-m3" ;;
sh4) opt="-m4" ;;
esac
var_append GCC_WRAPPER_INSERT " " "$opt"
fi

23
base/gcc/arch/options.sh64.in

@ -0,0 +1,23 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.sh64.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ "$SDECFG_SH64_OPT" ] ; then
opt=
case "$SDECFG_SH64_OPT" in
sh5) opt="-m5" ;;
esac
var_append GCC_WRAPPER_INSERT " " "$opt"
fi

26
base/gcc/arch/options.sparc.in

@ -0,0 +1,26 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.sparc.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
if [ "$SDECFG_SPARC_OPT" ] ; then
opt=
case "$SDECFG_SPARC_OPT" in
v7) opt="-mcpu=cypress -mtune=cypress" ;;
v8) opt="-mcpu=supersparc -mtune=supersparc" ;;
v9) opt="-mcpu=ultrasparc -mtune=ultrasparc" ;;
v9vis) opt="-mcpu=ultrasparc -mtune=ultrasparc -mvis" ;;
esac
var_append GCC_WRAPPER_INSERT " " "$opt"
fi

21
base/gcc/arch/options.sparc64.in

@ -0,0 +1,21 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.sparc64.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
case "$SDECFG_SPARC64_OPT" in
generic) ;;
*)
var_append GCC_WRAPPER_INSERT " " "-mcpu=$SDECFG_SPARC64_OPT" ;;
esac

23
base/gcc/arch/options.x86-64.in

@ -0,0 +1,23 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.x86-64.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
case "$SDECFG_X8664_OPT" in
generic) ;;
em64t)
var_append GCC_WRAPPER_INSERT " " "-march=nocona" ;;
*)
var_append GCC_WRAPPER_INSERT " " "-march=$SDECFG_X8664_OPT" ;;
esac

31
base/gcc/arch/options.x86.in

@ -0,0 +1,31 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../gcc/arch/options.x86.in
# Copyright (C) 2008 The OpenSDE Project
# Copyright (C) 2004 - 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
case "$SDECFG_X86_OPT" in
generic) ;;
k6*)
var_append GCC_WRAPPER_INSERT " " "-march=$SDECFG_X86_OPT"
# workaround and should be removed when gcc 3.x got fixed ...
var_append GCC_WRAPPER_INSERT " " "-fno-branch-count-reg"
;;
pentium4)
var_append GCC_WRAPPER_INSERT " " "-march=$SDECFG_X86_OPT"
# workaround for gcc bug #15617
var_append GCC_WRAPPER_INSERT " " "-mpreferred-stack-boundary=7"
;;
*)
var_append GCC_WRAPPER_INSERT " " "-march=$SDECFG_X86_OPT" ;;
esac

11
base/gcc/parse-config

@ -1,4 +1,3 @@
#!/bin/sh
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
@ -134,9 +133,13 @@ fi
# Add the architecture gcc optimisation options
#
if [ -f architecture/$arch/gcc-options.in ] ; then
. architecture/$arch/gcc-options.in
gcc_arch_options="$(pkgdesc confdir gcc)/arch/options.$arch.in"
if [ -s "$gcc_arch_options" ]; then
. "$gcc_arch_options"
else
echo_warning "gcc: no mappings found for $arch architecture"
fi
unset gcc_arch_options
# Inject -fPIC if the package is marked to need a quirk ...
#
@ -148,5 +151,3 @@ if hasflag NO-AS-NEEDED; then
var_remove_regex GCC_WRAPPER_INSERT ' ' ".*-Wl,--as-needed"
var_append GCC_WRAPPER_REMOVE ' ' "-Wl,--as-needed"
fi

Loading…
Cancel
Save