Use the latest Nim 1.6.6 RC; Handle Nim rebuilds when the new Nimble was already used
This commit is contained in:
parent
b6685bb651
commit
9b15962d8d
8
.envrc
8
.envrc
|
@ -1,16 +1,18 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
export IN_STATUS_NIM_WORKSPACE=1
|
||||||
|
|
||||||
export NIM_REPO="https://github.com/status-im/Nim"
|
export NIM_REPO="https://github.com/status-im/Nim"
|
||||||
export NIMBLE_REPO="https://github.com/nim-lang/nimble"
|
export NIMBLE_REPO="https://github.com/nim-lang/nimble"
|
||||||
|
|
||||||
if [[ -z "${NIM_COMMIT}" ]]; then
|
if [[ -z "${NIM_COMMIT}" ]]; then
|
||||||
export NIM_COMMIT="727c6378d2464090564dbcd9bc8b9ac648467e38" # v1.6.0
|
export NIM_COMMIT="d38177b11f628d9675809bfa85356c3ee3a26fea" # latest v1.6.x (2021-04-14)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -z "${NIMBLE_COMMIT}" ]]; then
|
if [[ -z "${NIMBLE_COMMIT}" ]]; then
|
||||||
export NIMBLE_COMMIT="26c9102c84c6b278985cedce79d6b8982361cb81" # latest (2021-12-16)
|
export NIMBLE_COMMIT="d68b2cb6efe8ce298cb5021fe84d3814d755322f" # latest (2021-04-14)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
source ./scripts/rebuild-nim
|
source ./scripts/rebuild-nim
|
||||||
|
|
||||||
export PATH="$(pwd)/${NIM_DIR}/bin:$(pwd)/scripts:${PATH}"
|
export PATH="$(pwd)/${NIM_DIR}/bin:$(pwd)/scripts:${PATH}"
|
||||||
|
|
||||||
|
|
|
@ -114,6 +114,9 @@ build_nim() {
|
||||||
git clone "${NIMBLE_REPO}" .
|
git clone "${NIMBLE_REPO}" .
|
||||||
git checkout "${NIMBLE_COMMIT}"
|
git checkout "${NIMBLE_COMMIT}"
|
||||||
# we have to delete .git or koch.nim will checkout a branch tip, overriding our target commit
|
# we have to delete .git or koch.nim will checkout a branch tip, overriding our target commit
|
||||||
|
# TODO
|
||||||
|
# This is quite the hack and it breaks the output of `nimble --version`
|
||||||
|
# which prints the Nim revision instead of the Nimble revision.
|
||||||
rm -rf .git
|
rm -rf .git
|
||||||
popd
|
popd
|
||||||
fi
|
fi
|
||||||
|
@ -122,6 +125,10 @@ build_nim() {
|
||||||
rm -rf dist/nimble
|
rm -rf dist/nimble
|
||||||
ln -s ../"${NIMBLE_DIR}" dist/nimble
|
ln -s ../"${NIMBLE_DIR}" dist/nimble
|
||||||
|
|
||||||
|
# Clean up the new Nimble cache, because the csources build
|
||||||
|
# won't recognize the validity of the packages there:
|
||||||
|
rm -rf ~/.nimble/pkgs2
|
||||||
|
|
||||||
# bootstrap the Nim compiler and build the tools
|
# bootstrap the Nim compiler and build the tools
|
||||||
rm -f bin/nim bin/nim_csources
|
rm -f bin/nim bin/nim_csources
|
||||||
pushd csources
|
pushd csources
|
||||||
|
|
Loading…
Reference in New Issue