Mark Linimon sent a PR regarding improvement to the ports system that has
been commited during January. Unfortunately, we then commited version 2.0 of
bsd.java.mk which was based on an earlier snapshot and thus we did override the
This patch implements the feature proposed by Mark for the latest version of
Ironically, I realized by doing this patch that the original patch from Mark
seemed to be broken regarding bsd.java.mk (a typo: "check-makevers" ->
"check-makevars"). This issue is only related to bsd.java.mk so AFAICT the
remaining of the original patch is fine.
To test the patch:
$ cd /usr/ports/java/trove4j && make -DJAVA_BUILD
trove4j-1.1b3: Makefile error: JAVA_BUILD and NO_BUILD cannot be set at the same time.
*** Error code 1
Stop in /usr/ports/java/trove4j.
$ cd /usr/ports && make java/trove4j -DJAVA_BUILD
`java/trove4j' is up to date.
* Ernst de Haan is cc'd as he is the maintainer of bsd.java.mk
* Greg Lewis is cc'd as he is the commiter of the most recent changes to
* Mark Linimon is cc'd as he is the originator of the initial PR
I'll take this.
On Wed, 30 Jun 2004, Herve Quiroz wrote:
> Ironically, I realized by doing this patch that the original patch from Mark
> seemed to be broken regarding bsd.java.mk (a typo: "check-makevers" ->
Yep, just a typo. I vaguely remember doing some regression testing
with setting up bogus user environments and trying to exercise each
code path, but I must have missed that one.
For those that don't understand the impact of the changes, they are
designed to allow 'make index' and 'make search' to succeed despite
any bogus user environment. The use of .BEGIN or .error directives
in Makefiles introduces such fragility; they should only be used in
cases to indicate that the ports infrastructure itself is broken
(has had a bad commit to the master repository), rather than that
there is some invalid setup on an individual machine.
And yes, I know that we have a number of these scattered around.
They all need to be fixed.