summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO23
-rw-r--r--PKGBUILD67
-rw-r--r--floating_wm_workaround.patch14
3 files changed, 56 insertions, 48 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 121b1f9d1716..ea3061a4b90e 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,19 +1,26 @@
pkgbase = glslviewer-git
- pkgdesc = Live GLSL coding render for MacOS and Linux
- pkgver = r551.4858c45
+ pkgdesc = Console-based GLSL Sandbox for 2D/3D shaders
+ pkgver = 3.2.4.r4.gdb3def8
pkgrel = 1
url = https://github.com/patriciogonzalezvivo/glslViewer
arch = i686
arch = x86_64
license = BSD-3-Clause
+ makedepends = cmake
makedepends = git
- depends = glfw
- provides = glslviewer-git
- conflicts = glslviewer-git
- source = glslviewer-git::git+https://github.com/patriciogonzalezvivo/glslViewer
- source = floating_wm_workaround.patch
+ depends = glu
+ depends = glfw-x11
+ depends = ncurses
+ depends = ffmpeg
+ provides = glslviewer
+ conflicts = glslviewer
+ source = glslviewer::git+https://github.com/patriciogonzalezvivo/glslViewer
md5sums = SKIP
- md5sums = dd0001eb24fdf2cd1f49e83b25ba2fd7
pkgname = glslviewer-git
+pkgname = glslviewer-examples-git
+ pkgdesc = Console-based GLSL Sandbox for 2D/3D shaders (shader examples)
+ depends =
+ provides = glslviewer-examples
+ conflicts = glslviewer-examples
diff --git a/PKGBUILD b/PKGBUILD
index 5552097b28ca..85797d3c9f64 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,41 +1,56 @@
-# Maintainer: Agorgianitis Loukas <agorglouk@gmail.com>
-pkgname=glslviewer-git
-pkgver=r551.4858c45
+# Maintainer: Joonas Henriksson <joonas.henriksson at gmail com>
+# Contributor: Agorgianitis Loukas <agorglouk@gmail.com>
+
+pkgbase=glslviewer-git
+pkgname=('glslviewer-git' 'glslviewer-examples-git')
+pkgver=3.2.4.r4.gdb3def8
pkgrel=1
-pkgdesc="Live GLSL coding render for MacOS and Linux"
+pkgdesc="Console-based GLSL Sandbox for 2D/3D shaders"
arch=('i686' 'x86_64')
url="https://github.com/patriciogonzalezvivo/glslViewer"
license=('BSD-3-Clause')
-depends=('glfw')
-makedepends=('git')
-provides=("${pkgname%-VCS}")
-conflicts=("${pkgname%-VCS}")
-source=("$pkgname::git+https://github.com/patriciogonzalezvivo/glslViewer"
- 'floating_wm_workaround.patch')
-md5sums=('SKIP'
- 'dd0001eb24fdf2cd1f49e83b25ba2fd7')
+depends=('glu' 'glfw-x11' 'ncurses' 'ffmpeg')
+makedepends=('cmake' 'git')
+provides=("${pkgbase%-git}")
+conflicts=("${pkgbase%-git}")
+source=("${pkgbase%-git}::git+https://github.com/patriciogonzalezvivo/glslViewer")
+md5sums=('SKIP')
pkgver() {
- cd "$srcdir/${pkgname%-VCS}"
- printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+ cd "$srcdir/${pkgbase%-git}"
+ git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}
prepare() {
- cd "$srcdir/${pkgname%-VCS}"
- patch -p1 -i "$srcdir/floating_wm_workaround.patch"
+ cd "$srcdir/${pkgbase%-git}"
+ git submodule init
+ git submodule update
}
build() {
- cd "$srcdir/${pkgname%-VCS}"
- make
+ cmake \
+ -S "${pkgbase%-git}" \
+ -B build \
+ -DCMAKE_INSTALL_PREFIX=/usr
+
+ make -C build
+}
+
+package_glslviewer-git() {
+ make install -C build DESTDIR="$pkgdir"
+
+ install -D -m644 "${pkgbase%-git}/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}
-package() {
- cd "$srcdir/${pkgname%-VCS}"
- install -D -m644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
- install -D -m755 bin/glslViewer "$pkgdir/usr/bin/glslviewer"
- install -D -m755 bin/glslLoader "$pkgdir/usr/bin/glslloader"
- mkdir -p "$pkgdir/usr/share/$pkgname/examples/"
- cp -R examples/* "$pkgdir/usr/share/$pkgname/examples/"
- chmod -R 755 "$pkgdir/usr/share/$pkgname/examples/"
+package_glslviewer-examples-git() {
+ pkgdesc+=" (shader examples)"
+ depends=()
+ provides=("${pkgname%-git}")
+ conflicts=("${pkgname%-git}")
+
+ install -d -m755 "$pkgdir/usr/share/$pkgname/"
+ cp -r "${pkgbase%-git}"/examples/* "$pkgdir/usr/share/$pkgname/"
+
+ install -D -m644 "${pkgbase%-git}/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}
+
diff --git a/floating_wm_workaround.patch b/floating_wm_workaround.patch
deleted file mode 100644
index d0cdc2005ab5..000000000000
--- a/floating_wm_workaround.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-diff --git a/src/window.cpp b/src/window.cpp
-index 66cf765..fc8f44c 100644
---- a/src/window.cpp
-+++ b/src/window.cpp
-@@ -204,6 +204,9 @@ void initGL (glm::ivec4 &_viewport, bool _headless, bool _alwaysOnTop) {
- glfwWindowHint(GLFW_FLOATING, GL_TRUE);
- }
-
-+ // Make it float
-+ glfwWindowHint(GLFW_RESIZABLE, GLFW_FALSE);
-+
- window = glfwCreateWindow(_viewport.z, _viewport.w, appTitle.c_str(), NULL, NULL);
-
- if(!window) {