summaryrefslogtreecommitdiff
path: root/databases
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2004-03-10 18:06:06 +0000
committerjlam <jlam@pkgsrc.org>2004-03-10 18:06:06 +0000
commitc35aa8092f99f682360aa42bfed40c908dbde325 (patch)
treedb85246ca11f0ab347f176fdc44b7a6e372b2f41 /databases
parent2653555f39c8797935782d2da9465efa829a5584 (diff)
downloadpkgsrc-c35aa8092f99f682360aa42bfed40c908dbde325.tar.gz
bdb.buildlink3.mk is used to select a Berkeley DB implementation for
use by pkgsrc. It will automatically depend on either db, db3, or db4 if the native one isn't sufficient. The two variables that control its behaviour are: BDB_DEFAULT is a user-settable variable whose value is the default Berkeley DB implementation to use. BDB_ACCEPTED is a package-settable list of Berkeley DB implementations that may be used by the package. E.g., if you always want to use DB4 as the Berkeley DB for all of the packages, then you can just set: BDB_DEFAULT= db4 in your /etc/mk.conf. Packages that currently include db*/buildlink3.mk should be made to include bdb.buildlink3.mk instead.
Diffstat (limited to 'databases')
-rw-r--r--databases/db/buildlink3.mk52
-rw-r--r--databases/db3/buildlink3.mk8
-rw-r--r--databases/db4/buildlink3.mk9
3 files changed, 29 insertions, 40 deletions
diff --git a/databases/db/buildlink3.mk b/databases/db/buildlink3.mk
index 417761f2d92..c05341eea3d 100644
--- a/databases/db/buildlink3.mk
+++ b/databases/db/buildlink3.mk
@@ -1,48 +1,26 @@
-# $NetBSD: buildlink3.mk,v 1.10 2004/02/06 19:04:24 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.11 2004/03/10 18:06:07 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
-DB2_BUILDLINK3_MK:= ${DB2_BUILDLINK3_MK}+
+DB_BUILDLINK3_MK:= ${DB_BUILDLINK3_MK}+
.include "../../mk/bsd.prefs.mk"
-.if !empty(DB2_BUILDLINK3_MK:M+)
-BUILDLINK_PACKAGES+= db
-BUILDLINK_DEPENDS.db+= db>=2.7.3
-BUILDLINK_PKGSRCDIR.db?= ../../databases/db
-.endif # DB2_BUILDLINK3_MK
-
-.if !empty(PREFER_PKGSRC:M[yY][eE][sS]) || \
- !empty(PREFER_PKGSRC:Mdb)
-BUILDLINK_USE_BUILTIN.db= NO
+.if !empty(BUILDLINK_DEPTH:M+)
+BUILDLINK_DEPENDS+= db2
.endif
-.if !defined(BUILDLINK_USE_BUILTIN.db)
-BUILDLINK_USE_BUILTIN.db= NO
-. if defined(USE_DB185)
-. if exists(/usr/include/db.h)
-# NetBSD, Darwin
-BUILDLINK_USE_BUILTIN.db= YES
-. elif exists(/usr/include/db1/db.h)
-# Linux
-BUILDLINK_USE_BUILTIN.db= YES
-BUILDLINK_INCDIRS.db?= include/db1
-BUILDLINK_TRANSFORM+= l:db:db1
-. endif
-. endif
-MAKEFLAGS+= BUILDLINK_USE_BUILTIN.db=${BUILDLINK_USE_BUILTIN.db}
-.endif
+BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Ndb2}
+BUILDLINK_PACKAGES+= db2
-.if !empty(BUILDLINK_USE_BUILTIN.db:M[nN][oO])
-. if !empty(BUILDLINK_DEPTH:M+)
-BUILDLINK_DEPENDS+= db
-. endif
-.endif
+.if !empty(DB_BUILDLINK3_MK:M+)
+BUILDLINK_DEPENDS.db2+= db>=2.7.3
+BUILDLINK_PKGSRCDIR.db2?= ../../databases/db
-.if !empty(DB2_BUILDLINK3_MK:M+)
-. if !empty(BUILDLINK_USE_BUILTIN.db:M[nN][oO])
-BUILDLINK_INCDIRS.db= include/db2
+.if defined(USE_DB185)
+BUILDLINK_INCDIRS.db2?= include/db2
BUILDLINK_TRANSFORM+= l:db:db2
-. endif
-.endif # DB2_BUILDLINK3_MK
+.endif
+
+.endif # DB_BUILDLINK3_MK
-BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//}
+BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//}
diff --git a/databases/db3/buildlink3.mk b/databases/db3/buildlink3.mk
index ace68444e77..69bd9f16bff 100644
--- a/databases/db3/buildlink3.mk
+++ b/databases/db3/buildlink3.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink3.mk,v 1.5 2004/03/05 19:25:09 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.6 2004/03/10 18:06:07 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
DB3_BUILDLINK3_MK:= ${DB3_BUILDLINK3_MK}+
@@ -13,6 +13,12 @@ BUILDLINK_PACKAGES+= db3
.if !empty(DB3_BUILDLINK3_MK:M+)
BUILDLINK_DEPENDS.db3+= db3>=2.9.2
BUILDLINK_PKGSRCDIR.db3?= ../../databases/db3
+
+.if defined(USE_DB185)
+BUILDLINK_INCDIRS.db3?= include/db3
+BUILDLINK_TRANSFORM+= l:db:db3
+.endif
+
.endif # DB3_BUILDLINK3_MK
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//}
diff --git a/databases/db4/buildlink3.mk b/databases/db4/buildlink3.mk
index 1e75e0f936f..72fd234f6fd 100644
--- a/databases/db4/buildlink3.mk
+++ b/databases/db4/buildlink3.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink3.mk,v 1.7 2004/03/05 19:25:09 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.8 2004/03/10 18:06:08 jlam Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
DB4_BUILDLINK3_MK:= ${DB4_BUILDLINK3_MK}+
@@ -13,7 +13,12 @@ BUILDLINK_PACKAGES+= db4
.if !empty(DB4_BUILDLINK3_MK:M+)
BUILDLINK_DEPENDS.db4+= db4>=4.2.52
BUILDLINK_PKGSRCDIR.db4?= ../../databases/db4
-BUILDLINK_INCDIRS.db4?= include/db4
+
+.if defined(USE_DB185)
+BUILDLINK_INCDIRS.db3?= include/db4
+BUILDLINK_TRANSFORM+= l:db:db4
+.endif
+
.endif # DB4_BUILDLINK3_MK
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH:S/+$//}