diff options
3 files changed, 88 insertions, 0 deletions
diff --git a/meta-oe/recipes-support/touchpademulator/touchpademulator/0001-makefile-Use-CC-instead-of-hardcoding-gcc-calls.patch b/meta-oe/recipes-support/touchpademulator/touchpademulator/0001-makefile-Use-CC-instead-of-hardcoding-gcc-calls.patch new file mode 100644 index 0000000000..062adc9665 --- /dev/null +++ b/meta-oe/recipes-support/touchpademulator/touchpademulator/0001-makefile-Use-CC-instead-of-hardcoding-gcc-calls.patch | |||
| @@ -0,0 +1,29 @@ | |||
| 1 | From 37284f7208e43da34cac64b419219c5d4e20b36e Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Khem Raj <raj.khem@gmail.com> | ||
| 3 | Date: Thu, 2 Oct 2025 15:25:50 -0700 | ||
| 4 | Subject: [PATCH] makefile: Use CC instead of hardcoding gcc calls | ||
| 5 | |||
| 6 | This helps to cross-compile it using infrastructure like yocto | ||
| 7 | |||
| 8 | Upstream-Status: Submitted [https://gitlab.com/CalcProgrammer1/TouchpadEmulator/-/merge_requests/4] | ||
| 9 | |||
| 10 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
| 11 | --- | ||
| 12 | Makefile | 4 +++- | ||
| 13 | 1 file changed, 3 insertions(+), 1 deletion(-) | ||
| 14 | |||
| 15 | diff --git a/Makefile b/Makefile | ||
| 16 | index adf39a6..4cebaa6 100644 | ||
| 17 | --- a/Makefile | ||
| 18 | +++ b/Makefile | ||
| 19 | @@ -1,7 +1,9 @@ | ||
| 20 | +CC ?= gcc | ||
| 21 | + | ||
| 22 | default: TouchpadEmulator | ||
| 23 | |||
| 24 | TouchpadEmulator: TouchpadEmulator.c | ||
| 25 | - gcc -Wall $(shell pkg-config --cflags dbus-1 dbus-glib-1) TouchpadEmulator.c -ldbus-1 -ldbus-glib-1 -lpthread -o TouchpadEmulator | ||
| 26 | + $(CC) -Wall $(shell pkg-config --cflags dbus-1 dbus-glib-1) TouchpadEmulator.c -ldbus-1 -ldbus-glib-1 -lpthread -o TouchpadEmulator | ||
| 27 | |||
| 28 | clean: | ||
| 29 | git clean -dfx | ||
diff --git a/meta-oe/recipes-support/touchpademulator/touchpademulator/0002-LaunchTouchpadEmulator.sh-Demand-sh-instead-of-bash.patch b/meta-oe/recipes-support/touchpademulator/touchpademulator/0002-LaunchTouchpadEmulator.sh-Demand-sh-instead-of-bash.patch new file mode 100644 index 0000000000..999c557d54 --- /dev/null +++ b/meta-oe/recipes-support/touchpademulator/touchpademulator/0002-LaunchTouchpadEmulator.sh-Demand-sh-instead-of-bash.patch | |||
| @@ -0,0 +1,25 @@ | |||
| 1 | From 5b715a6741a7a2fcd0dc04e31c682a0183a49fa6 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Khem Raj <raj.khem@gmail.com> | ||
| 3 | Date: Thu, 2 Oct 2025 15:27:09 -0700 | ||
| 4 | Subject: [PATCH] LaunchTouchpadEmulator.sh: Demand sh instead of bash | ||
| 5 | |||
| 6 | This script does not really use any bash specific extentions | ||
| 7 | so asking for simple /bin/sh should be good and makes it more | ||
| 8 | portable | ||
| 9 | |||
| 10 | Upstream-Status: Submitted [https://gitlab.com/CalcProgrammer1/TouchpadEmulator/-/merge_requests/4] | ||
| 11 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
| 12 | --- | ||
| 13 | LaunchTouchpadEmulator.sh | 2 +- | ||
| 14 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
| 15 | |||
| 16 | diff --git a/LaunchTouchpadEmulator.sh b/LaunchTouchpadEmulator.sh | ||
| 17 | index d12fc27..63134cd 100755 | ||
| 18 | --- a/LaunchTouchpadEmulator.sh | ||
| 19 | +++ b/LaunchTouchpadEmulator.sh | ||
| 20 | @@ -1,4 +1,4 @@ | ||
| 21 | -#! /bin/bash | ||
| 22 | +#! /bin/sh | ||
| 23 | |||
| 24 | if [ "$1" = "--autostart" ] ; then | ||
| 25 | mkdir -p ~/.config/autostart | ||
diff --git a/meta-oe/recipes-support/touchpademulator/touchpademulator_git.bb b/meta-oe/recipes-support/touchpademulator/touchpademulator_git.bb new file mode 100644 index 0000000000..e7b0387f7e --- /dev/null +++ b/meta-oe/recipes-support/touchpademulator/touchpademulator_git.bb | |||
| @@ -0,0 +1,34 @@ | |||
| 1 | SUMMARY = "Emulate a touchpad mouse device using a touchscreen on Linux" | ||
| 2 | LICENSE = "GPL-2.0-or-later" | ||
| 3 | LIC_FILES_CHKSUM = "file://LICENSE;md5=f744a106227710d355bcc787e464ba2d \ | ||
| 4 | file://debian/copyright;md5=7bed05b78c0e4abec501cf82c4b85d9c" | ||
| 5 | |||
| 6 | SRC_URI = "git://gitlab.com/CalcProgrammer1/TouchpadEmulator;protocol=https;branch=master \ | ||
| 7 | file://0001-makefile-Use-CC-instead-of-hardcoding-gcc-calls.patch \ | ||
| 8 | file://0002-LaunchTouchpadEmulator.sh-Demand-sh-instead-of-bash.patch \ | ||
| 9 | " | ||
| 10 | |||
| 11 | PV = "0.3+git" | ||
| 12 | SRCREV = "7800f4c3af4defaf1be1083c93983ed4ff0e3b32" | ||
| 13 | |||
| 14 | inherit pkgconfig | ||
| 15 | |||
| 16 | DEPENDS += "dbus dbus-glib" | ||
| 17 | |||
| 18 | # Fixes: | ||
| 19 | # File /usr/bin/TouchpadEmulator in package touchpademulator doesn't have GNU_HASH (didn't pass LDFLAGS?) [ldflags] | ||
| 20 | TARGET_CC_ARCH += "${LDFLAGS}" | ||
| 21 | |||
| 22 | do_configure () { | ||
| 23 | : | ||
| 24 | } | ||
| 25 | |||
| 26 | do_compile () { | ||
| 27 | oe_runmake | ||
| 28 | } | ||
| 29 | |||
| 30 | do_install () { | ||
| 31 | oe_runmake install 'DESTDIR=${D}' | ||
| 32 | } | ||
| 33 | |||
| 34 | FILES:${PN} += "${datadir}/icons" | ||
