summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorStanda Lukeš2023-11-17 21:06:10 +0100
committerStanda Lukeš2023-11-17 21:08:32 +0100
commita3f29ad42cbf67011154d2c2a9f69730aab04a73 (patch)
tree3c1e218b957e2c9ae7e06246993bbffc05d74a1f
downloadaur-a3f29ad42cbf67011154d2c2a9f69730aab04a73.tar.gz
Initial commit
-rw-r--r--.SRCINFO21
-rw-r--r--PKGBUILD44
-rw-r--r--factorio-yafc3
-rw-r--r--factorio-yafc.desktop10
4 files changed, 78 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..f8629355fbc4
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,21 @@
+pkgbase = factorio-yafc-git
+ pkgdesc = Yet Another Factorio Calculator: Powerful calculator/analyser that works with mods
+ pkgver = v0.5.8.51.gfd80865
+ pkgrel = 1
+ url = https://github.com/ShadowTheAge/yafc
+ arch = x86_64
+ license = GPL
+ makedepends = git
+ makedepends = dotnet-sdk
+ depends = sdl2
+ depends = sdl2_ttf
+ depends = sdl2_image
+ depends = dotnet-runtime
+ source = factorio-yafc-git::git+https://github.com/ShadowTheAge/yafc.git
+ source = factorio-yafc.desktop
+ source = factorio-yafc
+ sha256sums = SKIP
+ sha256sums = f4d87b77fd861031300921d1405dfd475b492a7214e4b3016f9788ed1c822ec0
+ sha256sums = 755616cb54c512258f606cd2bbe3e267b1aa4dedcc694549044038776b03d827
+
+pkgname = factorio-yafc-git
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..966b6197a9d0
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,44 @@
+# Maintainer: Standa Lukeš <archpkg@exyi.cz>
+
+pkgname=factorio-yafc-git
+pkgdesc="Yet Another Factorio Calculator: Powerful calculator/analyser that works with mods"
+pkgver=v0.5.8.51.gfd80865
+pkgrel=1
+arch=(x86_64)
+url=https://github.com/ShadowTheAge/yafc
+license=(GPL)
+depends=(sdl2 sdl2_ttf sdl2_image dotnet-runtime)
+makedepends=(git dotnet-sdk)
+optdepends=()
+provides=()
+conflicts=()
+options=()
+source=($pkgname::git+https://github.com/ShadowTheAge/yafc.git
+ factorio-yafc.desktop factorio-yafc)
+sha256sums=('SKIP'
+ 'f4d87b77fd861031300921d1405dfd475b492a7214e4b3016f9788ed1c822ec0'
+ '755616cb54c512258f606cd2bbe3e267b1aa4dedcc694549044038776b03d827')
+
+pkgver() {
+ cd "$srcdir/$pkgname"
+ git describe --tags --long | sed 's|Release-||;s|[_-]|.|g'
+}
+
+prepare() {
+ cd "$srcdir/$pkgname/YAFC"
+ dotnet restore
+}
+
+build() {
+ cd "$srcdir/$pkgname/YAFC"
+ dotnet publish --use-current-runtime --self-contained false -o "../publish"
+}
+
+package() {
+ cd "$srcdir/$pkgname"
+ install -d "$pkgdir/usr/lib"
+ cp -a "$srcdir/$pkgname/publish" "$pkgdir/usr/lib/$pkgname"
+ install -Dm755 "$srcdir/factorio-yafc" "$pkgdir/usr/bin/factorio-yafc" # launch script adding --roll-forward Major to make it run on newer .NET versions
+ install -Dm644 "$srcdir/factorio-yafc.desktop" "$pkgdir"/usr/share/applications/factorio-yafc.desktop
+}
+
diff --git a/factorio-yafc b/factorio-yafc
new file mode 100644
index 000000000000..2bdcaf0bd107
--- /dev/null
+++ b/factorio-yafc
@@ -0,0 +1,3 @@
+#!/usr/bin/bash
+
+dotnet --roll-forward Major /usr/lib/factorio-yafc-git/YAFC.dll "$@"
diff --git a/factorio-yafc.desktop b/factorio-yafc.desktop
new file mode 100644
index 000000000000..889f04808577
--- /dev/null
+++ b/factorio-yafc.desktop
@@ -0,0 +1,10 @@
+#!/usr/bin/env xdg-open
+
+[Desktop Entry]
+Version=1.0
+Type=Application
+Terminal=false
+Name=Yet Another Factorio Calculator (YAFC)
+Exec=factorio-yafc %U
+Comment=Powerful Factorio calculator/analyser that works with mods
+Categories=Game;