summaryrefslogtreecommitdiff
path: root/x11/fltk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2001-06-10 00:09:29 +0000
committerjlam <jlam@pkgsrc.org>2001-06-10 00:09:29 +0000
commit5d02f04b3aa2a8553bbc5c5b42fc941c54d5c76d (patch)
tree7a6bfc07ceedb0e0b8ac1235a0168afecaf37111 /x11/fltk
parent3bc5e40254426847ecde2acbbfab3d3fbc8e20a6 (diff)
downloadpkgsrc-5d02f04b3aa2a8553bbc5c5b42fc941c54d5c76d.tar.gz
Use cookies (.*_done) to determine whether headers and libs have been
linked from a particular package, and add a pre-configure target to the buildlink.mk file to more painlessly use buildlink.mk files. A ${BUILDLINK_TARGETS} variable still exists in case a package _must_ define NO_CONFIGURE.
Diffstat (limited to 'x11/fltk')
-rw-r--r--x11/fltk/buildlink.mk19
1 files changed, 14 insertions, 5 deletions
diff --git a/x11/fltk/buildlink.mk b/x11/fltk/buildlink.mk
index 1151487cac6..ff9255cd4ab 100644
--- a/x11/fltk/buildlink.mk
+++ b/x11/fltk/buildlink.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink.mk,v 1.3 2001/06/09 15:13:07 wiz Exp $
+# $NetBSD: buildlink.mk,v 1.4 2001/06/10 00:09:33 jlam Exp $
#
# This Makefile fragment is included by packages that use FLTK.
#
@@ -18,8 +18,6 @@ FLTK_BUILDLINK_MK= # defined
FLTK_REQD?= 1.0.9
-.include "../../graphics/Mesa/buildlink.mk"
-
FLTK_HEADERS= ${X11PREFIX}/include/FL/*
FLTK_LIBS= ${X11PREFIX}/lib/libfltk.*
DEPENDS+= fltk>=${FLTK_REQD}:../../x11/fltk
@@ -27,8 +25,17 @@ DEPENDS+= fltk>=${FLTK_REQD}:../../x11/fltk
BUILDLINK_INCDIR?= ${WRKDIR}/include
BUILDLINK_LIBDIR?= ${WRKDIR}/lib
-BUILDLINK_TARGETS+= link-fltk-headers
-BUILDLINK_TARGETS+= link-fltk-libs
+.include "../../graphics/Mesa/buildlink.mk"
+
+FLTK_BUILDLINK_COOKIE= ${WRKDIR}/.fltk_buildlink_done
+FLTK_BUILDLINK_TARGETS+= link-fltk-headers
+FLTK_BUILDLINK_TARGETS+= link-fltk-libs
+BUILDLINK_TARGETS+= ${FLTK_BUILDLINK_COOKIE}
+
+pre-configure: ${FLTK_BUILDLINK_COOKIE}
+
+${FLTK_BUILDLINK_COOKIE}: ${FLTK_BUILDLINK_TARGETS}
+ @${TOUCH} ${TOUCH_FLAGS} ${FLTK_BUILDLINK_COOKIE}
# This target links the headers into ${BUILDLINK_INCDIR}, which should
# be searched first by the C preprocessor.
@@ -59,4 +66,6 @@ link-fltk-libs:
fi; \
done
+jlam: ${FLTK_BUILDLINK_COOKIE}
+
.endif # FLTK_BUILDLINK_MK