From 76e8ab47c936674b8bb9bf1c48de53b30f5bf74a Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Wed, 6 Jul 2016 17:08:57 +0100 Subject: terminal: Fix gnome-terminal to work with recent versions Currently gnome-terminal just returns straight away, opening a terminal in a new separate process we have no insight into. For patch resolution, this leads to spawning many different terminal windows, for pydevshell, it just flashes a window up and then closes. We need to block until the command completes but gnome-terminal gives us no way to do this. We therefore write the pid to a file using a "phonehome" wrapper script, then monitor the pid until it exits. [YOCTO #7254] (also fixing do_devpyshell) Signed-off-by: Richard Purdie --- scripts/oe-gnome-terminal-phonehome | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100755 scripts/oe-gnome-terminal-phonehome (limited to 'scripts/oe-gnome-terminal-phonehome') diff --git a/scripts/oe-gnome-terminal-phonehome b/scripts/oe-gnome-terminal-phonehome new file mode 100755 index 0000000000..e02354883a --- /dev/null +++ b/scripts/oe-gnome-terminal-phonehome @@ -0,0 +1,10 @@ +#!/bin/sh +# +# Gnome terminal won't tell us which PID a given command is run as +# or allow a single instance so we can't tell when it completes. +# This allows us to figure out the PID of the target so we can tell +# when its done. +# +echo $$ > $1 +shift +exec $@ -- cgit v1.2.3