Bug 82000 - [PATCH] sysutils/portupgrade: add option for BDB4
Summary: [PATCH] sysutils/portupgrade: add option for BDB4
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Daichi GOTO
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-06-07 17:00 UTC by Alexander Novitsky
Modified: 2005-06-29 09:04 UTC (History)
1 user (show)

See Also:


Attachments
portupgrade-20041226_5.patch (1.26 KB, patch)
2005-06-07 17:00 UTC, Alexander Novitsky
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Novitsky 2005-06-07 17:00:34 UTC
I'm sorry the one I've submitted before didn't work. Please remove PR ports/81996.

It's too boring to change this port manually to BDB4 backend each time it changed, and it doesn't work with BDB1 backend on my machine (portsdb -u craches betwean 7000 and 8000 port).

So please add this option to choose betwean BDB1 and BDB4 backend by port config, not by manual fixing the port.


Port maintainer (knu@FreeBSD.org) is cc'd.

Generated with FreeBSD Port Tools 0.63
Comment 1 Erwin Lansing freebsd_committer freebsd_triage 2005-06-07 17:29:05 UTC
Responsible Changed
From-To: freebsd-ports-bugs->knu

Over to maintainer
Comment 2 Daichi GOTO freebsd_committer freebsd_triage 2005-06-22 06:54:26 UTC
State Changed
From-To: open->feedback

Over to new maintainer. 


Comment 3 Daichi GOTO freebsd_committer freebsd_triage 2005-06-22 06:54:26 UTC
Responsible Changed
From-To: knu->daichi

Grab.
Comment 4 KOMATSU Shinichiro 2005-06-28 03:07:49 UTC
Hello,

> It's too boring to change this port manually to BDB4 backend each time it changed, and it doesn't work with BDB1 backend on my machine (portsdb -u craches betwean 7000 and 8000 port).
> 
> So please add this option to choose betwean BDB1 and BDB4 backend by port config, not by manual fixing the port.

I slightly modified your patch as follows:

(1) Do not change default dependency (depend on ruby-bdb1), 
    since ruby-bdb (BDB >= 2) support is not so tested.
(2) Thus, no PORTREVISION bump.

If there is no problem or objection, I will have this patch committed.


Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/sysutils/portupgrade/Makefile,v
retrieving revision 1.199
diff -u -r1.199 Makefile
--- Makefile	26 Jun 2005 17:22:58 -0000	1.199
+++ Makefile	27 Jun 2005 15:16:25 -0000
@@ -26,9 +26,7 @@
 MAINTAINER=	koma2@lovepeers.org
 COMMENT=	FreeBSD ports/packages administration and management tool suite
 
-RUN_DEPENDS=	${RUBY_SITEARCHLIBDIR}/bdb1.so:${PORTSDIR}/databases/ruby-bdb1
-# For PKG_DBDRIVER={bdb_btree,bdb_hash,bdb}
-#		${RUBY_SITEARCHLIBDIR}/bdb.so:${PORTSDIR}/databases/ruby-bdb
+OPTIONS=	BDB4 "Use Berkeley DB >=2 as backend. (Use BDB 1.85 if off)" off
 
 USE_RC_SUBR=	yes
 USE_BZIP2=	yes
@@ -61,6 +59,13 @@
 
 .include <bsd.port.pre.mk>
 
+.if defined(WITH_BDB4)
+# For PKG_DBDRIVER={bdb_btree,bdb_hash,bdb}
+RUN_DEPENDS=	${RUBY_SITEARCHLIBDIR}/bdb.so:${PORTSDIR}/databases/ruby-bdb
+.else
+RUN_DEPENDS=	${RUBY_SITEARCHLIBDIR}/bdb1.so:${PORTSDIR}/databases/ruby-bdb1
+.endif
+
 # pkg_create(1) must support -b. (4.5-RELEASE or later)
 # XXX: PKG_CMD is not defined yet..
 PKG_CREATE_OK!=	/usr/sbin/pkg_create 2>&1 | ${GREP} ' -b ' || ${TRUE}

---
KOMATSU Shinichiro (new portupgrade maintainer)
Comment 5 Daichi GOTO freebsd_committer freebsd_triage 2005-06-29 09:03:47 UTC
State Changed
From-To: feedback->closed

Committed. Thanks!