From nobody Mon Feb 9 16:02:56 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=reject dis=none) header.from=citrix.com ARC-Seal: i=1; a=rsa-sha256; t=1624386120; cv=none; d=zohomail.com; s=zohoarc; b=L5VoGDI2mMY7yqpT+Ub1Ja3kMxJvLyw9gHBW7GqguYXM9AjCrWIYZwtygWV7XvAAs7UiFYy2rJ8m/ftnfpZ6MSjhsLVegxffUa4i6C0ZJWbG8jAL9SL/KLYiOwNVyFa89g2lDAAtc/zYt3GJRamVeJkWziIGE9iFZjD87Q8ANvw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1624386120; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=7BzVDSz04PDtzhuEU6F9oIFvO3mMwYgELDLI/Ud0yds=; b=XxAPTfM2fozj+rKQqeHILuxhi3Uk7ZEqJCNekp+UQ3kdrga0et2MhM2xVdnisvzSajaKjql47xkQ62TTCuZRD+OcWSNwM8iHNe4bwYhu7VGUlo7rLPg8hTn+LMgM+oWR1FU1Utst7OvWdI5lUU1+YItDSXse2l0pjJKYQspnB64= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1624386120709221.70840612236043; Tue, 22 Jun 2021 11:22:00 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.146026.268637 (Exim 4.92) (envelope-from ) id 1lvl1v-0003xK-EN; Tue, 22 Jun 2021 18:21:47 +0000 Received: by outflank-mailman (output) from mailman id 146026.268637; Tue, 22 Jun 2021 18:21:47 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1lvl1v-0003x5-AI; Tue, 22 Jun 2021 18:21:47 +0000 Received: by outflank-mailman (input) for mailman id 146026; Tue, 22 Jun 2021 18:21:46 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1lvl1u-0002zl-2D for xen-devel@lists.xenproject.org; Tue, 22 Jun 2021 18:21:46 +0000 Received: from esa2.hc3370-68.iphmx.com (unknown [216.71.145.153]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 502f1c37-ee41-478d-a30e-b37fa28ee278; Tue, 22 Jun 2021 18:21:36 +0000 (UTC) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 502f1c37-ee41-478d-a30e-b37fa28ee278 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1624386096; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=FuX/gdX/Z8iVIv8CdPdcrz1kl6FHA1swtRRbhrQEv1c=; b=U9B1y1p3TLadBIoPobG7VilBm0p3/YOsX0pDheUtntruFNOKuQKBoh4M AtYkdII3XozdQmiLzIf6AxTIOcHnt84wZZe4UKpTcOCtB3EfOH9/+jCtU o/7Jhzkahs00b6rirOJVIaBj+5R2pM3VydH8fuphTH3AdMX+WYIyi+Mnn w=; Authentication-Results: esa2.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none IronPort-SDR: OGBFqrArpyeROX0zZptHVTRLumLtvycqbI69jAu+cwGqyeLCt4BxrCiuEv1N4fOU7FfvNMSkSW uHj3JGzH4+A+cfXakgdxfYjuFLrMKtI3svo6IopvkNnskwqK6wE2VyNrO4qlRoDY6f3gg5un1c BIwknrx/utyqJ12m6EKPWSfu+EI7SNu5EzOEtLe03rzMyellzY3TGc/dbducKIPWMZFiWEYyla EQak3yGLq3vFabJFNka7EV1SS9RKcnzTlqZoNlegZj5gvKaFgT1XE8QjbkfS819QFHd0b06P3P 6Tg= X-SBRS: 5.1 X-MesageID: 46703313 X-Ironport-Server: esa2.hc3370-68.iphmx.com X-Remote-IP: 162.221.158.21 X-Policy: $RELAYED IronPort-HdrOrdr: A9a23:3mOxfK4tkSdTt2hrAAPXwXWBI+orL9Y04lQ7vn2ZFiYlF/Bwxv re/sjziyWE6wr5AEtQ6uxpOMG7MAjhHO1OkPss1NaZLU3bUQ6TRvAH0WKM+UyeJ8STzJ8l6U 4kSdkPNDSSNyk8sS+Z2njHLz9I+rDum83F6om+rwYLPGdXguNbnnZE422gYzdLrXx9dOYE/e 2nl7d6TlSbCAwqR/X+IkNAc/nIptXNmp6jSwUBHQQb5A6Hii7twKLmEjCDty1uFQ9n8PMHyy zoggb57qKsv7WQ0RnHzVLe6JxQhZ/I1sZDPsqRkcIYQw+c0zpAJb4RA4FqjgpF+t1H22xaze UkZC1QY/ib3kmhJV1dZyGdhDUIngxetUMKgmXo9EcL6faJMA7STfAx1L6xpSGpu3bI9esMpp 6i0w+ixu1qJAKFkyLn69fSURZ20kKyvHo5iOYWy2dSSI0EddZq3M8iFW5uYdY99RjBmcAa+S hVfY3hzecTdUnfY2HSv2FpztDpVnMvHg2eSkxHvsCOyTBZkH1w0kNdnaUk7zI93YN4T4MB6/ XPM6xumr0LRsgKbbhlDONERcesEGTCTR/FLWrXK1X6E6MMPW7LtvfMkfcIDSGRCdI1Jb4J6d n8uX9jxCUPknPVeIKzNcdwg1jwqU2GLH7QI+9lltFEhoE= X-IronPort-AV: E=Sophos;i="5.83,292,1616472000"; d="scan'208";a="46703313" From: Andrew Cooper To: Xen-devel CC: Andrew Cooper , Ian Jackson , Wei Liu , Jan Beulich , =?UTF-8?q?Roger=20Pau=20Monn=C3=A9?= , Juergen Gross Subject: [PATCH 3/4] tests/cpu-policy: Rework Makefile Date: Tue, 22 Jun 2021 19:21:23 +0100 Message-ID: <20210622182124.11571-4-andrew.cooper3@citrix.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20210622182124.11571-1-andrew.cooper3@citrix.com> References: <20210622182124.11571-1-andrew.cooper3@citrix.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @citrix.com) In particular, fill in the install/uninstall rules so this test can be packaged to be automated sensibly. Rework TARGET-y to be TARGETS, drop redundant -f's for $(RM), drop the unconditional -O3 and use the default instead, and drop CFLAGS from the link line but honour APPEND_LDFLAGS. Signed-off-by: Andrew Cooper Reviewed-by: Jan Beulich --- CC: Ian Jackson CC: Wei Liu CC: Jan Beulich CC: Roger Pau Monn=C3=A9 CC: Juergen Gross v2: * Drop -f's * Use %.o rather than *.o for Make level wildcards --- tools/tests/cpu-policy/Makefile | 31 +++++++++++++++++++------------ 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/tools/tests/cpu-policy/Makefile b/tools/tests/cpu-policy/Makef= ile index 70ff154da6..161732ad16 100644 --- a/tools/tests/cpu-policy/Makefile +++ b/tools/tests/cpu-policy/Makefile @@ -1,21 +1,19 @@ XEN_ROOT =3D $(CURDIR)/../../.. include $(XEN_ROOT)/tools/Rules.mk =20 -TARGET-y :=3D test-cpu-policy +TARGETS :=3D =20 # For brevity, these tests make extensive use of designated initialisers in # anonymous unions, but GCCs older than 4.6 can't cope. Ignore the test in # this case. -ifneq ($(clang),y) -TARGET-$(call cc-ver,$(CC),lt,0x040600) :=3D -endif - -ifeq ($(TARGET-y),) +ifneq ($(gcc)$(call cc-ver,$(CC),lt,0x040600),yy) +TARGETS +=3D test-cpu-policy +else $(warning Test harness not built, use newer compiler than "$(CC)" (version= $(shell $(CC) -dumpversion))) endif =20 .PHONY: all -all: $(TARGET-y) +all: $(TARGETS) =20 .PHONY: run run: $(TARGET-y) @@ -23,23 +21,32 @@ run: $(TARGET-y) =20 .PHONY: clean clean: - $(RM) -f -- *.o .*.d .*.d2 test-cpu-policy + $(RM) -- *.o $(TARGETS) $(DEPS_RM) =20 .PHONY: distclean distclean: clean - $(RM) -f -- *~ + $(RM) -- *~ =20 .PHONY: install install: all + $(INSTALL_DIR) $(DESTDIR)$(LIBEXEC_BIN) + $(if $(TARGETS),$(INSTALL_PROG) $(TARGETS) $(DESTDIR)$(LIBEXEC_BIN)) =20 .PHONY: uninstall +uninstall: + $(RM) -- $(addprefix $(DESTDIR)$(LIBEXEC_BIN)/,$(TARGETS)) =20 -CFLAGS +=3D -Werror $(CFLAGS_xeninclude) -D__XEN_TOOLS__ -O3 +CFLAGS +=3D -Werror -D__XEN_TOOLS__ +CFLAGS +=3D $(CFLAGS_xeninclude) CFLAGS +=3D $(APPEND_CFLAGS) =20 -vpath %.c ../../../xen/lib/x86 +LDFLAGS +=3D $(APPEND_LDFLAGS) + +vpath %.c $(XEN_ROOT)/xen/lib/x86 + +%.o: Makefile =20 test-cpu-policy: test-cpu-policy.o msr.o cpuid.o policy.o - $(CC) $(CFLAGS) $^ -o $@ + $(CC) $^ -o $@ $(LDFLAGS) =20 -include $(DEPS_INCLUDE) --=20 2.11.0