From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wei Liu Subject: Re: [PATCH] tools/libxc: Fix use of zlib-options when building the domain builder Date: Mon, 15 Feb 2016 11:57:41 +0000 Message-ID: <20160215115741.GH8818@citrix.com> References: <1455304891-31068-1-git-send-email-andrew.cooper3@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <1455304891-31068-1-git-send-email-andrew.cooper3@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Andrew Cooper Cc: Wei Liu , Roger Pau Monne , Ian Jackson , Ian Campbell , Xen-devel List-Id: xen-devel@lists.xenproject.org On Fri, Feb 12, 2016 at 07:21:31PM +0000, Andrew Cooper wrote: > c/s de0f8c7c changed the use of zlib-options, and moved it from being locally > generated to coming from ./configure. > Wow, this is ancient commit. > 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 > --- > 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) > > -- > 2.1.4 >