1 # --- T2-COPYRIGHT-NOTE-BEGIN ---
2 # T2 SDE: package/*/binutils/binutils.conf
3 # Copyright (C) 2004 - 2023 The T2 SDE Project
5 # This Copyright note is generated by scripts/Create-CopyPatch,
6 # more information can be found in the files COPYING and README.
8 # This program is free software; you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License version 2.
10 # --- T2-COPYRIGHT-NOTE-END ---
12 [[ "$arch" = loongarch* || "$arch" = mips* || "$arch" = s390* ]] &&
13 echo_warning "Gold disabled for $arch" ||
14 var_append extraconfopt ' ' '--enable-gold --enable-ld=default'
15 var_append extraconfopt ' ' '--enable-threads --enable-plugins --enable-shared'
16 var_append extraconfopt ' ' '--enable-64-bit-bfd --enable-targets=no'
17 [ "$arch" = "ia64" ] && var_append extraconfopt ' ' '--enable-obsolete'
19 if atstage toolchain; then
20 var_append confopt " " "--with-sysroot=$sysroot"
21 var_append confopt " " '--program-prefix=${arch_target}-'
23 confopt="${confopt/--with-sysroot/--with-libtool-sysroot}"
24 var_append confopt ' ' "--enable-install-libiberty"
27 var_append confopt " " "--disable-gprofng"
29 # hotfix libtool relink on install breaking gcc lto plugin
30 if atstage native; then
31 hook_add inmake 5 "install {bfd,opcodes}/.libs/lib*-*.so $root$libdir/"
32 hook_add inmake 5 "install libsframe/.libs/lib*.so.* $root$libdir/"