Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

avoid git.qemu.org #876

Merged
merged 1 commit into from
May 4, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion scripts/build-toolchains.sh
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,17 @@ module_all riscv-tests --prefix="${RISCV}/riscv${XLEN}-unknown-elf" --with-xlen=
CC= CXX= SRCDIR="$(pwd)/toolchains" module_all libgloss --prefix="${RISCV}/riscv${XLEN}-unknown-elf" --host=riscv${XLEN}-unknown-elf

if [ -z "$IGNOREQEMU" ] ; then
SRCDIR="$(pwd)/toolchains" module_all qemu --prefix="${RISCV}" --target-list=riscv${XLEN}-softmmu
echo "=> Starting qemu build"
dir="$(pwd)/toolchains/qemu"
echo "==> Initializing qemu submodule"
#since we don't want to use the global config we init passing rewrite config in to the command
git -c url.https://github.com/qemu.insteadOf=https://git.qemu.org/git submodule update --init --recursive "$dir"
echo "==> Applying url-rewriting to avoid git.qemu.org"
# and once the clones exist, we recurse through them and set the rewrite
# in the local config so that any further commands by the user have the rewrite. uggh. git, why you so ugly?
git -C "$dir" config --local url.https://github.com/qemu.insteadOf https://git.qemu.org/git
git -C "$dir" submodule foreach --recursive 'git config --local url.https://github.com/qemu.insteadOf https://git.qemu.org/git'
SRCDIR="$(pwd)/toolchains" module_build qemu --prefix="${RISCV}" --target-list=riscv${XLEN}-softmmu
fi

# make Dromajo
Expand Down