From: Dana Jansens Date: Mon, 11 Nov 2002 03:09:26 +0000 (+0000) Subject: dont build xftlsfonts when no xft found or xft2 found X-Git-Tag: openbox-2_1_3^2~18 X-Git-Url: http://git.openbox.org/?a=commitdiff_plain;h=63c3907a6b209272319f17781f2ea4906dacaf9e;p=dana%2Fopenbox.git dont build xftlsfonts when no xft found or xft2 found --- diff --git a/configure.in b/configure.in index 758757c5..5e699972 100644 --- a/configure.in +++ b/configure.in @@ -138,7 +138,6 @@ fi dnl Check for Xft extension support and proper library files. XFT="" XFT2="" -OLDLIBS=${LIBS} dnl XFT_UTF8="" AC_MSG_CHECKING([whether to build support for the Xft extension]) AC_ARG_ENABLE( @@ -183,10 +182,10 @@ if test "$XFT" = "yes"; then dnl if test "$XFT_UTF8" = "yes"; then dnl AC_DEFINE(XFT_UTF8,1,[Support for Utf8 text in the Xft extension]) dnl fi -else - LIBS=${OLDLIBS} fi - +AM_CONDITIONAL(XFT, test "$XFT" = "yes") +AM_CONDITIONAL(XFT2, test "$XFT2" = "yes"); + dnl Check for ordered 8bpp dithering ORDEREDPSEUDO="" AC_MSG_CHECKING([whether to include Pseudocolor ordered dithering code]) diff --git a/util/Makefile.am b/util/Makefile.am index 118c56fc..a855954d 100644 --- a/util/Makefile.am +++ b/util/Makefile.am @@ -2,15 +2,21 @@ CPPFLAGS= @CPPFLAGS@ @DEBUG@ -SUBDIRS = epist +SUBDIRS = epist bin_SCRIPTS = bsetbg -bin_PROGRAMS = bsetroot xftlsfonts + +if XFT +if XFT2 +else +TMP_PROGS = xftlsfonts +endif +endif + +bin_PROGRAMS = bsetroot $(TMP_PROGS) bsetroot_SOURCES = bsetroot.cc bsetroot_LDADD = ../src/BaseDisplay.o ../src/Color.o ../src/GCCache.o ../src/Texture.o ../src/Timer.o ../src/Image.o ../src/ImageControl.o ../src/i18n.o ../src/Util.o -xftlsfonts_SOURCES = xftlsfonts.cc - MAINTAINERCLEANFILES = Makefile.in distclean-local: diff --git a/util/xftlsfonts.cc b/util/xftlsfonts.cc index bc55bdc3..932ffc74 100644 --- a/util/xftlsfonts.cc +++ b/util/xftlsfonts.cc @@ -5,20 +5,6 @@ const char *VERSION = "1.0"; #include "../config.h" #endif // HAVE_CONFIG_H -#ifndef XFT -#include -using std::cout; -using std::endl; - -int main(int, char **) { - cout << NAME << " version " << VERSION << endl; - cout << "Copyright (c) 2002, Ben Jansens " << endl; - cout << endl; - cout << "Openbox was built without support for Xft fonts. This utility must" - << endl; - cout << "must be built with Xft support in order to function." << endl; -} -#else // XFT extern "C" { #include #include @@ -144,5 +130,3 @@ int main(int argc, char **argv) { XCloseDisplay(display); return 0; } -#endif // XFT -