mirror of
https://github.com/Noratrieb/std-internal-docs.git
synced 2026-01-14 17:45:03 +01:00
build
This commit is contained in:
commit
2014bd8ee1
5 changed files with 96 additions and 0 deletions
29
build.sh
Normal file
29
build.sh
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
set -euxo pipefail
|
||||
|
||||
root=$(realpath "$PWD")
|
||||
|
||||
# use a higher depth because bootstrap might be broken with depth 1?
|
||||
git clone --depth 50 https://github.com/rust-lang/rust.git
|
||||
cd rust
|
||||
|
||||
./configure \
|
||||
--set llvm.download-ci-llvm=true \
|
||||
--set rust.download-rustc=true
|
||||
|
||||
targets=(x86_64-unknown-linux-gnu x86_64-pc-windows-msvc aarch64-apple-darwin)
|
||||
|
||||
for target in "${targets[@]}"; do
|
||||
echo "Building $target"
|
||||
|
||||
export RUSTDOCFLAGS="--document-private-items \
|
||||
--document-hidden-items \
|
||||
--html-before-content=$root/before.html \
|
||||
--extend-css=$root/style.css"
|
||||
|
||||
./x doc library --target "$target"
|
||||
|
||||
mkdir "$root/www-root/$target"
|
||||
cp -r "./build/$target/doc" "$root/www-root/$target"
|
||||
done
|
||||
Loading…
Add table
Add a link
Reference in a new issue