pkgname=ruby pkgver=3.4.1 pkgrel=1 pkgdesc="An object-oriented language for quick and easy programming" arch=('x86_64') url="https://www.ruby-lang.org/en" license=('BSD-2-Clause') depends=( 'gcc-libs' 'gdbm' 'glibc' 'gmp' 'libffi' 'libxcrypt' 'libyaml' 'openssl' 'readline' 'zlib' ) options=('!emptydirs' '!lto') source=(https://cache.ruby-lang.org/pub/ruby/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz) sha256sums=(018d59ffb52be3c0a6d847e22d3fd7a2c52d0ddfee249d3517a0c8c6dbfa70af) build() { cd ${pkgname}-${pkgver} export CFLAGS="${CFLAGS/_FORTIFY_SOURCE=3/_FORTIFY_SOURCE=2}" export CXXFLAGS="${CXXFLAGS/_FORTIFY_SOURCE=3/_FORTIFY_SOURCE=2}" local configure_args=( --disable-rpath --enable-shared --without-valgrind --without-baseruby ac_cv_func_qsort_r=no --with-dbm-type=gdbm_compat --docdir=/usr/share/doc/${pkgname}-${pkgver} ${configure_options} ) ./configure ${configure_args[@]} make make capi } package() { cd ${pkgname}-${pkgver} make DESTDIR=${pkgdir} install }