okay to .include "${PORTSDIR}/Mk/bsd.java.mk"?

Oliver Eikemeier eikemeier at fillmore-labs.com
Sun Jun 20 02:35:40 PDT 2004


Am Sonntag den, 20. Juni 2004, um 10:27, schrieb Sam Lawrance:

> I'm porting postgis which includes a set of Java classes related to
> spatial data types (the rest of the source is C).
>
> I would like to provide an OPTIONS line giving the user the choice
> whether to build those classes (WITH_JDBCTYPES).
>
> Problem is, after including bsd.port.pre.mk to get the OPTIONS generated
> value of WITH_JDBCTYPES, USE_JAVA has already been read.
>
> Is this okay as a workaround?
>
> .if defined(WITH_JDBCTYPES)
> USE_JAVA=	1.4+
> .include "${PORTSDIR}/Mk/bsd.java.mk"
> .endif

Please don't. It's just another hack around bugs in bsd.port.mk that 
might
break things when they are fixed. Either don't use OPTIONS or make it an
extra knob that isn't selectable via OPTIONS (like in textproc/libxml2).

While this might work, you assume that it is fine to include bsd.java.mk
after bsd.port.pre.mk, which may not be the case or may break in the
future.



More information about the freebsd-ports mailing list