summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlastair Poole <netstar@gmail.com>2021-04-12 12:47:27 +0100
committerAlastair Poole <netstar@gmail.com>2021-04-12 12:47:27 +0100
commite1eed5190b6285941df69959e479e4273438d3e2 (patch)
treeeaa76a2efb81894388e7aaf2c701e1a6ef41a705
parent56d2cdc294b6554e1153d408e618c8a8694be393 (diff)
downloadenlightenment-e1eed5190b6285941df69959e479e4273438d3e2.tar.gz
freebsd: make elput optional.
-rwxr-xr-xconfs/freebsd.sh2
-rw-r--r--meson.build6
-rw-r--r--meson_options.txt5
-rw-r--r--src/bin/e_gesture.c4
-rw-r--r--src/bin/e_gesture.h4
-rw-r--r--src/bin/e_main.c3
-rw-r--r--src/modules/conf_bindings/e_mod_main.c2
-rw-r--r--src/modules/conf_bindings/meson.build5
8 files changed, 26 insertions, 5 deletions
diff --git a/confs/freebsd.sh b/confs/freebsd.sh
index 6d108a51f2..32d73f18b3 100755
--- a/confs/freebsd.sh
+++ b/confs/freebsd.sh
@@ -1,3 +1,3 @@
#!/bin/sh -e
-meson -Dsystemd=false -Ddevice-udev=false -Dgesture-recognition=false \
+meson -Dsystemd=false -Delput=false -Ddevice-udev=false -Dgesture-recognition=false \
$@ . build
diff --git a/meson.build b/meson.build
index fb3749bb3b..c82233b1ac 100644
--- a/meson.build
+++ b/meson.build
@@ -309,7 +309,7 @@ dep_eo = dependency('eo' , required: true)
dep_eldbus = dependency('eldbus' , required: true)
dep_emotion = dependency('emotion' , required: true)
dep_elementary = dependency('elementary' , required: true)
-dep_elput = dependency('elput' , required: true)
+dep_elput = dependency('elput' , required: false)
dep_wayland = []
if get_option('wl') == true
@@ -361,6 +361,10 @@ else
dep_ecore_x = dependency('ecore-x')
endif
+if get_option('elput') == true
+ config_h.set('HAVE_ELPUT', '1')
+endif
+
dep_xkeyboard_config = dependency('xkeyboard-config', required: false)
if dep_xkeyboard_config.found() == true
config_h.set_quoted('XKB_BASE', dep_xkeyboard_config.get_pkgconfig_variable('xkb_base'))
diff --git a/meson_options.txt b/meson_options.txt
index b214df80fa..ce0f88d694 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -40,6 +40,11 @@ option('libexif',
value: true,
description: 'enable EXIF support: (default=true)')
+option('elput',
+ type: 'boolean',
+ value: true,
+ description: 'enable elput support: (default=true)')
+
option('device-udev',
type: 'boolean',
value: true,
diff --git a/src/bin/e_gesture.c b/src/bin/e_gesture.c
index 94622836db..35eb9744c1 100644
--- a/src/bin/e_gesture.c
+++ b/src/bin/e_gesture.c
@@ -1,3 +1,5 @@
+#ifdef HAVE_ELPUT
+
#include <e.h>
#include <Eina.h>
#include <grp.h>
@@ -247,3 +249,5 @@ e_bindings_gesture_capable_devices_get(void)
{
return gesture_capable_devices;
}
+
+#endif
diff --git a/src/bin/e_gesture.h b/src/bin/e_gesture.h
index 0593ec4726..56d37c4a62 100644
--- a/src/bin/e_gesture.h
+++ b/src/bin/e_gesture.h
@@ -1,3 +1,5 @@
+#ifdef HAVE_ELPUT
+
#ifdef E_TYPEDEFS
typedef void (*E_Bindings_Swipe_Live_Update)(void *data, Eina_Bool end, double direction, double length, double error, unsigned int fingers);
@@ -11,3 +13,5 @@ E_API void e_bindings_swipe_live_update_hook_set(E_Bindings_Swipe_Live_Update up
E_API int e_bindings_gesture_capable_devices_get(void);
#endif
#endif
+
+#endif
diff --git a/src/bin/e_main.c b/src/bin/e_main.c
index 2fdaeee172..ec30762809 100644
--- a/src/bin/e_main.c
+++ b/src/bin/e_main.c
@@ -1053,11 +1053,12 @@ main(int argc, char **argv)
TS("E_Comp_Canvas Keys Grab");
e_comp_canvas_keys_grab();
TS("E_Comp_Canvas Keys Grab Done");
-
+#ifdef HAVE_ELPUT
TS("E_Gesture Init");
e_gesture_init();
TS("E_Gesture Init Done");
_e_main_shutdown_push(e_gesture_shutdown);
+#endif
TS("Run Startup Apps");
if (!nostartup)
diff --git a/src/modules/conf_bindings/e_mod_main.c b/src/modules/conf_bindings/e_mod_main.c
index 8800faed8a..41de4d67b3 100644
--- a/src/modules/conf_bindings/e_mod_main.c
+++ b/src/modules/conf_bindings/e_mod_main.c
@@ -33,10 +33,12 @@ e_modapi_init(E_Module *m)
_("Edge Bindings"), NULL,
"preferences-desktop-edge-bindings",
e_int_config_edgebindings);
+#ifdef HAVE_ELPUT
e_configure_registry_item_add("keyboard_and_mouse/swipe_bindings", 10,
_("Swipe Bindings"), NULL,
"preferences-desktop-swipe-bindings",
e_int_config_swipebindings);
+#endif
e_configure_registry_category_add("advanced", 80, _("Advanced"), NULL, "preferences-advanced");
e_configure_registry_item_add("advanced/signal_bindings", 10,
diff --git a/src/modules/conf_bindings/meson.build b/src/modules/conf_bindings/meson.build
index ee1adad559..9a2b9ca2ac 100644
--- a/src/modules/conf_bindings/meson.build
+++ b/src/modules/conf_bindings/meson.build
@@ -5,8 +5,9 @@ src = files(
'e_int_config_keybindings.c',
'e_int_config_mousebindings.c',
'e_int_config_signalbindings.c',
- 'e_int_config_swipebindings.c',
'e_mod_main.h'
)
-
+if get_option('gesture-recognition') == true
+ src += files('e_int_config_swipebindings.c')
+endif
desktop_only = true