[nycbug-talk] FreeBSD Porting

Steven Kreuzer skreuzer at f2o.org
Fri Oct 20 16:26:47 EDT 2006


In a nutshell, I am hacking the bind9 port so that there is the option
to compile in support for GeoDNS. I created an option called GEODNS and
a little hook that looks like this:

.if defined(WITH_GEODNS)
LIB_DEPENDS=   GeoIP.5:${PORTSDIR}/net/GeoIP
BUILD_DEPENDS= ${LOCALBASE}/include/GeoIP.h:${PORTSDIR}/net/GeoIP
RUN_DEPENDS=   ${LIB_DEPENDS}
CONFIGURE_ENV+= LDFLAGS="-L${LOCALBASE}/lib -lGeoIP"
CFLAGS="-I${LOCALBASE}/include"
.endif

However, I also need to apply 3 patches the the bind source to enable
this feature. I created diff's and put them in the files directory.
However, those patches get applied regardless of the options selected.

Do you know of any way to apply those patches only if WITH_GEODNS is
true? According to the porter handbook, it looks like all or nothing?

Anyone have any hacks or tricks?

Thanks,

Steven



More information about the talk mailing list