mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-08-05 21:37:15 +02:00
This commit updates $license variable in all APKBUILDs to comply with short names specified by SPDX version 3.0 [1] where possible. It was done using find-and-replace method on substrings inside $license variables. Only license names were updated, not "expressions" specifying relation between the licenses (e.g. "X and Y", "X or Y", "X and (Y or Z)") or exceptions (e.g. "X with exceptions"). Many licenses have a version or multiple variants, e.g. MPL-2.0, BSD-2-Clause, BSD-3-Clause. However, $license in many aports do not contain license version or variant. Since there's no way how to infer this information just from abuild, it were left without the variant suffix or version, i.e. non SPDX compliant. GNU licenses (AGPL, GFDL, GPL, LGPL) are especially complicated. They exist in two variants: -only (formerly e.g. GPL-2.0) and -or-later (formerly e.g. GPL-2.0+). We did not systematically noted distinguish between these variants, so GPL-2.0, GPL2, GPLv2 etc. may mean GPL-2.0-only or GPL-2.0-or-later. Thus GNU licenses without "+" (e.g. GPL2+) were left without the variant suffix, i.e. non SPDX compliant. Note: This commit just fixes format of the license names, no verification has been done if the specified license information is actually correct! [1]: https://spdx.org/licenses/
178 lines
3.9 KiB
Plaintext
178 lines
3.9 KiB
Plaintext
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
|
|
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
|
|
pkgname=jruby
|
|
pkgver=9.1.14.0
|
|
pkgrel=0
|
|
pkgdesc="An implementation of Ruby on the JVM"
|
|
url="http://jruby.org"
|
|
arch="noarch"
|
|
license="EPL GPL-2.0 LGPL-2.1 custom"
|
|
# libc6-compat: https://github.com/jnr/jnr-posix/issues/73
|
|
depends="$pkgname-libs java-jffi-native>=1.2 libc6-compat>=1.1.12-r5 openjdk8-jre-base"
|
|
makedepends="openjdk8 zip"
|
|
subpackages="
|
|
$pkgname-did_you_mean
|
|
$pkgname-irb
|
|
$pkgname-minitest
|
|
$pkgname-net-telnet:net_telnet
|
|
$pkgname-power_assert
|
|
$pkgname-rake
|
|
$pkgname-rdoc
|
|
$pkgname-readline
|
|
$pkgname-test-unit:test_unit
|
|
$pkgname-libs"
|
|
# jruby (launch script): https://github.com/jruby/jruby/pull/1860
|
|
source="https://s3.amazonaws.com/jruby.org/downloads/$pkgver/$pkgname-bin-$pkgver.tar.gz
|
|
jruby"
|
|
builddir="$srcdir/$pkgname-$pkgver"
|
|
|
|
_destdir="/usr/share/$pkgname"
|
|
_bindir="$_destdir/bin"
|
|
_rubydir="$_destdir/lib/ruby"
|
|
_gemdir="$_rubydir/gems/shared"
|
|
_stdlibdir="$_rubydir/stdlib"
|
|
|
|
prepare() {
|
|
cd "$builddir"/bin
|
|
rm *.bat *.dll *.exe
|
|
rm jirb_swing jruby jruby200.sh jruby.*
|
|
|
|
cd "$builddir"/lib/ruby/stdlib
|
|
rm -r win32 Win32API.rb
|
|
|
|
# Remove useless native binaries from JARs.
|
|
zip -qd jline/jline/*/jline-*.jar META-INF/native/*
|
|
zip -qd "$builddir"/lib/jruby.jar jni/*
|
|
}
|
|
|
|
check() (
|
|
cd "$srcdir"
|
|
|
|
export JRUBY_HOME="$builddir"
|
|
sh jruby --version
|
|
sh jruby -e 'puts "Hello, world!"'
|
|
)
|
|
|
|
package() {
|
|
cd "$builddir"
|
|
|
|
install -m644 -D "$builddir"/lib/jruby.jar \
|
|
"$pkgdir"$_destdir/lib/jruby.jar
|
|
|
|
install -m755 -D "$srcdir"/jruby "$pkgdir"$_bindir/jruby
|
|
|
|
# Some of the below copied files will be moved to subpackages by split functions.
|
|
|
|
install -dm755 "$pkgdir"$_rubydir
|
|
cp -r lib/ruby/gems lib/ruby/stdlib "$pkgdir"$_destdir/lib/ruby/
|
|
|
|
cp bin/* "$pkgdir"$_bindir/
|
|
|
|
install -dm755 "$pkgdir"/usr/bin
|
|
local file; for file in jgem jirb jruby jrubyc; do
|
|
ln -sf $_bindir/$file "$pkgdir"/usr/bin/$file
|
|
done
|
|
|
|
install -m644 -D COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING
|
|
}
|
|
|
|
did_you_mean() {
|
|
pkgdesc="Did you mean? experience in JRuby"
|
|
depends="$pkgname"
|
|
|
|
_mvgem did_you_mean
|
|
}
|
|
|
|
irb() {
|
|
pkgdesc="Interactive JRuby console"
|
|
depends="$pkgname $pkgname-readline"
|
|
|
|
_mvgem irb
|
|
_mv $_bindir/irb usr/bin/jirb
|
|
}
|
|
|
|
minitest() {
|
|
pkgdesc="Ruby testing tool supporting TDD, BDD, mocking, and benchmarking"
|
|
depends="$pkgname"
|
|
|
|
_mvgem minitest
|
|
}
|
|
|
|
net_telnet() {
|
|
pkgdesc="Telnet client functionality for JRuby"
|
|
depends="$pkgname"
|
|
|
|
_mvgem net-telnet
|
|
}
|
|
|
|
power_assert() {
|
|
pkgdesc="Power Assert for JRuby"
|
|
depends="$pkgname"
|
|
|
|
_mvgem power_assert
|
|
}
|
|
|
|
rake() {
|
|
pkgdesc="Ruby based make-like utility."
|
|
depends="$pkgname"
|
|
|
|
_mvgem rake
|
|
_mv $_bindir/rake
|
|
}
|
|
|
|
rdoc() {
|
|
pkgdesc="Ruby documentation tool"
|
|
depends="$pkgname $pkgname-irb"
|
|
|
|
_mvgem rdoc
|
|
_mv $_bindir/rdoc $_bindir/ri
|
|
}
|
|
|
|
readline() {
|
|
pkgdesc="Readline support for JRuby"
|
|
depends="$pkgname java-jansi-native"
|
|
|
|
_mv $_stdlibdir/jline
|
|
mv "$pkgdir"$_stdlibdir/readline* "$subpkgdir"$_stdlibdir/
|
|
}
|
|
|
|
test_unit() {
|
|
pkgdesc="Legacy xUnit family unit testing framework for JRuby"
|
|
depends="$pkgname $pkgname-power_assert"
|
|
|
|
_mvgem test-unit
|
|
_mv $_stdlibdir/test $_bindir/testrb
|
|
}
|
|
|
|
libs() {
|
|
pkgdesc="JRuby's standard libraries"
|
|
depends=""
|
|
|
|
_mv $_rubydir/gems $_rubydir/stdlib
|
|
}
|
|
|
|
|
|
_mv() {
|
|
local path; for path in "$@"; do
|
|
mkdir -p "$subpkgdir"/${path%/*}
|
|
mv "$pkgdir"/$path "$subpkgdir"/${path%/*}/
|
|
done
|
|
}
|
|
|
|
_mvgem() {
|
|
local name="$1"
|
|
local file
|
|
|
|
cd "$pkgdir"
|
|
for file in ./$_stdlibdir/$name.rb \
|
|
./$_stdlibdir/$name \
|
|
./$_gemdir/gems/$name-* \
|
|
./$_gemdir/specifications/default/$name-*; do
|
|
[ -e "$pkgdir"/$file ] || continue
|
|
_mv "$file"
|
|
done
|
|
}
|
|
|
|
sha512sums="d15ae0c60421951b830524acd21a0f2a56f480e983b148a2722cd36afed8e99a41f518eb8a679bfa2cf87f08637e81c24ea88be40c0a5390e081322f1fc6f8da jruby-bin-9.1.14.0.tar.gz
|
|
f2906a0136f437eaa119eae26d93b1a8e3411bc4ccee9453debf7a5d57bce767100b36a660db42184fd8398ff258455c3f2a8ef1082c907285b48d1b9b218bc2 jruby"
|