2021-01-20 23:15:24 +03:00
|
|
|
#!/bin/sh
|
|
|
|
|
2021-04-06 17:42:04 +03:00
|
|
|
set -e # exit on any error
|
2021-01-20 23:15:24 +03:00
|
|
|
|
2021-07-21 16:35:21 +03:00
|
|
|
BOOTSTRAP_PREFIX=$PWD/bootstrap-build
|
2021-01-20 23:15:24 +03:00
|
|
|
|
|
|
|
IDRIS2_CG="${IDRIS2_CG-"chez"}"
|
|
|
|
|
2021-07-21 16:35:21 +03:00
|
|
|
# BOOTSTRAP_PREFIX must be the "clean" build root, without cygpath -m
|
2021-01-20 23:15:24 +03:00
|
|
|
# Otherwise, we get 'git: Bad address'
|
2021-07-21 16:35:21 +03:00
|
|
|
echo "$BOOTSTRAP_PREFIX"
|
|
|
|
DYLIB_PATH="$BOOTSTRAP_PREFIX/lib"
|
2021-01-20 23:15:24 +03:00
|
|
|
|
2022-10-04 15:37:45 +03:00
|
|
|
$MAKE bootstrap-libs IDRIS2_CG="$IDRIS2_CG" LD_LIBRARY_PATH="$DYLIB_PATH" \
|
2021-07-21 16:35:21 +03:00
|
|
|
PREFIX="$BOOTSTRAP_PREFIX" SCHEME="$SCHEME"
|
2022-10-04 15:37:45 +03:00
|
|
|
$MAKE bootstrap-install IDRIS2_CG="$IDRIS2_CG" LD_LIBRARY_PATH="$DYLIB_PATH" \
|
2021-07-21 16:35:21 +03:00
|
|
|
PREFIX="$BOOTSTRAP_PREFIX" SCHEME="$SCHEME"
|
2021-01-20 23:15:24 +03:00
|
|
|
|
|
|
|
# Now rebuild everything properly
|
2021-07-21 16:35:21 +03:00
|
|
|
$MAKE clean-libs IDRIS2_BOOT="$BOOTSTRAP_PREFIX/bin/idris2"
|
|
|
|
$MAKE all IDRIS2_BOOT="$BOOTSTRAP_PREFIX/bin/idris2" IDRIS2_CG="$IDRIS2_CG" \
|
2022-01-25 22:50:57 +03:00
|
|
|
LD_LIBRARY_PATH="$DYLIB_PATH" \
|
2021-01-20 23:15:24 +03:00
|
|
|
SCHEME="$SCHEME"
|