[m-users.] adding grades

Sean Charles (emacstheviking) objitsu at gmail.com
Thu Jan 20 01:48:42 AEDT 2022


Fabulous! Thanks Julien, I will give that a try in the next day or so… my project is starting to work well as a standalone executable but I am considering making the guts of it usable as a library JAR file as well for JVM solutions as well.

Thanks,
Sean


> On 19 Jan 2022, at 13:57, Julien Fischer <jfischer at opturion.com> wrote:
> 
> 
> Hi Sean,
> 
> On Wed, 19 Jan 2022, Sean Charles (emacstheviking) wrote:
> 
>> I currently only have high-level C grade but I want to add Java to the list.
>> Do I need to rebuild with C and Java or can I augment an existing
>> build deplyment by just specifying Java this time?
> 
> Coincidently, I've just been discussing this with Zoltan over in the
> reviews list.  Most of the Mercury system supports installing extras
> grades after the initial installation -- the one major exception to that
> is mmake, but if you're planning to use the java grade, that's not
> relevant anyway since the java grade only works with mmc --make.
> 
> Assuming you still have the source tree from your initial install
> lying about, you should be able to do something like the following:
> 
> 1. Edit the top-level Mmakefile as per the following diff:
> 
> -----------------------------------------------------------
> diff --git a/Mmakefile b/Mmakefile
> index 506fa24..c97ed4b 100644
> --- a/Mmakefile
> +++ b/Mmakefile
> @@ -716,7 +716,7 @@ OVERRIDE_MC_FOR_LIBGRADE = MC=mmc \
> endif
> 
> .PHONY: install_grades
> -install_grades: install_main
> +install_grades:
>        # Use the newly installed compiler to build the libraries in
>        # various
>        # different grades. Except when cross-compiling, we override
>        # MC=mmc so
>        # that we use the mmc from the scripts directory, which runs the
>        # newly
> ------------------------------------------------------------
> 
> This will prevent the compiler itself be reinstalled.
> 
> 2. Do:
> 
>   $ mmake install_grades LIBGRADES="java"
> 
> Julien.



More information about the users mailing list