Skip to content

Commit

Permalink
Fix scripts
Browse files Browse the repository at this point in the history
topjohnwu committed May 5, 2024
1 parent 6d99867 commit c798839
Showing 4 changed files with 11 additions and 17 deletions.
2 changes: 0 additions & 2 deletions build-windows.sh
Original file line number Diff line number Diff line change
@@ -3,8 +3,6 @@
# Copyright 2022-2024 Google LLC.
# SPDX-License-Identifier: Apache-2.0

set -e

if ! uname | grep -q 'MINGW64_NT'; then
echo 'This script should run on MSYS2 bash'
echo
2 changes: 0 additions & 2 deletions build.sh
Original file line number Diff line number Diff line change
@@ -3,8 +3,6 @@
# Copyright 2022-2024 Google LLC.
# SPDX-License-Identifier: Apache-2.0

set -e

. common.sh

OS=$(uname | tr '[:upper:]' '[:lower:]')
10 changes: 0 additions & 10 deletions clean.sh

This file was deleted.

14 changes: 11 additions & 3 deletions common.sh
Original file line number Diff line number Diff line change
@@ -17,6 +17,9 @@ OUTPUT_VERSION='r27.0'

PYTHON_CMD='python3'

set -e
shopt -s nullglob

# url sha
git_clone_sha() {
local dir=${1##*/}
@@ -36,9 +39,9 @@ git_clone_branch() {
clone() {
git_clone_branch https://github.com/rust-lang/rust $RUST_VERSION
cd rust
# for p in ../patches/*.patch; do
# patch -p1 < $p
# done
for p in ../patches/*.patch; do
patch -p1 < $p
done
# Skip rust llvm
sed 's:\[submodule "src/llvm-project"\]:&\n\tupdate = none:' .gitmodules > .gitmodules.p
mv .gitmodules.p .gitmodules
@@ -117,6 +120,11 @@ run_cmd() {
rm -rf dist ondk-*
dist
;;
clean)
rm -rf rust llvm-project llvm_android toolchain-utils \
out out.arm out.x86 ndk tmp mingw64 \
android-ndk-*.zip ondk-* dist mingw.7z
;;
*)
echo "Unknown action \"$1\""
echo "./build.sh clone/build/ndk/dist"

0 comments on commit c798839

Please sign in to comment.