GCC Newspaper
NOVEMBER 30, 2026
Date
/
Architectures
Components
Topics
News & Policy
Other
modula-2

Modula-2: Fix parallel build issue with m2.pod

Modula-2 build process no longer marks m2.pod as .INTERMEDIATE to resolve parallel build hangs.

A latent bug in GNU Make 3.81 caused parallel builds involving the Modula-2 compiler to hang. This issue was triggered by marking the m2.pod file as .INTERMEDIATE. The fix removes this marking and explicitly deletes m2.pod during clean builds, allowing parallel compilation to proceed without interruption.

In Details

The Modula-2 build recipe in Make-lang.in has been modified to resolve a hang in GNU Make 3.81 during parallel builds (j > 1). The problematic .INTERMEDIATE target for m2.pod has been removed, and the file is now explicitly cleaned. This change addresses a subtle difference in how Modula-2's build targets interact with Make's parallel execution compared to Fortran and D.

For Context
GNU Make
A widely used build automation tool that reads Makefiles to determine which parts of a program need to be recompiled and issues the necessary commands to do so.
.INTERMEDIATE
A special target in GNU Make that tells Make that a file is intermediate and can be deleted after it's no longer needed. This can sometimes cause issues with dependency tracking in parallel builds.
Modula-2
A procedural programming language designed by Niklaus Wirth, emphasizing modularity and strong typing. GCC includes support for compiling Modula-2 code.
make clean
A common target in Makefiles that removes all generated files, effectively returning the build directory to its original state before compilation.
Filed Under: buildmodula-2make