Skip to content

Commit 64343a6

Browse files
committed
Merge #21089: guix: Add support for powerpc64{,le}
95990b9 guix: Update conservative space requirements (Carl Dong) 5e6df11 guix: Add support for powerpc64{,le} (Carl Dong) Pull request description: ``` The new time-machine commit contains a few small changes that make the powerpc cross-toolchain work. ``` See this compare to review my custom patches to Guix: dongcarl/guix@7d6bd44...6c9d16d ACKs for top commit: fanquake: ACK 95990b9 Tree-SHA512: 464b0fb93d65962d8c27499293edb618d13d18f40d44e3eed96935e86d430666dfb1c5b8a30f99ffdfd17b44514ad88e358977390b689a2e3831d521f6f7b86a
2 parents 7fca189 + 95990b9 commit 64343a6

File tree

4 files changed

+21
-14
lines changed

4 files changed

+21
-14
lines changed

contrib/guix/README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,9 @@ We achieve bootstrappability by using Guix as a functional package manager.
1313

1414
Conservatively, a x86_64 machine with:
1515

16-
- 4GB of free disk space on the partition that /gnu/store will reside in
17-
- 24GB of free disk space on the partition that the Bitcoin Core git repository
18-
resides in
19-
20-
> Note: these requirements are slightly less onerous than those of Gitian builds
16+
- 16GB of free disk space on the partition that /gnu/store will reside in
17+
- 8GB of free disk space per platform triple you're planning on building (see
18+
the `HOSTS` environment variable description)
2119

2220
## Setup
2321

contrib/guix/guix-build.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ fi
6969
################
7070

7171
# Default to building for all supported HOSTs (overridable by environment)
72-
export HOSTS="${HOSTS:-x86_64-linux-gnu arm-linux-gnueabihf aarch64-linux-gnu riscv64-linux-gnu
72+
export HOSTS="${HOSTS:-x86_64-linux-gnu arm-linux-gnueabihf aarch64-linux-gnu riscv64-linux-gnu powerpc64-linux-gnu powerpc64le-linux-gnu
7373
x86_64-w64-mingw32
7474
x86_64-apple-darwin18}"
7575

@@ -148,7 +148,7 @@ SOURCE_DATE_EPOCH="${SOURCE_DATE_EPOCH:-$(git log --format=%at -1)}"
148148
time-machine() {
149149
# shellcheck disable=SC2086
150150
guix time-machine --url=https://github.com/dongcarl/guix.git \
151-
--commit=7d6bd44da57926e0d4af25eba723a61c82beef98 \
151+
--commit=6c9d16db962a6f7155571b36eced681fd2889e23 \
152152
--max-jobs="$MAX_JOBS" \
153153
--keep-failed \
154154
${SUBSTITUTE_URLS:+--substitute-urls="$SUBSTITUTE_URLS"} \

contrib/guix/libexec/build.sh

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -136,12 +136,14 @@ case "$HOST" in
136136
*linux*)
137137
glibc_dynamic_linker=$(
138138
case "$HOST" in
139-
i686-linux-gnu) echo /lib/ld-linux.so.2 ;;
140-
x86_64-linux-gnu) echo /lib64/ld-linux-x86-64.so.2 ;;
141-
arm-linux-gnueabihf) echo /lib/ld-linux-armhf.so.3 ;;
142-
aarch64-linux-gnu) echo /lib/ld-linux-aarch64.so.1 ;;
143-
riscv64-linux-gnu) echo /lib/ld-linux-riscv64-lp64d.so.1 ;;
144-
*) exit 1 ;;
139+
i686-linux-gnu) echo /lib/ld-linux.so.2 ;;
140+
x86_64-linux-gnu) echo /lib64/ld-linux-x86-64.so.2 ;;
141+
arm-linux-gnueabihf) echo /lib/ld-linux-armhf.so.3 ;;
142+
aarch64-linux-gnu) echo /lib/ld-linux-aarch64.so.1 ;;
143+
riscv64-linux-gnu) echo /lib/ld-linux-riscv64-lp64d.so.1 ;;
144+
powerpc64-linux-gnu) echo /lib/ld64.so.1;;
145+
powerpc64le-linux-gnu) echo /lib/ld64.so.2;;
146+
*) exit 1 ;;
145147
esac
146148
)
147149
;;
@@ -231,6 +233,10 @@ case "$HOST" in
231233
*mingw*) HOST_LDFLAGS="-Wl,--no-insert-timestamp" ;;
232234
esac
233235

236+
case "$HOST" in
237+
powerpc64-linux-*) HOST_LDFLAGS="${HOST_LDFLAGS} -Wl,-z,noexecstack" ;;
238+
esac
239+
234240
# Make $HOST-specific native binaries from depends available in $PATH
235241
export PATH="${BASEPREFIX}/${HOST}/native/bin:${PATH}"
236242
mkdir -p "$DISTSRC"

contrib/guix/manifest.scm

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,10 @@ chain for " target " development."))
233233
(make-mingw-pthreads-cross-toolchain "x86_64-w64-mingw32")
234234
(make-nsis-with-sde-support nsis-x86_64)))
235235
((string-contains target "riscv64-linux-")
236-
(list (make-bitcoin-cross-toolchain "riscv64-linux-gnu"
236+
(list (make-bitcoin-cross-toolchain target
237+
#:base-gcc-for-libc gcc-7)))
238+
((string-contains target "powerpc64le-linux-")
239+
(list (make-bitcoin-cross-toolchain target
237240
#:base-gcc-for-libc gcc-7)))
238241
((string-contains target "-linux-")
239242
(list (make-bitcoin-cross-toolchain target)))

0 commit comments

Comments
 (0)