aboutsummaryrefslogtreecommitdiff
path: root/linux/makepkg/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'linux/makepkg/PKGBUILD')
-rw-r--r--linux/makepkg/PKGBUILD65
1 files changed, 65 insertions, 0 deletions
diff --git a/linux/makepkg/PKGBUILD b/linux/makepkg/PKGBUILD
new file mode 100644
index 0000000..95a0a54
--- /dev/null
+++ b/linux/makepkg/PKGBUILD
@@ -0,0 +1,65 @@
+# Maintainer: Aqua-sama <aqua@iserlohn-fortress.net>
+
+pkgname=smolbote-hg
+pkgver=0.0.0
+pkgrel=1
+pkgdesc='Yet another no-frills browser'
+url="https://neueland.iserlohn-fortress.net/smolbote"
+
+arch=('x86_64')
+license=('GPL3')
+
+# -hg replace the old -git package
+replaces=('smolbote-git')
+
+depends=('qt5-webengine' 'libconfig')
+makedepends=('mercurial' 'cmake' 'pkg-config' 'ninja' 'qt5-webengine' 'libconfig')
+
+# this is the central repository
+source=("smolbote-hg::hg+https://neueland.iserlohn-fortress.net/smolbote.hg")
+# if you're test building, you want to hg serve your own repo
+#source=("smolbote-hg::hg+http://localhost:8000")
+sha512sums=('SKIP')
+
+# any patches go here
+#prepare() {
+#}
+
+pkgver() {
+ cd smolbote-hg
+ printf "r%s.%s" "$(hg identify -n)" "$(hg identify -i)"
+}
+
+build() {
+ rm -rf "$pkgname-$pkgver"
+ mkdir "$pkgname-$pkgver"
+ cd "$pkgname-$pkgver"
+
+ # CMake Options
+ # build type
+ _cmake_options="-DCMAKE_BUILD_TYPE=Release"
+
+ # install prefix, or where should the binary be installed
+ _cmake_options="$_cmake_options -DCMAKE_INSTALL_PREFIX=$pkgdir/usr/local"
+
+ # compiler
+ _cmake_options="$_cmake_options -DCMAKE_C_COMPILER=/usr/bin/clang"
+ _cmake_options="$_cmake_options -DCMAKE_CXX_COMPILER=/usr/bin/clang++"
+
+ # use libc++ instead of libstdc++
+ #_cmake_options="$_cmake_options -DUseLibCpp=On"
+
+ # build system
+ _cmake_options="$_cmake_options -GNinja"
+
+ # Generate a makefile
+ cmake $_cmake_options "$srcdir/smolbote-hg"
+
+ # build
+ ninja
+}
+
+package() {
+ cd "$pkgname-$pkgver"
+ ninja install
+}