From 73941fa2f5e5a71fb36a3b9a9dec8a833898907e Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Fri, 19 Nov 2010 22:45:57 -0800 Subject: Bug 31645 - xlogo: Doesn't build with libXrender and without libXft https://bugs.freedesktop.org/show_bug.cgi?id=31645 Add AM_CONDITIONAL to skip building RenderLogo.c without Render support Signed-off-by: Alan Coopersmith --- Makefile.am | 8 ++++++-- RenderLogo.c | 4 +++- configure.ac | 1 + 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/Makefile.am b/Makefile.am index fa8729e..51bd1dd 100644 --- a/Makefile.am +++ b/Makefile.am @@ -27,11 +27,15 @@ xlogo_SOURCES = \ Logo.c \ Logo.h \ LogoP.h \ - RenderLogo.c \ - RenderLogo.h \ xlogo.c \ xlogo.h +if USE_RENDER +xlogo_SOURCES += \ + RenderLogo.c \ + RenderLogo.h +endif + appman_PRE = \ xlogo.man diff --git a/RenderLogo.c b/RenderLogo.c index a7963fb..bb1361c 100644 --- a/RenderLogo.c +++ b/RenderLogo.c @@ -27,6 +27,8 @@ in this Software without prior written authorization from The Open Group. #ifdef HAVE_CONFIG_H #include #endif + +#ifdef XRENDER #include #include @@ -159,4 +161,4 @@ intersect(XLineDouble *l1, XLineDouble *l2, XPointDouble *intersection) fprintf(stderr, "intersect: intersection is off by %f\n", check); } } - +#endif /* XRENDER */ diff --git a/configure.ac b/configure.ac index a3357ef..4f372f6 100644 --- a/configure.ac +++ b/configure.ac @@ -53,6 +53,7 @@ if test "x$USE_RENDER" = "xyes" ; then AC_DEFINE(XRENDER, 1, [Define to 1 to use Xrender & Xft2 to draw logo]) fi +AM_CONDITIONAL([USE_RENDER], [test "x$USE_RENDER" = "xyes"]) PKG_CHECK_MODULES(XLOGO, $XLOGO_DEPS) -- cgit v1.2.3