Disable GPU blacklist via command line options.
authorJoe Wreschnig <joe.wreschnig@gmail.com>
Wed, 10 Sep 2014 15:40:35 +0000 (17:40 +0200)
committerJoe Wreschnig <joe.wreschnig@gmail.com>
Wed, 10 Sep 2014 15:40:35 +0000 (17:40 +0200)
tools/generate-nw
tools/nw-linux-wrapper

index 61959f2705ad1e51416deeaffa423c70195b3cda..a249232477fa14016dd86fcaab7a5f163e087c02 100755 (executable)
@@ -37,6 +37,7 @@ def main(appdir, version=None):
         "main": indexes[0],
         "name": name,
         "version": version or "0.0.0",
+        "chromium-args": "--enable-webgl --ignore-gpu-blacklist",
         "window": {
             "show": False,
             "toolbar": False,
index d13e39fbe5928dfd5447541e54d1a372bff1ae00..e195611135973bb3897fd1b21d494c533efa99e9 100755 (executable)
@@ -10,6 +10,7 @@
 SELF=$(readlink -f "$0")
 NWDIR=$(dirname "$SELF")/nw
 NWBIN=$(command -v "$NWDIR/nw" nw | head -n 1)
+NWFLAGS="--enable-webgl --ignore-gpu-blacklist"
 PACKAGE="$NWDIR/package.nw"
 
 if [ ! -x "$NWBIN" ]; then
@@ -17,9 +18,9 @@ if [ ! -x "$NWBIN" ]; then
     exit 127
 fi
 
-"$NWBIN" "$@" "$PACKAGE"
+"$NWBIN" $NWFLAGS "$@" "$PACKAGE"
 if [ "$?" = "127" -a -w "$NWBIN" ]; then
     echo "Applying libudev.so.1 hack." >&2
     sed -i 's/udev\.so\.0/udev.so.1/g' "$NWBIN"
-    "$NWBIN" "$@" "$PACKAGE"
+    "$NWBIN" $NWFLAGS "$@" "$PACKAGE"
 fi