summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorNarrat2024-02-23 22:48:33 +0100
committerNarrat2024-02-23 22:49:48 +0100
commit4e49db01d1974bc65a989d82da52b40c5ef9ff94 (patch)
tree4ab3071cf7e9c6cb992115acc56ef4fab1f306f5 /PKGBUILD
parentfddae42777a7fd7724eedba9fe9de39d99dbb171 (diff)
downloadaur-monkey.tar.gz
monkey: fix build
add patch which adjusts the include dir. And add the configure step again in package(). If that is omitted it will install the files into /usr/local
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD26
1 files changed, 23 insertions, 3 deletions
diff --git a/PKGBUILD b/PKGBUILD
index c89370601ad7..4ecda3e9443d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=monkey
pkgver=1.7.3
-pkgrel=1
+pkgrel=2
pkgdesc='Lightweight and powerful web server'
url='https://github.com/monkey/monkey'
arch=('i686' 'x86_64')
@@ -10,10 +10,18 @@ license=('Apache')
depends=('mbedtls')
makedepends=('cmake')
options=('!emptydirs')
-source=("${pkgname}-${pkgver}.tar.gz::${url}/archive/refs/tags/v${pkgver}.tar.gz")
-sha1sums=('3ffb76235aec734188fbc41f97ef661cf05cf9ab')
+source=("${pkgname}-${pkgver}.tar.gz::${url}/archive/refs/tags/v${pkgver}.tar.gz"
+ 0001-fix_include.patch)
+sha1sums=('3ffb76235aec734188fbc41f97ef661cf05cf9ab'
+ '9346e0c2ad44a9019e461b42f4a2ab860584236a')
+prepare() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ # Fix include dir (not include/, but include/monkey/)
+ patch -Np2 -i "${srcdir}"/0001-fix_include.patch
+}
+
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
mkdir build
@@ -34,6 +42,18 @@ build() {
package() {
cd "${srcdir}/${pkgname}-${pkgver}"
+ ./configure \
+ --malloc-libc \
+ --mbedtls-shared \
+ --prefix=/usr \
+ --sbindir=/usr/bin \
+ --libdir=/usr/lib \
+ --includedir=/usr/include \
+ --sysconfdir=/etc/monkey \
+ --webroot=/srv/http \
+ --default-port=80 \
+ --default-user=http
+
make CMAKE_COMMAND="/usr/bin/cmake" RM="/usr/bin/cmake" CMAKE_SOURCE_DIR="." CMAKE_BINARY_DIR="." DESTDIR="${pkgdir}" install
rm -fr "${pkgdir}"/srv/http
}