60 lines
1.4 KiB
Bash
60 lines
1.4 KiB
Bash
#!/usr/bin/bash
|
|
# JOBoRun : Jwm OpenBox Obarun RUNit
|
|
# Maintainer : Joe Bo Run <joborun@disroot.org>
|
|
# PkgSource : url="https://gittea.disroot.org/joborun-pkg/jobextra/$pkgname"
|
|
# Website : https://pozol.eu
|
|
#-----------------------------------------| DESCRIPTION |---------------------------------------
|
|
|
|
pkgname=duktape
|
|
pkgver=2.7.0
|
|
pkgrel=06
|
|
pkgdesc='Embeddable Javascript engine'
|
|
url='https://duktape.org/'
|
|
depends=(glibc)
|
|
provides=(libduktape{,d}.so)
|
|
source=("https://duktape.org/$pkgname-$pkgver.tar.xz")
|
|
# https://duktape.org/download.html
|
|
|
|
prepare() {
|
|
cd $pkgname-$pkgver
|
|
|
|
# tools/configure.py needs Python 2
|
|
sed -i 's/^#undef DUK_USE_FASTINT$/#define DUK_USE_FASTINT/' src/duk_config.h
|
|
|
|
# Add missing NEEDED on libm.so
|
|
sed -i 's/duktape\.c/& -lm/' Makefile.sharedlibrary
|
|
}
|
|
|
|
_make() (
|
|
local make_options=(
|
|
-f Makefile.sharedlibrary
|
|
INSTALL_PREFIX=/usr
|
|
)
|
|
|
|
make "${make_options[@]}" "$@"
|
|
|
|
)
|
|
|
|
build() {
|
|
cd $pkgname-$pkgver
|
|
_make
|
|
}
|
|
|
|
package() {
|
|
cd $pkgname-$pkgver
|
|
_make DESTDIR="$pkgdir" install
|
|
install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 LICENSE.txt
|
|
}
|
|
|
|
# getver: github.com/svaarala/duktape
|
|
|
|
#---- arch license gpg-key & sha256sums ----
|
|
|
|
arch=(x86_64)
|
|
|
|
license=(MIT)
|
|
|
|
sha256sums=(90f8d2fa8b5567c6899830ddef2c03f3c27960b11aca222fa17aa7ac613c2890) # duktape-2.7.0.tar.xz
|
|
|
|
## 5d8404b861de0d6424955291932f8294e2000401dd3773d5a3b736c6601e98da duktape-2.7.0-06-x86_64.pkg.tar.lz
|