gcc: use as(1) from binutils with LLVM bintools

LLVM does not provide a drop-in replacement for as(1).

This makes it possible to build a GNU Fortran cross compiler from GNU
to LLVM — e.g. buildPackages.gfortran for
{ system = "aarch64-linux"; useLLVM = true; }
This commit is contained in:
Alyssa Ross 2023-01-19 21:40:06 +00:00 committed by sternenseemann
parent f5e63a0e9e
commit 4ed0e1a743
10 changed files with 20 additions and 20 deletions

View File

@ -13,7 +13,7 @@
, enableLTO ? !stdenv.hostPlatform.isStatic
, texinfo ? null
, perl ? null # optional, for texi2pod (then pod2man)
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null
, gnatboot ? null
@ -202,7 +202,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
enableLTO
enableMultilib

View File

@ -13,7 +13,7 @@
, enableLTO ? !stdenv.hostPlatform.isStatic
, texinfo ? null
, perl ? null # optional, for texi2pod (then pod2man)
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null
, gnatboot ? null
@ -206,7 +206,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
enableLTO
enableMultilib

View File

@ -13,7 +13,7 @@
, enableLTO ? !stdenv.hostPlatform.isStatic
, texinfo ? null
, perl ? null # optional, for texi2pod (then pod2man)
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null
, libucontext ? null
@ -250,7 +250,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
enableLTO
enableMultilib

View File

@ -12,7 +12,7 @@
, enableLTO ? !stdenv.hostPlatform.isStatic
, texinfo ? null
, perl ? null # optional, for texi2pod (then pod2man); required for Java
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, cloog ? null, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null, boehmgc ? null
, zip ? null, unzip ? null, pkg-config ? null
@ -207,7 +207,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
cloog
enableLTO

View File

@ -12,7 +12,7 @@
, enableLTO ? !stdenv.hostPlatform.isStatic
, texinfo ? null
, perl ? null # optional, for texi2pod (then pod2man); required for Java
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, cloog ? null, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null, boehmgc ? null
, zip ? null, unzip ? null, pkg-config ? null
@ -227,7 +227,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
cloog
enableLTO

View File

@ -14,7 +14,7 @@
, texinfo ? null
, flex
, perl ? null # optional, for texi2pod (then pod2man); required for Java
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null, boehmgc ? null
, gnatboot ? null
@ -238,7 +238,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
enableLTO
enableMultilib

View File

@ -11,7 +11,7 @@
, enableLTO ? !stdenv.hostPlatform.isStatic
, texinfo ? null
, perl ? null # optional, for texi2pod (then pod2man)
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null
, enableMultilib ? false
@ -206,7 +206,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
enableLTO
enableMultilib

View File

@ -11,7 +11,7 @@
, enableLTO ? !stdenv.hostPlatform.isStatic
, texinfo ? null
, perl ? null # optional, for texi2pod (then pod2man)
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null
, enableMultilib ? false
@ -188,7 +188,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
enableLTO
enableMultilib

View File

@ -13,7 +13,7 @@
, enableLTO ? !stdenv.hostPlatform.isStatic
, texinfo ? null
, perl ? null # optional, for texi2pod (then pod2man)
, gmp, mpfr, libmpc, gettext, which, patchelf
, gmp, mpfr, libmpc, gettext, which, patchelf, binutils
, isl ? null # optional, for the Graphite optimization framework.
, zlib ? null
, gnatboot ? null
@ -201,7 +201,7 @@ stdenv.mkDerivation ({
crossStageStatic libcCross threadsCross
version
gmp mpfr libmpc isl
binutils gmp mpfr libmpc isl
enableLTO
enableMultilib

View File

@ -5,7 +5,7 @@
, threadsCross
, version
, gmp, mpfr, libmpc, isl
, binutils, gmp, mpfr, libmpc, isl
, cloog ? null
, enableLTO
@ -51,7 +51,7 @@ let
crossConfigureFlags =
# Ensure that -print-prog-name is able to find the correct programs.
[
"--with-as=${targetPackages.stdenv.cc.bintools}/bin/${targetPlatform.config}-as"
"--with-as=${if targetPackages.stdenv.cc.bintools.isLLVM then binutils else targetPackages.stdenv.cc.bintools}/bin/${targetPlatform.config}-as"
"--with-ld=${targetPackages.stdenv.cc.bintools}/bin/${targetPlatform.config}-ld"
]
++ (if crossStageStatic then [