Add check, optdepends, checkdepends

Signed-off-by: Страхиња Радић <contact@strahinja.org>
This commit is contained in:
Страхиња Радић 2024-03-06 10:00:01 +01:00
parent 93a6c0fb9e
commit 6f734071a1
No known key found for this signature in database
GPG key ID: 9D31EA3651E8DF5A
2 changed files with 24 additions and 2 deletions

View file

@ -1,10 +1,15 @@
pkgbase = sled
pkgdesc = Simple text editor
pkgver = 0.12.5
pkgrel = 1
pkgrel = 2
url = https://strahinja.srht.site/sled
arch = x86_64
license = GPL3
checkdepends = perl
checkdepends = expect
optdepends = katex: For math mode
optdepends = git: For {git-log}
optdepends = imagemagick: For img tag attributes
source = sled-0.12.5.tar.gz::https://git.sr.ht/~strahinja/sled/archive/v0.12.5.tar.gz
md5sums = bc71a6663167ddd41d4afabdc255e689

View file

@ -1,15 +1,26 @@
# Maintainer: Strahinya Radich <contact@strahinja.org>
pkgname=sled
pkgver=0.12.5
pkgrel=1
pkgrel=2
pkgdesc="Simple text editor"
arch=('x86_64')
url="https://strahinja.srht.site/sled"
license=('GPL3')
source=("$pkgname-$pkgver.tar.gz::https://git.sr.ht/~strahinja/sled/archive/v$pkgver.tar.gz")
md5sums=('bc71a6663167ddd41d4afabdc255e689')
optdepends=(
'katex: For math mode'
'git: For {git-log}'
'imagemagick: For img tag attributes'
)
checkdepends=(
'perl'
'expect'
)
build() {
# Might need to add --nocheck to makepkg on systems using pacman only
# for test (Alpine)
cd $pkgname-v$pkgver
# Example on how to apply patches: dark theme patch (uncomment last
@ -20,6 +31,12 @@ build() {
# Example on how to disable configuration options: turn off wrap
# (uncomment next line)
#sed -i 's,^\(#define ENABLE_WRAP\),//\1,' config.h
FALLBACKVER=$pkgver-$pkgrel PREFIX="$pkgdir/usr" make -e all
}
check() {
cd $pkgname-v$pkgrel
make test
}
package() {