Skip to content

Commit a80256d

Browse files
committed
Use the version from .ruby-version for tool/generate-config-header.sh
1 parent 1a391c8 commit a80256d

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

tool/generate-config-header.sh

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,12 @@
33
set -e
44
set -x
55

6+
VERSION=$(cat .ruby-version)
7+
68
url="$1"
79
if [ -z "$url" ]; then
8-
url=$(mx urlrewrite https://lafo.ssw.uni-linz.ac.at/pub/graal-external-deps/ruby-3.0.2.tar.gz)
10+
# The source archive, a copy from https://www.ruby-lang.org/en/downloads/
11+
url=$(mx urlrewrite "https://lafo.ssw.uni-linz.ac.at/pub/graal-external-deps/ruby-$VERSION.tar.gz")
912
fi
1013

1114
os=$(uname -s)
@@ -29,10 +32,10 @@ archive=$(basename "$url")
2932

3033
if [ ! -e "$archive" ]; then
3134
curl -O "$url"
32-
tar xf ruby-3.0.2.tar.gz
35+
tar xf "ruby-$VERSION.tar.gz"
3336
fi
3437

35-
cd ruby-3.0.2 || exit 1
38+
cd "ruby-$VERSION" || exit 1
3639
./configure || (cat config.log; exit 1)
3740

3841
cp .ext/include/*/ruby/config.h "../lib/cext/include/truffleruby/config_${mx_platform}.h"

0 commit comments

Comments
 (0)