From patchwork Thu Aug 7 14:07:51 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefano Stabellini X-Patchwork-Id: 35048 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ob0-f198.google.com (mail-ob0-f198.google.com [209.85.214.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 239FB21137 for ; Thu, 7 Aug 2014 14:41:29 +0000 (UTC) Received: by mail-ob0-f198.google.com with SMTP id wp18sf16582012obc.1 for ; Thu, 07 Aug 2014 07:41:28 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:date:from:to:in-reply-to:message-id :references:user-agent:mime-version:cc:subject:precedence:list-id :list-unsubscribe:list-post:list-help:list-subscribe:sender :errors-to:x-original-sender:x-original-authentication-results :mailing-list:list-archive:content-type:content-transfer-encoding; bh=CH7MVmIG/PZDvcu4y04H8xEhIOmwyyd9C7jtAuCylPo=; b=VzWSkfn/11kmBh8CMEKypN+nPB7hN81ds8eemcLxvodii09/pi25Lshn3ffK6N4mBQ Q8EwjXtxxboCA8/eSZJruoxlts7RdO7dEA96RPOB7QdOENw5eWoibqjH6qj5rYBixl7A w76s4cQ8W/d2vw89wajazib4B5Wz6Bh9elgtrB5O5dczDGLnsfZPcBffbUt4RsU/pIu+ WcNdZ/gBtUty+Yu+/1OZaHh6MboNVS5Roj9o8s5YLYnkizSAPA6L8JIpPW/FP9AYEsTI aftw3nCQN0x9tYIT+MHtwB1/5gmyXG53qkf+mytcfovA1qW03ozinopD2E2zSG2jD+f6 Me8A== X-Gm-Message-State: ALoCoQnboGYHHOvUiMqyjOZ/90VDnJs9ge2qmsh4CcAc98PyymbrYBST9kOTY6DvQs6yTWRWLOwF X-Received: by 10.182.123.232 with SMTP id md8mr8867497obb.41.1407422488765; Thu, 07 Aug 2014 07:41:28 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.24.106 with SMTP id 97ls161887qgq.26.gmail; Thu, 07 Aug 2014 07:41:28 -0700 (PDT) X-Received: by 10.52.61.99 with SMTP id o3mr2370448vdr.46.1407422488675; Thu, 07 Aug 2014 07:41:28 -0700 (PDT) Received: from mail-vc0-f174.google.com (mail-vc0-f174.google.com [209.85.220.174]) by mx.google.com with ESMTPS id wc6si1842890vdb.42.2014.08.07.07.41.28 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 07 Aug 2014 07:41:28 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.174 as permitted sender) client-ip=209.85.220.174; Received: by mail-vc0-f174.google.com with SMTP id la4so6379264vcb.19 for ; Thu, 07 Aug 2014 07:41:28 -0700 (PDT) X-Received: by 10.52.83.227 with SMTP id t3mr2424478vdy.20.1407422488500; Thu, 07 Aug 2014 07:41:28 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp35730vcb; Thu, 7 Aug 2014 07:41:27 -0700 (PDT) X-Received: by 10.42.207.68 with SMTP id fx4mr4436431icb.67.1407422486687; Thu, 07 Aug 2014 07:41:26 -0700 (PDT) Received: from lists.xen.org (lists.xen.org. [50.57.142.19]) by mx.google.com with ESMTPS id h4si19212513igh.48.2014.08.07.07.41.26 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 07 Aug 2014 07:41:26 -0700 (PDT) Received-SPF: none (google.com: xen-devel-bounces@lists.xen.org does not designate permitted sender hosts) client-ip=50.57.142.19; Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XFONS-0002zY-KN; Thu, 07 Aug 2014 14:09:10 +0000 Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XFONR-0002zT-4E for xen-devel@lists.xensource.com; Thu, 07 Aug 2014 14:09:09 +0000 Received: from [85.158.137.68:60568] by server-12.bemta-3.messagelabs.com id 08/60-02460-48883E35; Thu, 07 Aug 2014 14:09:08 +0000 X-Env-Sender: Stefano.Stabellini@citrix.com X-Msg-Ref: server-5.tower-31.messagelabs.com!1407420545!12436814!1 X-Originating-IP: [66.165.176.63] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni42MyA9PiAzMDYwNDg=\n X-StarScan-Received: X-StarScan-Version: 6.11.3; banners=-,-,- X-VirusChecked: Checked Received: (qmail 18270 invoked from network); 7 Aug 2014 14:09:07 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-5.tower-31.messagelabs.com with RC4-SHA encrypted SMTP; 7 Aug 2014 14:09:07 -0000 X-IronPort-AV: E=Sophos;i="5.01,818,1400025600"; d="scan'208";a="160293451" Received: from ukmail1.uk.xensource.com (10.80.16.128) by smtprelay.citrix.com (10.13.107.80) with Microsoft SMTP Server id 14.3.181.6; Thu, 7 Aug 2014 10:09:04 -0400 Received: from kaball.uk.xensource.com ([10.80.2.59]) by ukmail1.uk.xensource.com with esmtp (Exim 4.69) (envelope-from ) id 1XFONM-0003pF-GA; Thu, 07 Aug 2014 15:09:04 +0100 Date: Thu, 7 Aug 2014 15:07:51 +0100 From: Stefano Stabellini X-X-Sender: sstabellini@kaball.uk.xensource.com To: Ian Jackson In-Reply-To: <21475.26389.402798.866488@mariner.uk.xensource.com> Message-ID: References: <1406907139-16800-1-git-send-email-stefano.stabellini@eu.citrix.com> <21474.16719.839599.709043@mariner.uk.xensource.com> <21475.26389.402798.866488@mariner.uk.xensource.com> User-Agent: Alpine 2.02 (DEB 1266 2009-07-14) MIME-Version: 1.0 X-DLP: MIA2 Cc: xen-devel@lists.xensource.com, Ian.Campbell@citrix.com, Stefano Stabellini Subject: Re: [Xen-devel] [PATCH v4 1/3] Move xenstore and libxc public headers to include subdir X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Post: , List-Help: , List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: stefano.stabellini@eu.citrix.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.174 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Archive: On Thu, 7 Aug 2014, Ian Jackson wrote: > Stefano Stabellini writes ("Re: [Xen-devel] [PATCH v4 1/3] Move xenstore and libxc public headers to include subdir"): > > git://xenbits.xen.org/people/sstabellini/xen-unstable.git public_headers_v4 > > sed 's/@VERSION@/4.1/g' < META.in >META.new && mv -f META.new META > mkdir -p /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1 > ocamlfind remove -destdir /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1 xenmmap > ocamlfind: [WARNING] No such directory: /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap > ocamlfind install -destdir /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1 -ldconf ignore xenmmap META xenmmap.cmi xenmmap.cma xenmmap.cmxa *.a *.so *.cmx > Installed /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap/xenmmap.cmx > Installed /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap/dllxenmmap_stubs.so > Installed /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap/xenmmap.a > Installed /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap/libxenmmap_stubs.a > Installed /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap/xenmmap.cmxa > Installed /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap/xenmmap.cma > Installed /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap/xenmmap.cmi > Installed /u/iwj/work/xen.git/dist/install/usr/local/lib/ocaml/3.12.1/xenmmap/META > make[7]: Leaving directory `/u/iwj/work/xen.git/tools/ocaml/libs/mmap' > make[6]: Leaving directory `/u/iwj/work/xen.git/tools/ocaml/libs' > make[6]: Entering directory `/u/iwj/work/xen.git/tools/ocaml/libs' > make -C xentoollog install > make[6]: *** [subdir-install-xentoollog] Error 2 > make[6]: Leaving directory `/u/iwj/work/xen.git/tools/ocaml/libs' > make[5]: *** [subdirs-install] Error 2 > make[5]: Leaving directory `/u/iwj/work/xen.git/tools/ocaml/libs' > make[4]: *** [subdir-install-libs] Error 2 > make[4]: Leaving directory `/u/iwj/work/xen.git/tools/ocaml' > make[3]: *** [subdirs-install] Error 2 > make[3]: Leaving directory `/u/iwj/work/xen.git/tools/ocaml' > make[2]: *** [subdir-install-ocaml] Error 2 > make[2]: Leaving directory `/u/iwj/work/xen.git/tools' > make[1]: *** [subdirs-install] Error 2 > make[1]: Leaving directory `/u/iwj/work/xen.git/tools' > make: *** [install-tools] Error 2 I needed to make a couple of more libxc to libxc/include substitutions under tools/ocaml. The appended patch should work. I have also pushed: git://xenbits.xen.org/people/sstabellini/xen-unstable.git public_headers_v5 --- >From 197699ff887967bf398b9b331c471eeebfa92d4c Mon Sep 17 00:00:00 2001 From: Stefano Stabellini Date: Thu, 10 Jul 2014 15:35:28 +0000 Subject: [PATCH v5] Move xenstore and libxc public headers to include subdir Also moves xc_dom.h to include as it is used often by other xen tools. Use the new include subdirectories to build Xen tools and qemu-xen. Add the old libxc include path to the programs that need it to build, on a case by case basis and commeting that they shouldn't require internal libxc headers to build. Signed-off-by: Stefano Stabellini --- Changes in v5: - fix ocaml build. --- tools/Makefile | 6 +++--- tools/Rules.mk | 6 +++--- tools/blktap2/drivers/Makefile | 2 ++ tools/libxc/Makefile | 6 +++--- tools/libxc/{ => include}/xc_dom.h | 0 tools/libxc/{ => include}/xenctrl.h | 0 tools/libxc/{ => include}/xenctrlosdep.h | 0 tools/libxc/{ => include}/xenguest.h | 0 tools/libxc/{ => include}/xentoollog.h | 0 tools/misc/Makefile | 2 ++ tools/ocaml/libs/eventchn/xeneventchn.mli | 2 +- tools/ocaml/libs/xentoollog/Makefile | 2 +- tools/ocaml/libs/xentoollog/genlevels.py | 2 +- tools/python/setup.py | 6 +++--- tools/xcutils/Makefile | 3 ++- tools/xenpaging/Makefile | 3 ++- tools/xenstore/Makefile | 9 +++++---- tools/xenstore/{ => include}/compat/xs.h | 0 tools/xenstore/{ => include}/compat/xs_lib.h | 0 tools/xenstore/{ => include}/xenstore.h | 0 tools/xenstore/{ => include}/xenstore_lib.h | 0 21 files changed, 28 insertions(+), 21 deletions(-) rename tools/libxc/{ => include}/xc_dom.h (100%) rename tools/libxc/{ => include}/xenctrl.h (100%) rename tools/libxc/{ => include}/xenctrlosdep.h (100%) rename tools/libxc/{ => include}/xenguest.h (100%) rename tools/libxc/{ => include}/xentoollog.h (100%) rename tools/xenstore/{ => include}/compat/xs.h (100%) rename tools/xenstore/{ => include}/compat/xs_lib.h (100%) rename tools/xenstore/{ => include}/xenstore.h (100%) rename tools/xenstore/{ => include}/xenstore_lib.h (100%) diff --git a/tools/xenstore/compat/xs.h b/tools/xenstore/include/compat/xs.h similarity index 100% rename from tools/xenstore/compat/xs.h rename to tools/xenstore/include/compat/xs.h diff --git a/tools/xenstore/compat/xs_lib.h b/tools/xenstore/include/compat/xs_lib.h similarity index 100% rename from tools/xenstore/compat/xs_lib.h rename to tools/xenstore/include/compat/xs_lib.h diff --git a/tools/xenstore/xenstore.h b/tools/xenstore/include/xenstore.h similarity index 100% rename from tools/xenstore/xenstore.h rename to tools/xenstore/include/xenstore.h diff --git a/tools/xenstore/xenstore_lib.h b/tools/xenstore/include/xenstore_lib.h similarity index 100% rename from tools/xenstore/xenstore_lib.h rename to tools/xenstore/include/xenstore_lib.h diff --git a/tools/Makefile b/tools/Makefile index b6476c9..1130369 100644 --- a/tools/Makefile +++ b/tools/Makefile @@ -192,9 +192,9 @@ subdir-all-qemu-xen-dir: qemu-xen-dir-find --includedir=$(PREFIX)/lib/xen/include \ --source-path=$$source \ --extra-cflags="-I$(XEN_ROOT)/tools/include \ - -I$(XEN_ROOT)/tools/libxc \ - -I$(XEN_ROOT)/tools/xenstore \ - -I$(XEN_ROOT)/tools/xenstore/compat \ + -I$(XEN_ROOT)/tools/libxc/include \ + -I$(XEN_ROOT)/tools/xenstore/include \ + -I$(XEN_ROOT)/tools/xenstore/compat/include \ $(EXTRA_CFLAGS_QEMU_XEN)" \ --extra-ldflags="-L$(XEN_ROOT)/tools/libxc \ -L$(XEN_ROOT)/tools/xenstore \ diff --git a/tools/Rules.mk b/tools/Rules.mk index 0aa1e6b..4e07e82 100644 --- a/tools/Rules.mk +++ b/tools/Rules.mk @@ -35,15 +35,15 @@ INSTALL_SHLIB = : install-shlib-unsupported-fail SYMLINK_SHLIB = : symlink-shlib-unsupported-fail endif -CFLAGS_libxenctrl = -I$(XEN_LIBXC) $(CFLAGS_xeninclude) +CFLAGS_libxenctrl = -I$(XEN_LIBXC)/include $(CFLAGS_xeninclude) LDLIBS_libxenctrl = $(XEN_LIBXC)/libxenctrl$(libextension) SHLIB_libxenctrl = -Wl,-rpath-link=$(XEN_LIBXC) -CFLAGS_libxenguest = -I$(XEN_LIBXC) $(CFLAGS_xeninclude) +CFLAGS_libxenguest = -I$(XEN_LIBXC)/include $(CFLAGS_xeninclude) LDLIBS_libxenguest = $(XEN_LIBXC)/libxenguest$(libextension) SHLIB_libxenguest = -Wl,-rpath-link=L$(XEN_LIBXC) -CFLAGS_libxenstore = -I$(XEN_XENSTORE) $(CFLAGS_xeninclude) +CFLAGS_libxenstore = -I$(XEN_XENSTORE)/include $(CFLAGS_xeninclude) LDLIBS_libxenstore = $(XEN_XENSTORE)/libxenstore$(libextension) SHLIB_libxenstore = -Wl,-rpath-link=$(XEN_XENSTORE) diff --git a/tools/blktap2/drivers/Makefile b/tools/blktap2/drivers/Makefile index 1129ca1..7df9bc4 100644 --- a/tools/blktap2/drivers/Makefile +++ b/tools/blktap2/drivers/Makefile @@ -16,6 +16,8 @@ CFLAGS += -I$(BLKTAP_ROOT)/include -I$(BLKTAP_ROOT)/drivers CFLAGS += $(CFLAGS_libxenctrl) CFLAGS += -D_GNU_SOURCE CFLAGS += -DUSE_NFS_LOCKS +# drivers/block-log.c incorrectly uses libxc internals +CFLAGS += -I$(XEN_ROOT)/tools/libxc ifeq ($(CONFIG_X86_64),y) CFLAGS += -fPIC diff --git a/tools/libxc/Makefile b/tools/libxc/Makefile index 22eef8e..83fcd3c 100644 --- a/tools/libxc/Makefile +++ b/tools/libxc/Makefile @@ -89,7 +89,7 @@ OSDEP_SRCS-y += xenctrl_osdep_ENOSYS.c -include $(XEN_TARGET_ARCH)/Makefile CFLAGS += -Werror -Wmissing-prototypes -CFLAGS += -I. $(CFLAGS_xeninclude) +CFLAGS += -I. -I./include $(CFLAGS_xeninclude) # Needed for posix_fadvise64() in xc_linux.c CFLAGS-$(CONFIG_Linux) += -D_GNU_SOURCE @@ -140,12 +140,12 @@ install: build $(INSTALL_DATA) libxenctrl.a $(DESTDIR)$(LIBDIR) $(SYMLINK_SHLIB) libxenctrl.so.$(MAJOR).$(MINOR) $(DESTDIR)$(LIBDIR)/libxenctrl.so.$(MAJOR) $(SYMLINK_SHLIB) libxenctrl.so.$(MAJOR) $(DESTDIR)$(LIBDIR)/libxenctrl.so - $(INSTALL_DATA) xenctrl.h xenctrlosdep.h xentoollog.h $(DESTDIR)$(INCLUDEDIR) + $(INSTALL_DATA) include/xenctrl.h include/xenctrlosdep.h include/xentoollog.h $(DESTDIR)$(INCLUDEDIR) $(INSTALL_SHLIB) libxenguest.so.$(MAJOR).$(MINOR) $(DESTDIR)$(LIBDIR) $(INSTALL_DATA) libxenguest.a $(DESTDIR)$(LIBDIR) $(SYMLINK_SHLIB) libxenguest.so.$(MAJOR).$(MINOR) $(DESTDIR)$(LIBDIR)/libxenguest.so.$(MAJOR) $(SYMLINK_SHLIB) libxenguest.so.$(MAJOR) $(DESTDIR)$(LIBDIR)/libxenguest.so - $(INSTALL_DATA) xenguest.h $(DESTDIR)$(INCLUDEDIR) + $(INSTALL_DATA) include/xenguest.h $(DESTDIR)$(INCLUDEDIR) .PHONY: TAGS TAGS: diff --git a/tools/libxc/xc_dom.h b/tools/libxc/include/xc_dom.h similarity index 100% rename from tools/libxc/xc_dom.h rename to tools/libxc/include/xc_dom.h diff --git a/tools/libxc/xenctrl.h b/tools/libxc/include/xenctrl.h similarity index 100% rename from tools/libxc/xenctrl.h rename to tools/libxc/include/xenctrl.h diff --git a/tools/libxc/xenctrlosdep.h b/tools/libxc/include/xenctrlosdep.h similarity index 100% rename from tools/libxc/xenctrlosdep.h rename to tools/libxc/include/xenctrlosdep.h diff --git a/tools/libxc/xenguest.h b/tools/libxc/include/xenguest.h similarity index 100% rename from tools/libxc/xenguest.h rename to tools/libxc/include/xenguest.h diff --git a/tools/libxc/xentoollog.h b/tools/libxc/include/xentoollog.h similarity index 100% rename from tools/libxc/xentoollog.h rename to tools/libxc/include/xentoollog.h diff --git a/tools/misc/Makefile b/tools/misc/Makefile index 69b1817..266fd16 100644 --- a/tools/misc/Makefile +++ b/tools/misc/Makefile @@ -6,6 +6,8 @@ CFLAGS += -Werror CFLAGS += $(CFLAGS_libxenctrl) CFLAGS += $(CFLAGS_xeninclude) CFLAGS += $(CFLAGS_libxenstore) +# xen-hptool.c and xen-mfndump.c incorrectly use libxc internals +CFLAGS += -I$(XEN_ROOT)/tools/libxc HDRS = $(wildcard *.h) diff --git a/tools/ocaml/libs/eventchn/xeneventchn.mli b/tools/ocaml/libs/eventchn/xeneventchn.mli index e4e02a4..e180145 100644 --- a/tools/ocaml/libs/eventchn/xeneventchn.mli +++ b/tools/ocaml/libs/eventchn/xeneventchn.mli @@ -14,7 +14,7 @@ * GNU Lesser General Public License for more details. *) -(** Event channel bindings: see tools/libxc/xenctrl.h *) +(** Event channel bindings: see tools/libxc/include/xenctrl.h *) type handle (** An initialised event channel interface. *) diff --git a/tools/ocaml/libs/xentoollog/Makefile b/tools/ocaml/libs/xentoollog/Makefile index 471b428..f2134b8 100644 --- a/tools/ocaml/libs/xentoollog/Makefile +++ b/tools/ocaml/libs/xentoollog/Makefile @@ -48,7 +48,7 @@ xentoollog.mli: xentoollog.mli.in _xtl_levels.mli.in libs: $(LIBS) -_xtl_levels.ml.in _xtl_levels.mli.in _xtl_levels.inc: genlevels.py $(XEN_ROOT)/tools/libxc/xentoollog.h +_xtl_levels.ml.in _xtl_levels.mli.in _xtl_levels.inc: genlevels.py $(XEN_ROOT)/tools/libxc/include/xentoollog.h $(PYTHON) genlevels.py _xtl_levels.mli.in _xtl_levels.ml.in _xtl_levels.inc .PHONY: install diff --git a/tools/ocaml/libs/xentoollog/genlevels.py b/tools/ocaml/libs/xentoollog/genlevels.py index 6b42f21..65d334f 100755 --- a/tools/ocaml/libs/xentoollog/genlevels.py +++ b/tools/ocaml/libs/xentoollog/genlevels.py @@ -3,7 +3,7 @@ import sys def read_levels(): - f = open('../../../libxc/xentoollog.h', 'r') + f = open('../../../libxc/include/xentoollog.h', 'r') levels = [] record = False diff --git a/tools/python/setup.py b/tools/python/setup.py index 17ebb4a..439c429 100644 --- a/tools/python/setup.py +++ b/tools/python/setup.py @@ -13,7 +13,7 @@ PATH_XENSTORE = XEN_ROOT + "/tools/xenstore" xc = Extension("xc", extra_compile_args = extra_compile_args, - include_dirs = [ PATH_XEN, PATH_LIBXC, "xen/lowlevel/xc" ], + include_dirs = [ PATH_XEN, PATH_LIBXC + "/include", "xen/lowlevel/xc" ], library_dirs = [ PATH_LIBXC ], libraries = [ "xenctrl", "xenguest" ], depends = [ PATH_LIBXC + "/libxenctrl.so", PATH_LIBXC + "/libxenguest.so" ], @@ -21,7 +21,7 @@ xc = Extension("xc", xs = Extension("xs", extra_compile_args = extra_compile_args, - include_dirs = [ PATH_XEN, PATH_XENSTORE, "xen/lowlevel/xs" ], + include_dirs = [ PATH_XEN, PATH_XENSTORE + "/include", "xen/lowlevel/xs" ], library_dirs = [ PATH_XENSTORE ], libraries = [ "xenstore" ], depends = [ PATH_XENSTORE + "/libxenstore.so" ], @@ -29,7 +29,7 @@ xs = Extension("xs", xl = Extension("xl", extra_compile_args = extra_compile_args, - include_dirs = [ PATH_XEN, PATH_LIBXL, PATH_LIBXC, "xen/lowlevel/xl" ], + include_dirs = [ PATH_XEN, PATH_LIBXL, PATH_LIBXC + "/include", "xen/lowlevel/xl" ], library_dirs = [ PATH_LIBXL ], libraries = [ "xenlight" ], depends = [ PATH_LIBXL + "/libxenlight.so" ], diff --git a/tools/xcutils/Makefile b/tools/xcutils/Makefile index 98706bf..f71703d 100644 --- a/tools/xcutils/Makefile +++ b/tools/xcutils/Makefile @@ -15,7 +15,8 @@ PROGRAMS = readnotes lsevtchn CFLAGS += -Werror -CFLAGS_readnotes.o := $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest) +# incorrectly uses libxc internals +CFLAGS_readnotes.o := $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest) -I$(XEN_ROOT)/tools/libxc CFLAGS_lsevtchn.o := $(CFLAGS_libxenctrl) .PHONY: all diff --git a/tools/xenpaging/Makefile b/tools/xenpaging/Makefile index 548d9dd..054562d 100644 --- a/tools/xenpaging/Makefile +++ b/tools/xenpaging/Makefile @@ -1,7 +1,8 @@ XEN_ROOT=$(CURDIR)/../.. include $(XEN_ROOT)/tools/Rules.mk -CFLAGS += $(CFLAGS_libxenctrl) $(CFLAGS_libxenstore) $(PTHREAD_CFLAGS) +# xenpaging.c and file_ops.c incorrectly use libxc internals +CFLAGS += $(CFLAGS_libxenctrl) $(CFLAGS_libxenstore) $(PTHREAD_CFLAGS) -I$(XEN_ROOT)/tools/libxc LDLIBS += $(LDLIBS_libxenctrl) $(LDLIBS_libxenstore) $(PTHREAD_LIBS) LDFLAGS += $(PTHREAD_LDFLAGS) diff --git a/tools/xenstore/Makefile b/tools/xenstore/Makefile index 08460c8..d0ac949 100644 --- a/tools/xenstore/Makefile +++ b/tools/xenstore/Makefile @@ -7,6 +7,7 @@ MINOR = 3 CFLAGS += -Werror CFLAGS += -I. CFLAGS += -I$(XEN_ROOT)/tools/ +CFLAGS += -I./include CFLAGS += $(CFLAGS_libxenctrl) CLIENTS := xenstore-exists xenstore-list xenstore-read xenstore-rm xenstore-chmod @@ -135,10 +136,10 @@ endif ln -sf libxenstore.so.$(MAJOR).$(MINOR) $(DESTDIR)$(LIBDIR)/libxenstore.so.$(MAJOR) ln -sf libxenstore.so.$(MAJOR) $(DESTDIR)$(LIBDIR)/libxenstore.so $(INSTALL_DATA) libxenstore.a $(DESTDIR)$(LIBDIR) - $(INSTALL_DATA) xenstore.h $(DESTDIR)$(INCLUDEDIR) - $(INSTALL_DATA) xenstore_lib.h $(DESTDIR)$(INCLUDEDIR) - $(INSTALL_DATA) compat/xs.h $(DESTDIR)$(INCLUDEDIR)/xenstore-compat/xs.h - $(INSTALL_DATA) compat/xs_lib.h $(DESTDIR)$(INCLUDEDIR)/xenstore-compat/xs_lib.h + $(INSTALL_DATA) include/xenstore.h $(DESTDIR)$(INCLUDEDIR) + $(INSTALL_DATA) include/xenstore_lib.h $(DESTDIR)$(INCLUDEDIR) + $(INSTALL_DATA) include/compat/xs.h $(DESTDIR)$(INCLUDEDIR)/xenstore-compat/xs.h + $(INSTALL_DATA) include/compat/xs_lib.h $(DESTDIR)$(INCLUDEDIR)/xenstore-compat/xs_lib.h ln -sf xenstore-compat/xs.h $(DESTDIR)$(INCLUDEDIR)/xs.h ln -sf xenstore-compat/xs_lib.h $(DESTDIR)$(INCLUDEDIR)/xs_lib.h