From patchwork Fri Feb 12 19:21:31 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Andrew Cooper X-Patchwork-Id: 8296511 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id AF1AA9F6E4 for ; Fri, 12 Feb 2016 19:24:50 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DE40420452 for ; Fri, 12 Feb 2016 19:24:49 +0000 (UTC) Received: from lists.xen.org (lists.xenproject.org [50.57.142.19]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id EE49C20456 for ; Fri, 12 Feb 2016 19:24:48 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1aUJI0-000871-HI; Fri, 12 Feb 2016 19:22:00 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1aUJHy-00086w-Lk for xen-devel@lists.xen.org; Fri, 12 Feb 2016 19:21:58 +0000 Received: from [85.158.139.211] by server-7.bemta-5.messagelabs.com id E0/82-29293-5D03EB65; Fri, 12 Feb 2016 19:21:57 +0000 X-Env-Sender: prvs=843bae1bd=Andrew.Cooper3@citrix.com X-Msg-Ref: server-2.tower-206.messagelabs.com!1455304915!22071664!1 X-Originating-IP: [66.165.176.89] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni44OSA9PiAyMDMwMDc=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 7.35.1; banners=-,-,- X-VirusChecked: Checked Received: (qmail 17723 invoked from network); 12 Feb 2016 19:21:57 -0000 Received: from smtp.citrix.com (HELO SMTP.CITRIX.COM) (66.165.176.89) by server-2.tower-206.messagelabs.com with RC4-SHA encrypted SMTP; 12 Feb 2016 19:21:57 -0000 X-IronPort-AV: E=Sophos;i="5.22,437,1449532800"; d="scan'208";a="331428790" From: Andrew Cooper To: Xen-devel Date: Fri, 12 Feb 2016 19:21:31 +0000 Message-ID: <1455304891-31068-1-git-send-email-andrew.cooper3@citrix.com> X-Mailer: git-send-email 2.1.4 MIME-Version: 1.0 X-DLP: MIA1 Cc: Andrew Cooper , Wei Liu , Ian Jackson , Ian Campbell , Roger Pau Monne Subject: [Xen-devel] [PATCH] tools/libxc: Fix use of zlib-options when building the domain builder X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP c/s de0f8c7c changed the use of zlib-options, and moved it from being locally generated to coming from ./configure. However, it neglected to modify the users of zlib-options. The curious use of $(call ...) was to select either the -D or -l options as appropriate, but c/s de0f8c7c broke this by loosing the `grep`. Instead, use $(filter ...) to pick out either the -D or -l options. This fixes the build with Clang, which complains at passing '-llzma' when trying to compile xc_dom_bzimageloader.c to xc_dom_bzimageloader.o. Signed-off-by: Andrew Cooper Acked-by: Wei Liu Acked-by: Roger Pau Monné --- CC: Roger Pau Monne CC: Ian Campbell CC: Ian Jackson CC: Wei Liu --- tools/libxc/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/libxc/Makefile b/tools/libxc/Makefile index 0a8614c..608404f 100644 --- a/tools/libxc/Makefile +++ b/tools/libxc/Makefile @@ -226,10 +226,10 @@ else zlib-options = $(ZLIB) endif -xc_dom_bzimageloader.o: CFLAGS += $(call zlib-options,D) -xc_dom_bzimageloader.opic: CFLAGS += $(call zlib-options,D) +xc_dom_bzimageloader.o: CFLAGS += $(filter -D%,$(zlib-options)) +xc_dom_bzimageloader.opic: CFLAGS += $(filter -D%,$(zlib-options)) -libxenguest.so.$(MAJOR).$(MINOR): COMPRESSION_LIBS = $(call zlib-options,l) +libxenguest.so.$(MAJOR).$(MINOR): COMPRESSION_LIBS = $(filter -l%,$(zlib-options)) libxenguest.so.$(MAJOR).$(MINOR): $(GUEST_PIC_OBJS) libxenctrl.so $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenguest.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $(GUEST_PIC_OBJS) $(COMPRESSION_LIBS) -lz $(LDLIBS_libxenevtchn) $(LDLIBS_libxenctrl) $(PTHREAD_LIBS) $(APPEND_LDFLAGS)