]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
matchbox-terminal: add x-terminal-emulator RPROVIDES and alternative
authorRoss Burton <ross.burton@arm.com>
Wed, 13 Nov 2024 15:55:06 +0000 (15:55 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 14 Nov 2024 11:56:44 +0000 (11:56 +0000)
Add a RPROVIDES for virtual-x-terminal-emulator, so that:
- Packages can RDEPEND on virtual-x-terminal-emulator and know that they
  have installed a terminal
- The x-terminal-emulator binary will (via alternatives) run a terminal

We don't bother with PROVIDES because nobody needs to DEPEND on a terminal,
the entire point of this is that the actual binary is interchangable.

Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-sato/matchbox-terminal/matchbox-terminal_0.2.bb

index f91c593f784b10363f2ab57c44634b8ba8ab14e2..c9b01b3cfd90f3d66b11b7aa13410f2e92d972a5 100644 (file)
@@ -16,6 +16,11 @@ PV = "0.2+git"
 
 S = "${WORKDIR}/git"
 
-inherit autotools pkgconfig features_check
+inherit autotools pkgconfig features_check update-alternatives
 
 ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
+
+RPROVIDES:${PN} = "virtual-x-terminal-emulator"
+ALTERNATIVE:${PN} = "x-terminal-emulator"
+ALTERNATIVE_TARGET[x-terminal-emulator] = "${bindir}/matchbox-terminal"
+ALTERNATIVE_PRIORITY[x-terminal-emulator] = "20"