]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
meson: tools: build virt-login-shell binary
authorPavel Hrdina <phrdina@redhat.com>
Wed, 20 May 2020 14:28:46 +0000 (16:28 +0200)
committerPavel Hrdina <phrdina@redhat.com>
Mon, 3 Aug 2020 07:27:05 +0000 (09:27 +0200)
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
tools/Makefile.am
tools/meson.build

index 40e73d1b83d8c3c7ab3c8497bd841420eebcf4fb..51507ba1e379227c77b0d50e8d6911dc910af6aa 100644 (file)
@@ -41,7 +41,6 @@ endif WITH_SANLOCK
 
 if WITH_LOGIN_SHELL
 conf_DATA += virt-login-shell.conf
-bin_PROGRAMS += virt-login-shell
 libexec_PROGRAMS = virt-login-shell-helper
 endif WITH_LOGIN_SHELL
 
@@ -62,14 +61,6 @@ virt-sanlock-cleanup: virt-sanlock-cleanup.in Makefile
 
 noinst_LTLIBRARIES =
 
-# virt-login-shell will be setuid, and must not link to anything
-# except glibc. It wil scrub the environment and then invoke the
-# real virt-login-shell-helper binary.
-virt_login_shell_SOURCES = \
-               virt-login-shell.c
-
-virt_login_shell_CPPFLAGS = $(STANDALONE_CPPFLAGS)
-
 virt_login_shell_helper_SOURCES = \
                virt-login-shell-helper.c
 
index 4229119d5e154fe09684393612da419713a09e0e..183620e33a9d759f240bab997e8e2283291391f8 100644 (file)
@@ -78,3 +78,20 @@ if conf.has('WITH_HOST_VALIDATE')
     install_rpath: libdir,
   )
 endif
+
+if conf.has('WITH_LOGIN_SHELL')
+  # virt-login-shell will be setuid, and must not link to anything
+  # except glibc. It wil scrub the environment and then invoke the
+  # real virt-login-shell-helper binary.
+  executable(
+    'virt-login-shell',
+    [
+      'virt-login-shell.c',
+    ],
+    include_directories: [
+      top_inc_dir,
+    ],
+    install: true,
+    install_dir: bindir,
+  )
+endif