Browse Source

Merge branch 'opencl_dynlink' into bfgminer

Luke Dashjr 13 years ago
parent
commit
ba9aa3d4da
1 changed files with 7 additions and 0 deletions
  1. 7 0
      driver-opencl.c

+ 7 - 0
driver-opencl.c

@@ -1435,6 +1435,13 @@ struct device_api opencl_api;
 
 static void opencl_detect()
 {
+#ifndef WIN32
+	if (!getenv("DISPLAY")) {
+		applog(LOG_DEBUG, "DISPLAY not set, setting :0 just in case");
+		setenv("DISPLAY", ":0", 1);
+	}
+#endif
+
 	if (!load_opencl_symbols()) {
 		nDevs = 0;
 		return;