Rename definition to truffleruby+graalvm

* '+' needs to be considered part of the name for --definitions and -l
  to see truffleruby and truffleruby+graalvm as separate.
This commit is contained in:
Benoit Daloze 2020-07-13 20:53:14 +02:00
parent 767a1ccc30
commit 30895f03c4
5 changed files with 27 additions and 27 deletions

View file

@ -751,7 +751,7 @@ build_package_truffleruby() {
"${PREFIX_PATH}/lib/truffle/post_install_hook.sh"
}
build_package_graalvm() {
build_package_truffleruby_graalvm() {
clean_prefix_path
build_package_copy_to "${PREFIX_PATH}/graalvm"
@ -1259,14 +1259,14 @@ list_maintained_versions() {
extract_latest_versions() {
# sort in this function looks redundunt but it is necessary
# rbx-3.99 appears latest unless the sort
sed 'h; s/[+-]/./g; s/.p\([[:digit:]]\)/.z.\1/; s/$/.z/; G; s/\n/ /' | \
sed 'h; s/[-]/./g; s/.p\([[:digit:]]\)/.z.\1/; s/$/.z/; G; s/\n/ /' | \
LC_ALL=C sort -t. -k 1,1 -k 2,2n -k 3,3n -k 4,4n -k 5,5n | \
sed 's/[+.]/ /; s/[0-9].*z //; s/^\([0-9].[0-9]\)/mri\1 \1/' | \
sed 's/[.]/ /; s/[0-9].*z //; s/^\([0-9].[0-9]\)/mri\1 \1/' | \
awk '{ latest[$1] =$2 } END{ for(key in latest) { print latest[key] } }'
}
sort_versions() {
sed 'h; s/[+-]/./g; s/.p\([[:digit:]]\)/.z.\1/; s/$/.z/; G; s/\n/ /' | \
sed 'h; s/[-]/./g; s/.p\([[:digit:]]\)/.z.\1/; s/$/.z/; G; s/\n/ /' | \
LC_ALL=C sort -t. -k 1,1 -k 2,2n -k 3,3n -k 4,4n -k 5,5n | awk '{print $2}'
}

View file

@ -10,7 +10,7 @@ fi
version="$1"
release_directory="$2"
file="share/ruby-build/graalvm-${version}"
file="share/ruby-build/truffleruby+graalvm-${version}"
add_platform() {
platform="$1"
@ -19,7 +19,7 @@ add_platform() {
sha256=$(sha256sum "$release_directory/$basename" | cut -d ' ' -f 1)
cat >> "$file" <<EOS
install_package "graalvm-${version}" "${url}#${sha256}" graalvm
install_package "truffleruby+graalvm-${version}" "${url}#${sha256}" truffleruby_graalvm
;;
EOS
}

View file

@ -1,13 +0,0 @@
case $(uname -s) in
Linux)
install_package "graalvm-20.1.0" "https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-20.1.0/graalvm-ce-java8-linux-amd64-20.1.0.tar.gz#4fac212b37cd548831fd6587dd4d59dc068068815aa20323b47fde9529d6bb6e" graalvm
;;
Darwin)
use_homebrew_openssl
install_package "graalvm-20.1.0" "https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-20.1.0/graalvm-ce-java8-darwin-amd64-20.1.0.tar.gz#3b9fd8ce84c9162a188fde88907c66990db22af0ff6ae2c04430113253a9a634" graalvm
;;
*)
colorize 1 "Unsupported operating system: $(uname -s)"
return 1
;;
esac

View file

@ -0,0 +1,13 @@
case $(uname -s) in
Linux)
install_package "truffleruby+graalvm-20.1.0" "https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-20.1.0/graalvm-ce-java8-linux-amd64-20.1.0.tar.gz#4fac212b37cd548831fd6587dd4d59dc068068815aa20323b47fde9529d6bb6e" truffleruby_graalvm
;;
Darwin)
use_homebrew_openssl
install_package "truffleruby+graalvm-20.1.0" "https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-20.1.0/graalvm-ce-java8-darwin-amd64-20.1.0.tar.gz#3b9fd8ce84c9162a188fde88907c66990db22af0ff6ae2c04430113253a9a634" truffleruby_graalvm
;;
*)
colorize 1 "Unsupported operating system: $(uname -s)"
return 1
;;
esac

View file

@ -82,8 +82,6 @@ NUM_DEFINITIONS="$(ls "$BATS_TEST_DIRNAME"/../share/ruby-build | wc -l)"
2.1.0
2.1.1
2.2.0-dev
graalvm-20.0.0
graalvm-20.1.0
jruby-1.6.5
jruby-1.6.5.1
jruby-1.7.0-preview1
@ -96,7 +94,9 @@ jruby-9000-dev
jruby-9000
truffleruby-1.0.0-rc2
truffleruby-19.0.0
truffleruby-19.3.0"
truffleruby-19.3.0
truffleruby+graalvm-20.0.0
truffleruby+graalvm-20.1.0"
for ver in $expected; do
touch "${RUBY_BUILD_ROOT}/share/ruby-build/$ver"
done
@ -134,8 +134,6 @@ truffleruby-19.3.0"
2.6.4
2.6.5
2.7.0
graalvm-20.0.0
graalvm-20.1.0
jruby-1.5.6
jruby-9.2.7.0
jruby-9.2.8.0
@ -152,18 +150,20 @@ rbx-3.107
truffleruby-19.2.0.1
truffleruby-19.3.0
truffleruby-19.3.0.2
truffleruby-19.3.1"
truffleruby-19.3.1
truffleruby+graalvm-20.0.0
truffleruby+graalvm-20.1.0"
expected="2.4.9
2.5.7
2.6.5
2.7.0
graalvm-20.1.0
jruby-9.2.9.0
maglev-1.0.0
mruby-2.1.0
rbx-3.107
truffleruby-19.3.1"
truffleruby-19.3.1
truffleruby+graalvm-20.1.0"
for ver in $all_versions; do
touch "${RUBY_BUILD_ROOT}/share/ruby-build/$ver"