[m-rev.] for review: clarify how to build and install Mercury in C#/Java grades

Julien Fischer jfischer at opturion.com
Sat Aug 9 19:38:32 AEST 2025


On Sat, 9 Aug 2025 at 18:16, Zoltan Somogyi <zoltan.somogyi at runbox.com> wrote:
>
>
> On Sat, 9 Aug 2025 17:03:55 +1000, Julien Fischer <jfischer at opturion.com> wrote:
> > +The Java version of the compiler MUST be built using `mmake`'s `--use-mmc-make`
> > +option; the build will not work otherwise. Setting the variable `GRADE` in the
> > +invocations of `mmake` is currently required to avoid variable definition
> > +ordering problems in `Mmake.workspace`.
>
> What ordering problem? A search for "order" in that file does not have
> any relevant matches, and I couldn't find any by just reading the file.
>
> Are you trying to say that Mmake.workspace simply needs to know
> the value of GRADE? In that case, is there some reason why it cannot come
> from e.g. Mmake.params, rather than the mmake command line?

Because Mmake.common includes Mmake.workspace *before* Mmake.params.

> Even if it can, I understand for including it on the recommended command line;
> I just do not understand the reference to the "ordering problem".

There are several things in Mmake.workspace that depend on the value of
GRADE.  If you only set the GRADE via the the Mmake.params file, then they
will have the wrong value. (Currently, the configure script will always pick a C
grade as the default value of GRADE.). It's been well over a decade
since I wrote
that and I can't recall what the exact problem was, although the
definitions of both
MLOBJS and LINK_RT_LIB_OPTS are likely candidates.

Julien.






>
> I don't know Java and C# builds well enough for this to be definitive,
> but I see nothing wrong with the rest of the diff.
>
> Zoltan.
>


More information about the reviews mailing list