From mboxrd@z Thu Jan 1 00:00:00 1970 From: Samuel Thibault Subject: Re: [PATCH] tools: Check presence of ncurses Date: Tue, 4 Mar 2008 11:42:52 +0000 Message-ID: <20080304114252.GB5038@implementation.uk.xensource.com> References: <20080304110725.GA5038@implementation.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Keir Fraser, le Tue 04 Mar 2008 11:24:46 +0000, a écrit : > Will this break cross-compile environments? Xentop is not built in that case > (hence no dependency on curses.h), yet your new check will still be > enforced. If it is the xentop usage that you are wanting to protect with a > check, perhaps the compile-or-not decision in xenstat/Makefile should be > made dynamically based on presence of curses.h? Something like this then: tools: Compile xentop only if curses are available. Signed-off-by: Samuel Thibault diff -r c89f6ed56351 tools/xenstat/Makefile --- a/tools/xenstat/Makefile Mon Mar 03 11:47:40 2008 +0000 +++ b/tools/xenstat/Makefile Tue Mar 04 11:41:24 2008 +0000 @@ -6,7 +6,9 @@ SUBDIRS += libxenstat # This doesn't cross-compile (cross-compile environments rarely have curses) ifeq ($(XEN_COMPILE_ARCH),$(XEN_TARGET_ARCH)) +ifeq ($(wildcard /usr/include/curses.h),/usr/include/curses.h) SUBDIRS += xentop +endif endif .PHONY: all install clean