mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 04:25:18 +00:00
Don't always skip virportallocatortest
Include dlfcn.h before checking if RTLD_NEXT is defined
This commit is contained in:
parent
29151830e4
commit
d7e0f1133e
@ -23,8 +23,11 @@
|
|||||||
#include "virfile.h"
|
#include "virfile.h"
|
||||||
#include "testutils.h"
|
#include "testutils.h"
|
||||||
|
|
||||||
#if HAVE_DLFCN_H && defined(RTLD_NEXT)
|
#if HAVE_DLFCN_H
|
||||||
|
# include <dlfcn.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(RTLD_NEXT)
|
||||||
# ifdef MOCK_HELPER
|
# ifdef MOCK_HELPER
|
||||||
# include "internal.h"
|
# include "internal.h"
|
||||||
# include <sys/socket.h>
|
# include <sys/socket.h>
|
||||||
@ -32,7 +35,6 @@
|
|||||||
# include <arpa/inet.h>
|
# include <arpa/inet.h>
|
||||||
# include <netinet/in.h>
|
# include <netinet/in.h>
|
||||||
# include <stdio.h>
|
# include <stdio.h>
|
||||||
# include <dlfcn.h>
|
|
||||||
|
|
||||||
static bool host_has_ipv6 = false;
|
static bool host_has_ipv6 = false;
|
||||||
static int (*realsocket)(int domain, int type, int protocol);
|
static int (*realsocket)(int domain, int type, int protocol);
|
||||||
@ -265,7 +267,7 @@ mymain(void)
|
|||||||
VIRT_TEST_MAIN_PRELOAD(mymain, abs_builddir "/.libs/libvirportallocatormock.so")
|
VIRT_TEST_MAIN_PRELOAD(mymain, abs_builddir "/.libs/libvirportallocatormock.so")
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
#else /* ! HAVE_DLFCN_H */
|
#else /* ! defined(RTLD_NEXT) */
|
||||||
int
|
int
|
||||||
main(void)
|
main(void)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user