summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2020-11-06 15:01:13 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2020-11-06 15:20:34 +0100
commitceedbf8185fc7593366679f02d31da63af8c4bd1 (patch)
treec4bdddf2fa357c70bea717eb4f41b5a48bf7a6ed /meson.build
parent3f51bbff559428e4c32640c0c1b7b8516dc16acb (diff)
downloadsystemd-ceedbf8185fc7593366679f02d31da63af8c4bd1.tar.gz
meson: add option for fexecve use
There are downsides to using fexecve: when fexecve is used (for normal executables), /proc/pid/status shows Name: 3, which means that ps -C foobar doesn't work. pidof works, because it checks /proc/self/cmdline. /proc/self/exe also shows the correct link, but requires privileges to read. /proc/self/comm also shows "3". I think this can be considered a kernel deficiency: when O_CLOEXEC is used, this "3" is completely meaningless. It could be any number. The kernel should use argv[0] instead, which at least has *some* meaning. I think the approach with fexecve/execveat is instersting, so let's provide it as opt-in.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build2
1 files changed, 2 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 68ead1f849..a800959ba9 100644
--- a/meson.build
+++ b/meson.build
@@ -215,6 +215,7 @@ conf.set_quoted('SYSTEM_SYSVRCND_PATH', sysvrcnd_path)
conf.set_quoted('RC_LOCAL_PATH', get_option('rc-local'))
conf.set('ANSI_OK_COLOR', 'ANSI_' + get_option('ok-color').underscorify().to_upper())
+conf.set10('ENABLE_FEXECVE', get_option('fexecve'))
conf.set_quoted('USER_CONFIG_UNIT_DIR', join_paths(pkgsysconfdir, 'user'))
conf.set_quoted('USER_DATA_UNIT_DIR', userunitdir)
@@ -3787,6 +3788,7 @@ foreach tuple : [
['link-timesyncd-shared', get_option('link-timesyncd-shared')],
['kernel-install', get_option('kernel-install')],
['systemd-analyze', conf.get('ENABLE_ANALYZE') == 1],
+ ['fexecve'],
]
if tuple.length() >= 2