Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Nov 2004 06:00:22 -0600
From:      "Conrad J. Sabatier" <conrads@cox.net>
To:        Matthias Andree <matthias.andree@gmx.de>
Cc:        Bauno <bauno@inwind.it>
Subject:   Re: porting klibido to FreeBSD
Message-ID:  <20041129060022.6e1e346c@dolphin.local.net>
In-Reply-To: <20041128211346.GC25374@merlin.emma.line.org>
References:  <20041127191925.69c8994c@dolphin.local.net> <20041127194736.0198f21f@dolphin.local.net> <200411281723.28744.bauno@inwind.it> <20041128130321.6f984751@dolphin.local.net> <20041128211346.GC25374@merlin.emma.line.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 28 Nov 2004 22:13:46 +0100, Matthias Andree
<matthias.andree@gmx.de> wrote:

> On Sun, 28 Nov 2004, Conrad J. Sabatier wrote:
> 
> > On Sun, 28 Nov 2004 17:23:28 +0100, Bauno <bauno@inwind.it> wrote:
> > 
> > > On Sunday 28 November 2004 02:47, you wrote:
> > > > A little more detail I should have provided before:
> > > >
> > > > The FreeBSD db4 call's arguments are defined as this:
> > > >
> > > > int
> > > > Db::open(const char *file,
> > > >     const char *database, DBTYPE type, u_int32_t flags, int
> > > >     mode);
> > > >
> > > 
> > > Tha'ts what I'm using: 
> > > 
> > > int
> > > Db::open(DbTxn *txnid, const char *file,
> > >     const char *database, DBTYPE type, u_int32_t flags, int mode);
> > > 
> > > 
> > > It's from Db 4.2, but I used it with db 4.1 as well, with no
> > > problems. The DbTxn *txnid is the transaction handler, it seems
> > > strange it's missing...that would mean the Bdb in freebsd can't be
> > > used as a transactional data store. 
> > > 
> > > What version of Berkeley Db is installed on Freebsd?
> 
> I didn't get where this started, and figured you got it solved,
> congratulations on that.

Yes, I now have it actually running.

Still some problems to work out, though.  For one thing, the program
crashes every time I try to subscribe to a group.  I expect, though,
that this problem will clear up once I get about the business of
converting it into a proper port and get the various make options and a
decent set of patches worked out.

> Berkeley DB has been offering the transactional datastore since
> version 3.0 if I recall correctly (but I never bothered for 2.x), and
> the developer version of bogofilter (in the bogofilter CVS) works with
> Berkeley DB 3.0 to 4.3 (port commit is pending, ports/73790). It's all
> a real mess because SleepyCat changed the interface between minor
> releases, as you've found out the hard way.  Add a txnid argument
> here, remove an option or flag there... every version is different.
> 
> The hoops we need to jump in bogofilter are documented in the
> DB_AT_LEAST, DB_EQUAL, DB_AT_MOST macros in our DB interface:
> http://cvs.sourceforge.net/viewcvs.py/bogofilter/bogofilter/src/datastore_db.c?view=markup

Cool, I'll definitely take a look.

> You'll find information in the Berkeley DB reference documentation in
> the chapter "Upgrading Berkeley DB Applications", if you're looking at
> 4.2's document, it has the documentation all the way back to 1.85.
> Look for ref/toc.html underneath $DOCSDIR.

Yes, I've looked at the docs a bit, but need to do a lot more.  This is
my first time dealing with a port that uses this stuff, so I'm sort of
"out of my element" here.

Still, this program (klibido) is definitely worth the effort, and will
make a fine addition to FreeBSD's ports collections, once I get all the
kinks worked out.

Thanks.

-- 
Conrad J. Sabatier <conrads@cox.net> -- "In Unix veritas"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20041129060022.6e1e346c>