diff options
author | Riku Voipio <riku.voipio@linaro.org> | 2014-08-12 15:58:57 +0300 |
---|---|---|
committer | Riku Voipio <riku.voipio@linaro.org> | 2014-08-22 15:06:34 +0300 |
commit | 9af5c906d189d8f4aae902d75567639d2a8f4e22 (patch) | |
tree | 46ddbea715bab06eba0eb1063f8565284f8420ef /configure | |
parent | ab31cda3270994ab7a59a3ed8d44029a52af95a3 (diff) | |
download | hqemu-9af5c906d189d8f4aae902d75567639d2a8f4e22.zip hqemu-9af5c906d189d8f4aae902d75567639d2a8f4e22.tar.gz |
linux-user: add setns and unshare
Add support for the setns and unshare syscalls, trivially passed through to
the host. Based on patches by Paul Burton, added configure check.
Signed-off-by: Paul Burton <paul@archlinuxmips.org>
Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 20 |
1 files changed, 20 insertions, 0 deletions
@@ -3470,6 +3470,23 @@ if compile_prog "" "" ; then timerfd=yes fi +# check for setns and unshare support +setns=no +cat > $TMPC << EOF +#include <sched.h> + +int main(void) +{ + int ret; + ret = setns(0, 0); + ret = unshare(0); + return ret; +} +EOF +if compile_prog "" "" ; then + setns=yes +fi + # Check if tools are available to build documentation. if test "$docs" != "no" ; then if has makeinfo && has pod2man; then @@ -4541,6 +4558,9 @@ fi if test "$timerfd" = "yes" ; then echo "CONFIG_TIMERFD=y" >> $config_host_mak fi +if test "$setns" = "yes" ; then + echo "CONFIG_SETNS=y" >> $config_host_mak +fi if test "$inotify" = "yes" ; then echo "CONFIG_INOTIFY=y" >> $config_host_mak fi |