Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 23 Apr 2005 15:56:48 +0930
From:      "Paul A. Hoadley" <paulh@logicsquad.net>
To:        freebsd-ports@freebsd.org
Subject:   Depending on other ports with OPTIONS
Message-ID:  <20050423062648.GE61472@bigbird.logicsquad.net>

next in thread | raw e-mail | index | archive | help

--ftEhullJWpWg/VHq
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Hello,

I am currently making my first port: RefDB [1].  I have been quite
carefully reading the Porter's Handbook, and examining other ports,
and on the whole it is proceeding quite smoothly.

I am using OPTIONS in the Makefile for RefDB (a user can choose MySQL,
PostgreSQL or SQLite as the back-end DB).  RefDB depends on libdbi,
and, of course, the specific libdbi-driver corresponding to the chosen
database.

Based on another port's Makefile, I have been setting RUN_DEPENDS to
check for the specific libdbi-driver.  For example, if a user chooses
MySQL as the backend for RefDB, I have this:

=2Eif defined(WITH_MYSQL)
USE_MYSQL=3D	yes
RUN_DEPENDS+=3D	${LOCALBASE}/lib/dbd/libmysql.so:${PORTSDIR}/databases/libd=
bi-drivers
CONFIGURE_ARGS+=3D	--with-db-server=3Dmysql
=2Eendif

The problem is this.  Say I run 'make install' for my new port, and
choose MySQL.  If libdbi-drivers has never been installed, that's fine
and I can select the MySQL driver from it's options.  Say I don't
install any other drivers, then run 'make deinstall clean rmconfig
install' for RefDB, but this time choose PostgreSQL as the DB from my
options.  It will certainly notice that libpgsql.so is missing, and
run install in libdbi-drivers, but the options there are already saved
and obviously not re-presented.  Hence libpgsql.so remains unbuilt and
uninstalled.

This must be a common problem, and I hope it's not too much of a FAQ
for the list.  How can I do the equivalent of 'rmconfig install' in
libdbi-drivers when I change options when building the RefDB port?


[1] http://refdb.sourceforge.net/


--=20
Paul.

w  http://logicsquad.net/
h  http://paul.hoadley.name/

--ftEhullJWpWg/VHq
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (FreeBSD)

iD8DBQFCaeqo730Z/jysbzIRAt2MAJ0egN/k+nFfGcRO7uRUV4spNU9DmACeLT14
8qKDWqvdyDe9qRO69KLGipU=
=pr52
-----END PGP SIGNATURE-----

--ftEhullJWpWg/VHq--



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