diff options
author | Sam Thursfield <sam.thursfield@codethink.co.uk> | 2017-08-24 12:56:15 +0000 |
---|---|---|
committer | Sam Thursfield <sam.thursfield@codethink.co.uk> | 2017-08-24 12:56:15 +0000 |
commit | 6632adf452a9f514545a1f8be8adcd922a0ccbc5 (patch) | |
tree | dd0f4774ed3d9f67950d51a95da409597db48610 /elements/gnu-toolchain/stage1-binutils.bst | |
parent | 54e447a9f1a9e94d68e6f5f616617ce49682192a (diff) | |
parent | 879a306c8c6285e9ef8dcbbba96bb84e62a9654c (diff) | |
download | definitions-6632adf452a9f514545a1f8be8adcd922a0ccbc5.tar.gz |
Merge remote-tracking branch 'buildstream-tests/gnu-toolchain' into sam/buildstream-autoconvert
This branch contains a manual conversion of the Baserock bootstrap
process to BuildStream. The original branch can be found here:
https://gitlab.com/BuildStream/buildstream-tests/tree/gnu-toolchain
It's not possible to automatically convert the existing Baserock
bootstrap due to differences in how BuildStream works.
Diffstat (limited to 'elements/gnu-toolchain/stage1-binutils.bst')
-rw-r--r-- | elements/gnu-toolchain/stage1-binutils.bst | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/elements/gnu-toolchain/stage1-binutils.bst b/elements/gnu-toolchain/stage1-binutils.bst new file mode 100644 index 00000000..72d51bcb --- /dev/null +++ b/elements/gnu-toolchain/stage1-binutils.bst @@ -0,0 +1,38 @@ +kind: autotools + +sources: +- kind: git + url: upstream:binutils-tarball + track: binutils-2.25 + ref: 5500a97a2ad1735db5b35bc51cfb825c1f4c38df + +depends: +- gnu-toolchain/base-platform.bst +- gnu-toolchain/base-sdk.bst + +variables: + prefix: /tools + +environment: + PATH: /tools/bin:/usr/bin:/bin:/usr/sbin:/sbin + +config: + configure-commands: + # We set the sysroot location dynamically at runtime by passing + # `--sysroot` to GCC, so we need to build a linker with sysroot support. + # We set it to a non-existent directory as a safety net to avoid looking + # at the host dirs in case we forget to set the sysroot. Setting the + # lib path is vital to avoid the tools we build linking to the libraries + # on the host system; the '=' makes the path we give relative to the + # sysroot, which we can then set at runtime by passing -Wl,--sysroot to + # GCC. Although nothing should be installed on /lib64, we configure the + # linker to look at that directory as well to make things more robust + # (currently GCC installs libraries to this directory at least on + # x86_64). + + - | + %{configure} --disable-nls --disable-werror \ + --build=$(sh config.guess) \ + --host=$(sh config.guess) \ + --target=%{target-stage1} \ + --with-sysroot=/nonexistentdir --with-lib-path="=%{prefix}/lib:=%{prefix}/lib64" |