aboutsummaryrefslogtreecommitdiff
path: root/linux/makepkg
diff options
context:
space:
mode:
authorAqua-sama <aqua@iserlohn-fortress.net>2018-01-16 15:41:45 +0100
committerAqua-sama <aqua@iserlohn-fortress.net>2018-01-16 15:41:45 +0100
commitc3b20dc648cfd02d3a26bbd6fab0db5a7d39fc05 (patch)
tree573ad55f55da490d02d500875de8c53848702f59 /linux/makepkg
parentConverted repository to mercurial (diff)
downloadsmolbote-c3b20dc648cfd02d3a26bbd6fab0db5a7d39fc05.tar.xz
Fixed build scripts for use with the mercurial repository
Diffstat (limited to 'linux/makepkg')
-rw-r--r--linux/makepkg/PKGBUILD (renamed from linux/makepkg/PKGBUILD.aqua)19
-rw-r--r--linux/makepkg/PKGBUILD.generic47
2 files changed, 13 insertions, 53 deletions
diff --git a/linux/makepkg/PKGBUILD.aqua b/linux/makepkg/PKGBUILD
index 72b8536..95a0a54 100644
--- a/linux/makepkg/PKGBUILD.aqua
+++ b/linux/makepkg/PKGBUILD
@@ -1,6 +1,6 @@
# Maintainer: Aqua-sama <aqua@iserlohn-fortress.net>
-pkgname=smolbote-git
+pkgname=smolbote-hg
pkgver=0.0.0
pkgrel=1
pkgdesc='Yet another no-frills browser'
@@ -9,10 +9,16 @@ 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=('git' 'cmake' 'pkg-config' 'ninja' 'qt5-webengine' 'libconfig')
+makedepends=('mercurial' 'cmake' 'pkg-config' 'ninja' 'qt5-webengine' 'libconfig')
-source=("smolbote-git::git+git://neueland.iserlohn-fortress.net/smolbote.git")
+# 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
@@ -20,8 +26,8 @@ sha512sums=('SKIP')
#}
pkgver() {
- cd smolbote-git
- echo "$(git describe --long --tags | tr - .)"
+ cd smolbote-hg
+ printf "r%s.%s" "$(hg identify -n)" "$(hg identify -i)"
}
build() {
@@ -37,6 +43,7 @@ build() {
_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++
@@ -46,7 +53,7 @@ build() {
_cmake_options="$_cmake_options -GNinja"
# Generate a makefile
- cmake $_cmake_options "$srcdir/smolbote-git"
+ cmake $_cmake_options "$srcdir/smolbote-hg"
# build
ninja
diff --git a/linux/makepkg/PKGBUILD.generic b/linux/makepkg/PKGBUILD.generic
deleted file mode 100644
index 98f132f..0000000
--- a/linux/makepkg/PKGBUILD.generic
+++ /dev/null
@@ -1,47 +0,0 @@
-# Maintainer: Aqua-sama <aqua@iserlohn-fortress.net>
-
-pkgname=smolbote-git
-pkgver=0.0.0
-pkgrel=1
-pkgdesc='Yet another no-frills browser'
-url="https://neueland.iserlohn-fortress.net/smolbote"
-
-arch=('x86_64')
-license=('GPL3')
-
-depends=('qt5-base' 'qt5-webengine')
-makedepends=('git' 'cmake' 'libconfig' 'pkg-config')
-
-source=("smolbote-git::git+git://neueland.iserlohn-fortress.net/smolbote.git")
-sha512sums=('SKIP')
-
-# any patches go here
-#prepare() {
-#}
-
-pkgver() {
- cd smolbote-git
- echo "$(git describe --long --tags | tr - .)"
-}
-
-build() {
- rm -rf "$pkgname-$pkgver"
- mkdir "$pkgname-$pkgver"
- cd "$pkgname-$pkgver"
-
- # Generate a makefile
- # Adjust the install prefix as necessary, default is /usr/local/bin
- cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr/local "$srcdir/smolbote-git"
-
- # Use this if you want to link with libc++ instead
- # This requires clang, since gcc doesn't understand the concept of not using libstdc++
- #cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr/local -DCMAKE_CXX_COMPILER=/usr/bin/clang++ -DUseLibCpp=On "$srcdir/smolbote-git"
-
- # build, with 4 threads
- make
-}
-
-package() {
- cd "$pkgname-$pkgver"
- make DESTDIR="$pkgdir/" install
-}