Skip to content

Commit a3aef1a

Browse files
committed
Fix fuchsia toolchain prebuild setup
* Adjust bootstrap to provide useful output on failure * Add missing package dependencies in the build environment * Fix permission bits on prebuilt toolchain files
1 parent d7a17fb commit a3aef1a

File tree

3 files changed

+17
-12
lines changed

3 files changed

+17
-12
lines changed

src/bootstrap/sanity.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -221,8 +221,9 @@ $ pacman -R cmake && pacman -S mingw-w64-x86_64-cmake
221221
let run = |cmd: &mut Command| {
222222
cmd.output().map(|output| {
223223
String::from_utf8_lossy(&output.stdout)
224-
.lines().next().unwrap()
225-
.to_string()
224+
.lines().next().unwrap_or_else(|| {
225+
panic!("{:?} failed {:?}", cmd, output)
226+
}).to_string()
226227
})
227228
};
228229
build.lldb_version = run(Command::new("lldb").arg("--version")).ok();

src/ci/docker/dist-fuchsia/Dockerfile

+13-9
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,21 @@
11
FROM ubuntu:16.04
22

3-
RUN apt-get update && apt-get install -y --no-install-recommends \
4-
g++ \
5-
make \
6-
file \
7-
curl \
3+
RUN apt-get update && apt-get build-dep -y clang llvm && apt-get install -y \
4+
build-essential \
5+
bzip2 \
86
ca-certificates \
9-
python2.7-dev \
10-
git \
117
cmake \
8+
curl \
9+
file \
10+
g++ \
11+
gdb \
12+
git \
13+
libedit-dev \
14+
make \
1215
ninja-build \
16+
nodejs \
17+
python2.7-dev \
1318
sudo \
14-
bzip2 \
1519
xz-utils \
1620
unzip
1721

@@ -34,4 +38,4 @@ ENV TARGETS=x86_64-unknown-fuchsia
3438
ENV TARGETS=$TARGETS,aarch64-unknown-fuchsia
3539

3640
ENV RUST_CONFIGURE_ARGS --target=$TARGETS --enable-extended
37-
ENV SCRIPT python2.7 ../x.py dist --target $TARGETS
41+
ENV SCRIPT python2.7 ../x.py dist --target $TARGETS

src/ci/docker/dist-fuchsia/build-toolchain.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ git reset --hard FETCH_HEAD
2727

2828
# Download toolchain
2929
./scripts/download-toolchain
30-
chmod +x prebuilt/downloads/clang+llvm-x86_64-linux/bin/*
30+
chmod -R a+rx prebuilt/downloads/clang+llvm-x86_64-linux
3131
cp -a prebuilt/downloads/clang+llvm-x86_64-linux/. /usr/local
3232

3333
build() {

0 commit comments

Comments
 (0)