summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorCornholio2016-03-11 22:15:42 -0500
committerCornholio2016-03-11 22:15:42 -0500
commitcedd899dbba8e2133a2fbc2fb4ec74f0a14fdd7b (patch)
tree4c07952b901f25c5700212008e64a71195b264f7
downloadaur-cedd899dbba8e2133a2fbc2fb4ec74f0a14fdd7b.tar.gz
Initial commit
-rw-r--r--.SRCINFO20
-rw-r--r--PKGBUILD47
-rw-r--r--fix-build.patch9
-rw-r--r--use-bumblebee.patch21
4 files changed, 97 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..92dbd39598a
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,20 @@
+pkgbase = nvdock-bumblebee
+ pkgdesc = A tray icon for easy launching of the NVIDIA control panel
+ pkgver = 1.02
+ pkgrel = 1
+ url = http://www.opsat.net/user/bob/projects/nvdock
+ arch = i686
+ arch = x86_64
+ license = BSD
+ depends = gtk2
+ provides = nvdock
+ conflicts = nvdock
+ source = http://bobmajdakjr.googlecode.com/files/nvdock-1.02.tar.bz2
+ source = fix-build.patch
+ source = use-bumblebee.patch
+ md5sums = e18c4eeff936dc3b671fd8b5a9bb5145
+ md5sums = e16d729d78e761e1015bd3b06876cb2f
+ md5sums = 3b58520b41ba471c71a029491f26a5e5
+
+pkgname = nvdock-bumblebee
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..2ec958786dd
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,47 @@
+# Maintainer: cornholio <vigo.the.unholy.carpathian@gmail.com>
+# Upstream Maintainer: Giovanni Scafora <giovanni@archlinux.org>
+# Contributor: Matthew Sharpe <matt.sharpe@gmail.com>
+
+pkgname=nvdock-bumblebee
+pkgver=1.02
+pkgrel=1
+pkgdesc="A tray icon for easy launching of the NVIDIA control panel"
+arch=('i686' 'x86_64')
+url="http://www.opsat.net/user/bob/projects/nvdock"
+license=('BSD')
+provides=('nvdock')
+conflicts=('nvdock')
+depends=('gtk2')
+source=("http://bobmajdakjr.googlecode.com/files/nvdock-${pkgver}.tar.bz2"
+ "fix-build.patch"
+ "use-bumblebee.patch")
+md5sums=('e18c4eeff936dc3b671fd8b5a9bb5145'
+ 'e16d729d78e761e1015bd3b06876cb2f'
+ '3b58520b41ba471c71a029491f26a5e5')
+
+prepare() {
+ cd "${srcdir}/nvdock-${pkgver}"
+
+ # Remove unneeded glib build dependency (FS#40523)
+ patch -Np1 -i ../fix-build.patch
+
+ # Use bumblebee
+ patch -Np1 -i ../use-bumblebee.patch
+}
+
+build() {
+ cd "${srcdir}/nvdock-${pkgver}"
+
+ make
+}
+
+package() {
+ cd "${srcdir}/nvdock-${pkgver}"
+
+ install -D -m755 build/nvdock "${pkgdir}/usr/bin/nvdock"
+ install -D -m644 data/nvdock.png "${pkgdir}/usr/share/pixmaps/nvdock.png"
+ install -D -m644 data/nvdock.desktop "${pkgdir}/usr/share/applications/nvdock.desktop"
+
+ # Install license
+ install -D COPYING "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}
diff --git a/fix-build.patch b/fix-build.patch
new file mode 100644
index 00000000000..0b85ab13383
--- /dev/null
+++ b/fix-build.patch
@@ -0,0 +1,9 @@
+diff -Naur nvdock-1.02.orig/Makefile nvdock-1.02/Makefile
+--- nvdock-1.02.orig/Makefile 2007-10-17 17:29:44.000000000 +0200
++++ nvdock-1.02/Makefile 2014-05-26 12:48:13.582975614 +0200
+@@ -1,4 +1,4 @@
+-CFLAGS=$(shell pkg-config --cflags gtk+-2.0 glib) $(shell pkg-config --cflags glib-2.0)
++CFLAGS=$(shell pkg-config --cflags gtk+-2.0) $(shell pkg-config --cflags glib-2.0)
+ LDFLAGS=$(shell pkg-config --libs gtk+-2.0) $(shell pkg-config --libs glib-2.0)
+
+ all:
diff --git a/use-bumblebee.patch b/use-bumblebee.patch
new file mode 100644
index 00000000000..9466d51909b
--- /dev/null
+++ b/use-bumblebee.patch
@@ -0,0 +1,21 @@
+diff -Naur nvdock-1.02/src/nvdock.h nvdock-1.02-patched/src/nvdock.h
+--- nvdock-1.02/src/nvdock.h 2007-10-19 06:07:19.000000000 -0400
++++ nvdock-1.02-patched/src/nvdock.h 2016-03-11 20:58:50.447203815 -0500
+@@ -43,11 +43,11 @@
+
+ #define CMD_SUFFIX " &> /dev/null &"
+ #define CMD_NVCLOCK_GTK "nvclock_gtk"
+-#define CMD_NVIDIA_RELOAD "nvidia-settings -load-config-only"
+-#define CMD_NVIDIA_SETTINGS "nvidia-settings"
+-#define CMD_NVIDIA_TEMP "nvidia-settings -q GPUCoreTemp | grep Attribute | cut -d ' ' -f 6 | cut -d '.' -f 1"
+-#define CMD_NVIDIA_LOAD "nvidia-settings -load-config-only"
+-#define CMD_NVIDIA_VERSION "nvidia-settings -q NvidiaDriverVersion | grep Attribute | cut -d : -f 3 | cut -d ' ' -f 2"
++#define CMD_NVIDIA_RELOAD "optirun -b none nvidia-settings -c :8 -load-config-only"
++#define CMD_NVIDIA_SETTINGS "optirun -b none nvidia-settings -c :8"
++#define CMD_NVIDIA_TEMP "optirun -b none nvidia-settings -c :8 -q GPUCoreTemp | grep Attribute | cut -d ' ' -f 6 | cut -d '.' -f 1"
++#define CMD_NVIDIA_LOAD "optirun -b none nvidia-settings -c :8 -load-config-only"
++#define CMD_NVIDIA_VERSION "optirun -b none nvidia-settings -c :8 -q NvidiaDriverVersion | grep Attribute | cut -d : -f 3 | cut -d ' ' -f 2"
+ #define CMD_WHICH_QUERY "which %s 2> /dev/null"
+
+ #define ICON "/usr/share/pixmaps/nvdock.png"
+