From: Lennart Poettering Date: Mon, 25 Dec 2017 11:07:40 +0000 (+0100) Subject: meson: when pivot_root() is added one day, look for it in X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=0f7010b10c20a84c90222925d39e222dc5d998a1;p=elogind.git meson: when pivot_root() is added one day, look for it in We of course don't know in which header glibc will export pivot_root() and if it ever will. But there's a good chance they'll place it where chroot() is located, given the similarity in the operations, hence let's try our luck and look for it at the same place. If we are lucky this means we don't have to patch our code if glibc decides to expose the call one day. --- diff --git a/meson.build b/meson.build index aea61990c..ac61dbc93 100644 --- a/meson.build +++ b/meson.build @@ -520,7 +520,8 @@ endforeach foreach ident : [ ['memfd_create', '''#include '''], ['gettid', '''#include '''], - ['pivot_root', '''#include '''], # no known header declares pivot_root + ['pivot_root', '''#include +// #include '''], # no known header declares pivot_root ['name_to_handle_at', '''#include #include #include '''],