aboutsummaryrefslogtreecommitdiff
path: root/apks/firefly3/APKBUILD
diff options
context:
space:
mode:
authorGabriel Arakaki Giovanini <mail@gabrielgio.me>2022-11-07 20:04:30 +0000
committerGabriel Arakaki Giovanini <mail@gabrielgio.me>2022-11-07 20:04:30 +0000
commit400ba1808f11f8e4814df6bdb17861d856efb107 (patch)
tree04be03ca31a8b8edc80b9aa2c20020212bf94501 /apks/firefly3/APKBUILD
parent3f8ef10024a2c5b7d94ee91c7b481a742bfcd156 (diff)
downloadapkbuilds-400ba1808f11f8e4814df6bdb17861d856efb107.tar.gz
apkbuilds-400ba1808f11f8e4814df6bdb17861d856efb107.tar.bz2
apkbuilds-400ba1808f11f8e4814df6bdb17861d856efb107.zip
feat: Finish firefly APKBUILD
Add dependencies and subpackages' dependencies.
Diffstat (limited to 'apks/firefly3/APKBUILD')
-rw-r--r--apks/firefly3/APKBUILD67
1 files changed, 60 insertions, 7 deletions
diff --git a/apks/firefly3/APKBUILD b/apks/firefly3/APKBUILD
index a1b4f5e..3772133 100644
--- a/apks/firefly3/APKBUILD
+++ b/apks/firefly3/APKBUILD
@@ -7,12 +7,39 @@ url="https://firefly-iii.org"
arch="noarch"
license="AGPL-3.0-only"
_php=php8
-_php_mods="-curl -zip -sodium -gd -xml -mbstring -bcmath -fileinfo -session
- -tokenizer -xmlwriter -dom -shmop"
+_php_mods="
+ -curl
+ -zip
+ -sodium
+ -gd
+ -xml
+ -mbstring
+ -bcmath
+ -fileinfo
+ -session
+ -tokenizer
+ -xmlwriter
+ -dom
+ -shmop
+"
depends="$_php ${_php_mods//-/$_php-}"
-_php_makemods="-intl -pdo -simplexml"
+_php_makemods="
+ -intl
+ -pdo
+ -simplexml
+"
makedepends="$_php ${_php_makemods//-/$_php-} composer"
-source="${pkgname}-${pkgver}.tar.gz::https://github.com/firefly-iii/firefly-iii/archive/refs/tags/$pkgver.tar.gz"
+subpackages="
+ $pkgname-nginx:_nginx:noarch
+ $pkgname-mysql:_mysql
+ $pkgname-psql:_psql
+ $pkgname-sqlite:_sqlite
+"
+install="$pkgname.post-install"
+source="
+ ${pkgname}-${pkgver}.tar.gz::https://github.com/firefly-iii/firefly-iii/archive/refs/tags/$pkgver.tar.gz
+ firefly.nginx.conf
+"
options="!check" # no clue how to run test on this
builddir="$srcdir/firefly-iii-$pkgver/"
@@ -20,16 +47,42 @@ package() {
local wwwdir="usr/share/webapps/$pkgname"
mkdir -p "$pkgdir"
- cd "$pkgdir"
+ cd "$pkgdir"
- mkdir -p ./${wwwdir%/*}
- cp -a "$builddir" ./$wwwdir
+ mkdir -p ./${wwwdir%/*}
+ cp -a "$builddir" ./$wwwdir
chmod +x ./$wwwdir/artisan
cd "$wwwdir" && composer install --prefer-dist --no-dev --no-scripts
+}
+
+_mysql() {
+ depends="firefly3 php8-pdo_mysql"
+ pkgdesc="Mysql dependencies for $pkgname"
+ mkdir -p "$subpkgdir"/usr
+}
+
+_psql() {
+ depends=" firefly3 php8-pdo_pgsql php8-pgsql"
+ pkgdesc="Postgresql dependencies for $pkgname"
+ mkdir -p "$subpkgdir"/usr
+}
+_sqlite() {
+ depends="firefly3 php8-pdo_sqlite"
+ pkgdesc="Sqlite dependencies for $pkgname"
+ mkdir -p "$subpkgdir"/usr
}
+
+_nginx() {
+ depends="firefly3"
+ pkgdesc="nginx configuration for $pkgname"
+ install -Dm644 "$srcdir/firefly.nginx.conf" \
+ "$subpkgdir"/etc/nginx/http.d/firefly.conf
+}
+
sha512sums="
a59f89305eeb6cdb301ca86a6a3dfacd90497ce887b59b7c426bef341e7a070efc0d430c6e40277273e5aa56b86271c652f80e696cc53f0788b0624dd1b66a46 firefly3-5.7.13.tar.gz
+9d32e8e8bd805b09cd429eacc42fe9e746570cdc867531ac47a0b31801378e5e0fc357ef88e8d5c14617ba1887a3789a9d2f7150111b497377380df7ccdd08a7 firefly.nginx.conf
"