From patchwork Fri Feb 8 22:47:11 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cole Robinson X-Patchwork-Id: 157895 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp28021jaa; Fri, 8 Feb 2019 14:47:53 -0800 (PST) X-Google-Smtp-Source: AHgI3IZ9xR80wMI3X5wrXxxyuWK7rhUEaL8XX1ph71RofQNjPHPnWyzeng1I2/6GhT65m6xGWXH2 X-Received: by 2002:a37:b8c1:: with SMTP id i184mr16778835qkf.51.1549666073232; Fri, 08 Feb 2019 14:47:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549666073; cv=none; d=google.com; s=arc-20160816; b=cnnIAr2ZfLeyRE8h+rzyDi73bPmrqoC9A15Xr4I4Fb0s6YEeNGNRkbaT10OLM1ZmMs 8u91aJV9khgkB1R1h2qjHFOSoP3aGXe5OJfCa0IvRYaItudMwj8NRt5snrhhdoZeYMPE f0TfAD6k8OJ1BFz6veQrw3Hyhc/FgoKtRHU40E4LJmSaWv/l6KcSznojT6iUK1s56/aP UCOeUuXrrhReoMqREQw1YLfVJsfHAbx9nwtNllrtRke0ScyVcZ0G4+hSJVfJt2ulbRyE YahDFjOHf/TtcskW5wAhm/YhPSd6GwBwe9Yq0y7oKg3C8CNnJc+glQnNvwNQQp8lliQx tdpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:references:in-reply-to:message-id:date:to:from :delivered-to; bh=NAsBBqtf/p98qDzTCVU2HkJGozUpqeNO/eUDXodHSHc=; b=RYJZGjsqNPKCoDTo6NWAVJmU4O1oWcF3Bmn6XmzzAK678T/dJ2G7nFGm2tZEKL8y6X QGyXa9TrDzjD0ZCm9elyMECFvMJQxoMiMRxj+i35Jw2PO+unQP2TzhBqrpYVvifWHBUa PjxVu1oAE234iB3qj60nTff3BLCtSeOobIxAg+JEOUQXF4ckKVhu12BqG6oLe086swVw pDEv5qLKkREmDuWyyDXiIz1+/obqOn7mdvdCS2TcgdgWo0VwuB92mSAjDHTn/ktkMv6N 1mIxGvBGgLnIsLg26Ze6NppNs10xfhCaMnea2muigSyqhrGwoDReOxH+r7iPeGnq+ADr miqg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com. [209.132.183.28]) by mx.google.com with ESMTPS id f15si2289793qth.61.2019.02.08.14.47.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 08 Feb 2019 14:47:53 -0800 (PST) Received-SPF: pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; Authentication-Results: mx.google.com; spf=pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D4E3E59478; Fri, 8 Feb 2019 22:47:51 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A04361EC; Fri, 8 Feb 2019 22:47:51 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 575DF18033A6; Fri, 8 Feb 2019 22:47:51 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id x18MlLuS014267 for ; Fri, 8 Feb 2019 17:47:21 -0500 Received: by smtp.corp.redhat.com (Postfix) id 5929454505; Fri, 8 Feb 2019 22:47:21 +0000 (UTC) Delivered-To: libvirt-list@redhat.com Received: from worklaptop.redhat.com (ovpn-123-115.rdu2.redhat.com [10.10.123.115]) by smtp.corp.redhat.com (Postfix) with ESMTP id E77645B682; Fri, 8 Feb 2019 22:47:20 +0000 (UTC) From: Cole Robinson To: libvirt-list@redhat.com Date: Fri, 8 Feb 2019 17:47:11 -0500 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 2/4] tests: Create a shared library with libxl driver X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Fri, 08 Feb 2019 22:47:52 +0000 (UTC) This allows us to mock functions in the libxl driver, like is already possible for the qemu driver Signed-off-by: Cole Robinson --- tests/Makefile.am | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) -- 2.20.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list diff --git a/tests/Makefile.am b/tests/Makefile.am index c9f79a4e7d..c3f633cee0 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -58,7 +58,7 @@ MOCKLIBS_LDFLAGS = -module -avoid-version \ -rpath /evil/libtool/hack/to/force/shared/lib/creation \ $(MINGW_EXTRA_LDFLAGS) -QEMULIB_LDFLAGS = \ +DRIVERLIB_LDFLAGS = \ -avoid-version \ -rpath /evil/libtool/hack/to/force/shared/lib/creation \ $(MINGW_EXTRA_LDFLAGS) @@ -278,7 +278,7 @@ ssh_LDADD = $(COVERAGE_LDFLAGS) if WITH_LIBXL test_programs += xlconfigtest xml2sexprtest sexpr2xmltest \ xmconfigtest libxlxml2domconfigtest -test_libraries += libxlmock.la +test_libraries += libxltestdriver.la libxlmock.la endif WITH_LIBXL if WITH_QEMU @@ -509,6 +509,10 @@ libxl_LDADDS += ../src/libvirt_driver_network_impl.la endif WITH_NETWORK libxl_LDADDS += $(LDADDS) +libxltestdriver_la_SOURCES = +libxltestdriver_la_LDFLAGS = $(DRIVERLIB_LDFLAGS) +libxltestdriver_la_LIBADD = $(libxl_LDADDS) + xlconfigtest_SOURCES = \ xlconfigtest.c testutilsxen.c testutilsxen.h \ testutils.c testutils.h @@ -567,7 +571,7 @@ qemu_LDADDS += ../src/libvirt_qemu_probes.lo endif WITH_DTRACE_PROBES libqemutestdriver_la_SOURCES = -libqemutestdriver_la_LDFLAGS = $(QEMULIB_LDFLAGS) +libqemutestdriver_la_LDFLAGS = $(DRIVERLIB_LDFLAGS) libqemutestdriver_la_LIBADD = $(qemu_LDADDS) qemucpumock_la_SOURCES = \ @@ -1038,7 +1042,7 @@ endif WITH_QEMU if WITH_LIBXL domaincapstest_SOURCES += testutilsxen.c testutilsxen.h -domaincapstest_LDADD += ../src/libvirt_driver_libxl_impl.la $(GNULIB_LIBS) +domaincapstest_LDADD += libxltestdriver.la $(GNULIB_LIBS) endif WITH_LIBXL if WITH_BHYVE