summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorPellegrino Prevete2019-04-16 20:50:33 +0200
committerPellegrino Prevete2019-04-16 20:50:33 +0200
commit1195691a2aab17d4c444605003400cf6c7a0b1af (patch)
tree67f8ef1e1e2a52552f11c41147caa5a7af021115
downloadaur-1195691a2aab17d4c444605003400cf6c7a0b1af.tar.gz
Initial release
-rw-r--r--.SRCINFO19
-rw-r--r--PKGBUILD117
2 files changed, 136 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..747a660594dd
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,19 @@
+pkgbase = barrier-git
+ pkgdesc = Open-source KVM software based on Synergy (GUI)
+ pkgver = 2.1.2
+ pkgrel = 2
+ url = https://github.com/debauchee/barrier
+ arch = any
+ license = GPLv2
+ makedepends = python-setuptools
+ depends = hicolor-icon-theme
+ depends = qt5-base
+ depends = barrier-headless-git
+ depends = cmake
+ provides = barrier
+ conflicts = barrier
+ source = barrier-git::git+https://github.com/debauchee/barrier.git
+ sha256sums = SKIP
+
+pkgname = barrier-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..84cbdf930bf7
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,117 @@
+# Maintainer: Pellegrino Prevete <pellegrinoprevete@gmail.com>
+
+pkgname=(barrier-git barrier-headless-git)
+pkgver=2.1.2
+pkgrel=2
+pkgdesc="Open-source KVM software based on Synergy"
+url="https://github.com/debauchee/barrier"
+license=("custom:GPL2WithOpenSSLException")
+source=(
+ "barrier-git::git+https://github.com/debauchee/barrier.git"
+)
+sha256sums=('SKIP')
+arch=(x86_64)
+depends=(
+ # Barrier core dependencies:
+ curl
+ avahi
+ libx11
+ libxrandr
+ libxext
+ libxinerama
+ xorgproto
+ libxtst
+ libxi
+ libsm
+ libice
+ openssl
+)
+makedepends=(
+ cmake
+
+ # Barrier GUI dependencies:
+ qt5-base
+ hicolor-icon-theme
+)
+
+prepare() {
+ cd "barrier-git"
+
+ for patch in "${srcdir?}"/*.patch; do
+ if [ -f "${patch?}" ]; then
+ patch -Np1 -i "${patch?}"
+ fi
+ done
+}
+
+build() {
+ cd "barrier-git"
+
+ mkdir -p build
+ cd build
+
+ cmake -G "Unix Makefiles" \
+ -D CMAKE_BUILD_TYPE:STRING=Release \
+ -D CMAKE_INSTALL_PREFIX:STRING=/usr \
+ -D BARRIER_REVISION:STRING=00000000 \
+ -D BARRIER_VERSION_STAGE:STRING=RELEASE \
+ ..
+ make
+}
+
+_package_common() {
+ # Install binaries:
+ cd "barrier-git/build"
+ DESTDIR="${pkgdir?}" make install
+
+ # Install the license:
+ cd ..
+ install -m 644 -D LICENSE "${pkgdir?}/usr/share/licenses/${pkgname?}/LICENSE"
+
+ # Install the manpages:
+ mkdir -p "${pkgdir?}/usr/share/man/man1"
+ install -m 644 doc/*.1 "${pkgdir?}/usr/share/man/man1"
+
+ # Install the examples:
+ mkdir -p "${pkgdir?}/usr/share/doc/${pkgname?}"
+ install -m 644 doc/barrier.conf* "${pkgdir?}/usr/share/doc/${pkgname?}"
+}
+
+package_barrier-git() {
+ pkgdesc="Open-source KVM software based on Synergy (GUI)"
+ depends=(
+ "barrier-headless-git=${pkgver?}-${pkgrel?}"
+ qt5-base
+ hicolor-icon-theme
+ )
+
+ # Install all the files:
+ _package_common
+
+ # Now go and delete files that are already in
+ # barrier-headless:
+ for file in \
+ /usr/share/doc \
+ /usr/share/man \
+ /usr/bin/barrier{s,c} \
+ ;do
+ rm -rf "${pkgdir:?}/${file:?}"
+ done
+}
+
+package_barrier-headless-git() {
+ pkgdesc="Open-source KVM software based on Synergy (client and server CLI binaries)"
+
+ # Install all the files:
+ _package_common
+
+ # Now go and delete the GUI-related files:
+ for file in \
+ /usr/bin/barrier \
+ /usr/share/applications \
+ /usr/share/icons \
+ ;do
+ rm -rf "${pkgdir:?}/${file:?}"
+ done
+}
+