[arch-commits] Commit in fortune-mod/trunk (PKGBUILD)
George Rawlinson
grawlinson at archlinux.org
Sun Jun 20 03:43:42 UTC 2021
Date: Sunday, June 20, 2021 @ 03:43:42
Author: grawlinson
Revision: 965803
upgpkg: fortune-mod 3.6.1-1
* New upstream release
* Fix patches & build
Modified:
fortune-mod/trunk/PKGBUILD
----------+
PKGBUILD | 32 +++++++++++++++-----------------
1 file changed, 15 insertions(+), 17 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2021-06-20 03:21:33 UTC (rev 965802)
+++ PKGBUILD 2021-06-20 03:43:42 UTC (rev 965803)
@@ -1,9 +1,10 @@
# Maintainer: Kyle Keen <keenerd at gmail.com>
# Contributor: Kevin Piche <kevin at archlinux.org>
# Contributor: Dale Blount <archlinux at dale.us>
+# Contributor: George Rawlinson <grawlinson at archlinux.org>
pkgname=fortune-mod
-pkgver=2.12.0
+pkgver=3.6.1
pkgrel=1
pkgdesc="The Fortune Cookie Program from BSD games"
arch=('x86_64')
@@ -11,23 +12,20 @@
license=('BSD')
depends=('recode')
makedepends=('cmake' 'rinutils')
-source=("https://github.com/shlomif/fortune-mod/archive/fortune-mod-$pkgver.tar.gz")
-md5sums=('467b8071241e0e666a8a23f4a615e588')
+source=("https://github.com/shlomif/fortune-mod/releases/download/$pkgname-$pkgver/$pkgname-$pkgver.tar.xz"
+ 'not-a-game.patch')
+b2sums=('0ff684ee8aaf5eaabd75f187a3bff533ab4ee6e66c47c57fc700d2671006c8dff42f732fde78b40516f8ee907a52fc1965fb0ff257b12563d645f97c5ebc0031'
+ '3af374f348d42bf649199a79afc18a8f0dace50d2b4c8aa090a1a54ccffcb65bf069d26f0d1d417a395c5a3574f7376c5ae1ec8b97dd2385d6b4b944643b1215')
+
prepare() {
- cd "$srcdir/fortune-mod-fortune-mod-$pkgver/fortune-mod"
- # probably a better way to do this but it is baked in hard
- sed -i 's|/games/|/|' CMakeLists.txt
- sed -i 's|"sbin"|"bin"|' CMakeLists.txt
- sed -i 's|"games"|"bin"|' CMakeLists.txt
- sed -i 's|/games/fortunes|/fortune|' datfiles/{,off/}CMakeLists.txt
+ cd "$pkgname-$pkgver"
+ patch -p1 -i ../not-a-game.patch
}
build() {
- cd "$srcdir/fortune-mod-fortune-mod-$pkgver/fortune-mod"
- mkdir -p build
- cd build
- cmake .. \
+ cd "$pkgname-$pkgver"
+ cmake -B build -S . \
-DCMAKE_INSTALL_PREFIX=/usr \
-DNO_OFFENSIVE=OFF \
-DLOCALDIR=/usr/share/fortune/ \
@@ -34,12 +32,12 @@
-DLOCALODIR=/usr/share/fortune/off/ \
-DCOOKIEDIR=/usr/share/fortune/ \
-DOCOOKIEDIR=/usr/share/fortune/off/
- make REGEXDEFS='-DHAVE_REGEX_H -DPOSIX_REGEX -DHAVE_STDBOOL'
+ make -C build
}
package() {
- cd "$srcdir/fortune-mod-fortune-mod-$pkgver/fortune-mod/build"
- make DESTDIR="$pkgdir" \
+ cd "$pkgname-$pkgver"
+ make -C build DESTDIR="$pkgdir" \
FORTDIR="$pkgdir/usr/bin" \
COOKIEDIR="$pkgdir/usr/share/fortune" \
BINDIR="$pkgdir/usr/bin" \
@@ -46,5 +44,5 @@
BINMANDIR="$pkgdir/usr/share/man/man1" \
FORTMANDIR="$pkgdir/usr/share/man/man6" install
rm "$pkgdir/usr/share/fortune/"{,off/}*.u8
- install -Dm644 ../../LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+ install -Dm644 COPYING.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}
More information about the arch-commits
mailing list