Files
termux-packages/packages/vtm/0002-no-libinput.patch
2025-07-18 04:48:15 +00:00

70 lines
2.5 KiB
Diff

--- a/src/netxs/desktopio/system.hpp
+++ b/src/netxs/desktopio/system.hpp
@@ -59,7 +59,9 @@
#include <sys/kd.h> // ::console_ioctl()
#endif
#include <linux/keyboard.h> // ::keyb_ioctl()
+ #if !defined(__ANDROID__)
#include <linux/input.h> // mouse button codes: BTN_LEFT ...
+ #endif
#endif
#if defined(__APPLE__)
@@ -4699,7 +4701,7 @@
}
});
}
- #if defined(__linux__)
+ #if defined(__linux__) && !defined(__ANDROID__)
}
}
#include "lixx.hpp" // libinput++
@@ -5188,7 +5190,7 @@
#endif
return state;
};
- #if defined(__linux__)
+ #if defined(__linux__) && !defined(__ANDROID__)
if (dtvt::vtmode & ui::console::mouse) // Trying to get direct mouse access.
{
if (auto li = lixx::initialize())
@@ -5760,7 +5762,7 @@
timecod = time{},
dev_map = std::unordered_map<arch, si32>{}]() mutable
{
- #if defined(__linux__)
+ #if defined(__linux__) && !defined(__ANDROID__)
using namespace netxs::lixx;
while (true)
{
@@ -5911,7 +5913,7 @@
micefd, m_proc,
alarm, f_proc);
}
- #if defined(__linux__)
+ #if defined(__linux__) && !defined(__ANDROID__)
lixx::uninitialize();
#endif
--- a/src/vtm.cpp
+++ b/src/vtm.cpp
@@ -125,7 +125,7 @@
break;
}
}
- #if defined(__linux__)
+ #if defined(__linux__) && !defined(__ANDROID__)
else if (getopt.match("-a", "--mouse"))
{
auto enabled = xml::take_or(getopt.next(), true);
@@ -174,7 +174,7 @@
#if defined(WIN32)
"\n -0, --session0 Use Session 0 to run Desktop Server in background."
#endif
- #if defined(__linux__)
+ #if defined(__linux__) && !defined(__ANDROID__)
"\n -a, --mouse [mode] Set/reset persistent access to mouse devices for all users."
"\n Run 'sudo vtm --mouse 0' to reset access."
#endif