aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2021-10-18 14:00:31 +0200
committerJakub Jirutka <jakub@jirutka.cz>2021-10-18 18:44:44 +0200
commit4355713025637fcdb8e77969295f5c6fa9af53e6 (patch)
tree4d0b5885da3a7f08041ae5c0a12ead4acbca06aa
parentb9e6139642e4041cdf81341db782384dc12df154 (diff)
downloadaports-4355713025637fcdb8e77969295f5c6fa9af53e6.tar.gz
aports-4355713025637fcdb8e77969295f5c6fa9af53e6.tar.bz2
aports-4355713025637fcdb8e77969295f5c6fa9af53e6.tar.xz
main/ruby: cleanup aport a bit
-rw-r--r--main/ruby/APKBUILD51
1 files changed, 18 insertions, 33 deletions
diff --git a/main/ruby/APKBUILD b/main/ruby/APKBUILD
index 758a22598a..16a28fb9e3 100644
--- a/main/ruby/APKBUILD
+++ b/main/ruby/APKBUILD
@@ -143,25 +143,30 @@ package() {
install -m 644 -D COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING
+ cd "$pkgdir"
+
# Remove bundled gem bundler; it's provided by a separate aport/package
# ruby-bundler.
- subpkgdir=".trash" _mvgem bundler && rm -Rf .trash
+ rm -rf ./$_rubydir/bundler
+ rm ./$_rubydir/bundler.rb
+ rm -rf ./$_gemdir/gems/bundler-*
+ rm ./$_gemdir/specifications/default/bundler-*.gemspec
rm usr/bin/bundle usr/bin/bundler
# Remove bundled CA certificates; they are provided by ca-certificates.
- rm "$pkgdir"/$_rubydir/rubygems/ssl_certs/*/*.pem
- rmdir "$pkgdir"/$_rubydir/rubygems/ssl_certs/* || true
+ rm ./$_rubydir/rubygems/ssl_certs/*/*.pem
+ rmdir ./$_rubydir/rubygems/ssl_certs/* || true
- rm -Rf "$pkgdir"/$_gemdir/cache/*
+ rm -Rf ./$_gemdir/cache/*
- if [ -d "$pkgdir"/usr/local ]; then
- local f=$(cd "$pkgdir" ; find usr/local -type f)
+ if [ -d usr/local ]; then
+ local f=$(find usr/local -type f)
if [ -n "$f" ]; then
error "Found files in /usr/local:"
echo "$f"
return 1
fi
- rm -r "$pkgdir"/usr/local
+ rm -r usr/local
fi
}
@@ -170,17 +175,18 @@ rdoc() {
license="Ruby"
depends="$pkgname"
- _mvgem rdoc
- _mv usr/bin/ri \
- usr/bin/rdoc
+ amove $_rubydir/rdoc
+ amove $_gemdir/gems/rdoc-*
+ amove $_gemdir/specifications/default/rdoc-*
+ amove usr/bin/ri
+ amove usr/bin/rdoc
}
libs() {
pkgdesc="Libraries necessary to run Ruby"
depends=""
- mkdir -p "$subpkgdir"/usr
- mv "$pkgdir"/usr/lib "$subpkgdir"/usr/
+ amove usr/lib
}
full() {
@@ -198,27 +204,6 @@ full() {
done < "$builddir"/gems/bundled_gems
}
-_mv() {
- local i; for i in "$@"; do
- mkdir -p "$subpkgdir"/${i%/*}
- mv "$pkgdir"/$i "$subpkgdir"/${i%/*}/
- done
-}
-
-_mvgem() {
- cd "$pkgdir"
- local path; for path in ./$_rubydir/$1.rb \
- ./$_rubydir/$1 \
- ./$_rubydir/$_chost/$1 \
- ./$_rubydir/$_chost/$1.so \
- ./$_gemdir/gems/$1-* \
- ./$_gemdir/specifications/$1-* \
- ./$_gemdir/specifications/default/$1-* ; do
- [ ! -e "$pkgdir/$path" ] || _mv "$path"
- done
-}
-
-
sha512sums="
e1fba6f5429b5fca9c3f52a32535615fcf95fafa415efc71c46db4cce159f249112c01574c305026be5c50140335696042e47a74194caea045acbfaa4da738cd ruby-3.0.2.tar.gz
59f85e23f9487b6a3ff1a5de9f73c243f23d2f9538d2628b4ba1fe62b47d5cac254e812ae2a0212d5866fb9df89125b32829b77f8d9397a2fcc4d39d837916e9 get-ruby_nonempty_memcpy-to-have-c-linkage.patch