uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
|
|
@ -0,0 +1,38 @@
|
|||
diff --git a/build.sh b/build.sh
|
||||
index 05603db..8c38b31 100755
|
||||
--- a/build.sh
|
||||
+++ b/build.sh
|
||||
@@ -2,5 +2,5 @@
|
||||
|
||||
dependencies="gtk+-3.0 x11 xrandr libpulse"
|
||||
includes="$(pkg-config --cflags $dependencies)"
|
||||
-libs="$(pkg-config --libs $dependencies)"
|
||||
+libs="$(pkg-config --libs $dependencies) -ldl"
|
||||
g++ -o gpu-screen-recorder-gtk -O2 src/main.cpp -s $includes $libs
|
||||
diff --git a/src/main.cpp b/src/main.cpp
|
||||
index ae2078f..9dcdce1 100644
|
||||
--- a/src/main.cpp
|
||||
+++ b/src/main.cpp
|
||||
@@ -15,6 +15,7 @@
|
||||
#include <pwd.h>
|
||||
#include <libgen.h>
|
||||
#include <functional>
|
||||
+#include <dlfcn.h>
|
||||
|
||||
typedef struct {
|
||||
Display *display;
|
||||
@@ -830,7 +831,13 @@ static void audio_input_change_callback(GtkComboBox *widget, gpointer userdata)
|
||||
}
|
||||
|
||||
static bool is_nv_fbc_installed() {
|
||||
- return access("/usr/lib/libnvidia-fbc.so.1", F_OK) == 0 || access("/usr/local/lib/libnvidia-fbc.so.1", F_OK) == 0;
|
||||
+ auto handle = dlopen("libnvidia-fbc.so.1", RTLD_LAZY);
|
||||
+ if (handle) {
|
||||
+ dlclose(handle);
|
||||
+ return true;
|
||||
+ } else {
|
||||
+ return false;
|
||||
+ }
|
||||
}
|
||||
|
||||
static GtkWidget* create_common_settings_page(GtkStack *stack, GtkApplication *app) {
|
||||
Loading…
Add table
Add a link
Reference in a new issue