[m-rev.] for review: do not use .exe extension with ug_invocation dependencies

Julien Fischer jfischer at opturion.com
Mon Jul 21 16:46:32 AEST 2025


For review by Zoltan.

The request for review is for the explanatory comment.

------

Do not use .exe extension with ug_invocation dependencies.

doc/Mmakefile:
    As above. Add a comment explaining why this works.

Julien.

diff --git a/doc/Mmakefile b/doc/Mmakefile
index f08268966..64d17ba2c 100644
--- a/doc/Mmakefile
+++ b/doc/Mmakefile
@@ -173,7 +173,11 @@ ifdef BUILD_SRCDIST
 UG_INVOCATION_DEP=
 UG_INVOCATION_MC=$(MC)
 else
-UG_INVOCATION_DEP=../compiler/mercury_compile$(EXT_FOR_EXE)
+# We do not specify the executable extension (.exe) on Windows here because it
+# will not be present for the launcher scripts generated in the non-C grades.
+# This does not matter because the PATHEXT mechanism will cause the shell and
+# gmake to account for it in C grades (where the extension is present).
+UG_INVOCATION_DEP=../compiler/mercury_compile
 UG_INVOCATION_MC=../compiler/mercury_compile
 endif


More information about the reviews mailing list