build: drop libvirt setuid library build

The virt-login-shell setuid program is now a tiny piece of code
that only uses standard libc functions, and santizes the execution
environment before invoking the real virt-login-shell-helper.
The latter is thus able to use the normal libvirt.so build,
allowing us to delete the special cut down setuid library build.

Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
This commit is contained in:
Daniel P. Berrangé
2019-07-30 13:44:37 +01:00
parent 4feeb2d986
commit ac0d21c762
5 changed files with 19 additions and 153 deletions

View File

@@ -280,43 +280,37 @@ virGlobalInit(void)
goto error;
#endif /* HAVE_LIBINTL_H */
/*
* Note we must avoid everything except 'remote' driver
* for virt-login-shell usage
*/
#ifndef LIBVIRT_SETUID_RPC_CLIENT
/*
* Note that the order is important: the first ones have a higher
* priority when calling virConnectOpen.
*/
# ifdef WITH_TEST
#ifdef WITH_TEST
if (testRegister() == -1)
goto error;
# endif
# ifdef WITH_OPENVZ
#endif
#ifdef WITH_OPENVZ
if (openvzRegister() == -1)
goto error;
# endif
# ifdef WITH_VMWARE
#endif
#ifdef WITH_VMWARE
if (vmwareRegister() == -1)
goto error;
# endif
# ifdef WITH_PHYP
#endif
#ifdef WITH_PHYP
if (phypRegister() == -1)
goto error;
# endif
# ifdef WITH_ESX
#endif
#ifdef WITH_ESX
if (esxRegister() == -1)
goto error;
# endif
# ifdef WITH_HYPERV
#endif
#ifdef WITH_HYPERV
if (hypervRegister() == -1)
goto error;
# endif
# ifdef WITH_XENAPI
#endif
#ifdef WITH_XENAPI
if (xenapiRegister() == -1)
goto error;
# endif
#endif
#ifdef WITH_REMOTE
if (remoteRegister() == -1)