diff options
-rw-r--r-- | graphics/xpm/Makefile | 14 | ||||
-rw-r--r-- | mk/bsd.pkg.mk | 16 | ||||
-rw-r--r-- | mk/bsd.prefs.mk | 19 |
3 files changed, 28 insertions, 21 deletions
diff --git a/graphics/xpm/Makefile b/graphics/xpm/Makefile index eea59b8aa61..50db8e8a0e4 100644 --- a/graphics/xpm/Makefile +++ b/graphics/xpm/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.18 2001/06/08 21:30:35 tron Exp $ +# $NetBSD: Makefile,v 1.19 2001/07/02 08:02:34 jlam Exp $ DISTNAME= xpm-3.4k CATEGORIES= graphics x11 @@ -8,16 +8,14 @@ MAINTAINER= mycroft@netbsd.org HOMEPAGE= http://www.inria.fr/koala/lehors/xpm.html COMMENT= The X Pixmap library -USE_IMAKE= yes +USE_IMAKE= # defined +CHECK_XPM= # defined -.if !defined(CHECK_XPM) -IS_BUILTIN_XPM!= ${MAKE} CHECK_XPM=YES USE_XPM=YES VARNAME=IS_BUILTIN_XPM show-var -.if (${IS_BUILTIN_XPM} != "0") +.include "../../mk/bsd.prefs.mk" + +.if ${HAVE_BUILTIN_XPM} != "NO" IGNORE= "The Xpm library is included in your X11 distribution." .endif -.endif - -.include "../../mk/bsd.prefs.mk" .if (${OPSYS} == SunOS) post-install: diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk index a71e91f5754..426281f665f 100644 --- a/mk/bsd.pkg.mk +++ b/mk/bsd.pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.mk,v 1.774 2001/07/01 21:13:20 jlam Exp $ +# $NetBSD: bsd.pkg.mk,v 1.775 2001/07/02 08:02:33 jlam Exp $ # # This file is in the public domain. # @@ -723,23 +723,15 @@ DEPENDS+= ${LESSTIF_DEPENDS} .endif .endif # USE_MOTIF -# Check if we got Xpm distributed with XFree86 4.0 or newer or if we -# need to use the package. +# If USE_XPM is set, depend on xpm. .if defined(USE_XPM) -.if !defined(IS_BUILTIN_XPM) -.if exists(${X11BASE}/include/X11/xpm.h) -IS_BUILTIN_XPM!= ${EGREP} -c NormalLibXpm ${X11BASE}/lib/X11/config/X11.tmpl || ${TRUE} -MAKEFLAGS+= IS_BUILTIN_XPM=${IS_BUILTIN_XPM} -.else -IS_BUILTIN_XPM= 0 -.endif -.endif -.if (${IS_BUILTIN_XPM} == "0") +.if ${HAVE_BUILTIN_XPM} == "NO" DEPENDS+= xpm-3.4k:../../graphics/xpm XPMDIR_DEFAULT= ${X11PREFIX} .else XPMDIR_DEFAULT= ${X11BASE} .endif +.undef __BUILTIN_XPM .endif # USE_XPM # If USE_MESA is set, depend on Mesa (or Mesa-glx if USE_GLX is defined and diff --git a/mk/bsd.prefs.mk b/mk/bsd.prefs.mk index 8b186e24e2f..d13a2ba77e0 100644 --- a/mk/bsd.prefs.mk +++ b/mk/bsd.prefs.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.prefs.mk,v 1.45 2001/06/28 13:16:56 drochner Exp $ +# $NetBSD: bsd.prefs.mk,v 1.46 2001/07/02 08:02:34 jlam Exp $ # # Make file, included to get the site preferences, if any. Should # only be included by package Makefiles before any .if defined() @@ -184,6 +184,23 @@ HAVE_BUILTIN_FREETYPE2= YES .undef __BUILTIN_FREETYPE2 .endif # CHECK_FREETYPE2 +# Check if we got Xpm distributed with XFree86 4.x or if we need to +# depend on the Xpm package. +.if (defined(CHECK_XPM) || defined(USE_XPM)) +X11BASE?= /usr/X11R6 +.if exists(${X11BASE}/include/X11/xpm.h) +__BUILTIN_XPM!= ${EGREP} -c NormalLibXpm ${X11BASE}/lib/X11/config/X11.tmpl || ${TRUE} +.else +__BUILTIN_XPM= 0 +.endif +.if ${__BUILTIN_XPM} == "0" +HAVE_BUILTIN_XPM= NO +.else +HAVE_BUILTIN_XPM= YES +.endif +.undef __BUILTIN_XPM +.endif # CHECK_XPM + .if defined(USE_CURSES) && !defined(NEED_NCURSES) NEED_NCURSES= NO .if ${OPSYS} == "NetBSD" |