This patch adds a new -F/--desktop-file command line option to
invoker which takes a desktop file name as argument. Using it will
notify lipstick that the app which goes with that desktop file is
being started.
As a GNU extension, passing '+' to getopt_long can be used as an
alternative to the POSIXLY_CORRECT environment variable to get the
argument behavior that invoker relies on. Variables set in the invoker
environment will pass onto child processes, and adding this to the
environment would break some applications.
In case where the binary to be invoked is either not a shared library
object (e.g. it's a shell script) or when main() cannot be resolved
as shared library (because it hasn't been exported as such), instead
of abort()ing due to an uncaught exception, handle the exception and
print the error message in the log + on the console, and then fail.
We don't have a "boosted" group anymore, so the call fails.
Remove all code related to the failing call.
The re-classification for policy does not seem to be needed anymore?
And if it is indeed still needed, it probably doesn't work atm.
The old name was vague and didn't indicate the change in behavior at
all. Its documentation also described the behavior incorrectly. If the
-o or --keep-oom-score parameter is passed, the OOM score of the boosted
process will be unchanged. Normally, it will be reset to 0 on launch.
The --daemon-mode parameter is kept as an alias for compatibility.
This allows the application to look up its installation prefix (e.g.
/usr) by just looking at argv[0] and calculating relative paths from
there (previously one would need to pass the full path to invoker).
Previously, the user ID and group ID of the process was always set
to that of the application, if it differed from that of the invoker.
This commit adds simple privileges checking for the application
to determine whether or not it is allowed to access privileged
system information, before deciding to drop user ID or group ID.
This feature only encourages poor application interactivity: anything which is
sufficiently slow to require a splash screen should be made faster instead.
In addition to that, the feature is poorly implemented (X11-specific), and thus
useless. Rip it out, and remove the last dependency on X11 from applauncherd.
The tests in here have been in a completely non-working state for a very long
time, and it's now getting to a point where it hurts, rather than hinders
development. Nuke them from the tree.
In the future, the useful parts can be brought back easily from history.