Problem
CI runs the default net6.0 test flow, but the build fails on Linux/macOS with
mono: command not found, though net6.0 doesn't need net462 or Mono.
Cause: build.proj's Test → Build compiles the whole solution, which
includes the net462 Clojure.Compile project even if the CI is testing net6.0 which
doesn't need Mono. Its post-build target
(Clojure.Compile.csproj) AOT-compiles the standard library by running the
net462 compiler, via Mono for Unix:
<TargetCmdline Condition=" '$(OS)' == 'Unix' ">mono $(TargetPath)</TargetCmdline>
So net6.0 CI drags in Mono purely as a build side-effect, to produce net462
artifacts it never loads (net6.0 loads the stdlib from source / embedded resources
at startup; only net462 needs the AOT + ILMerge).
Current stopgap
.github/workflows/tests.yml now installs Mono on the Linux/macOS too.
Why decouple
- Removes an irrelevant dependency
- Clearer build graph
Proposed approach
When TestTargetFramework != net462, don't build Clojure.Compile /
Clojure.Main461 (or skip the Mono AOT post-build).
Problem
CI runs the default net6.0 test flow, but the build fails on Linux/macOS with
mono: command not found, though net6.0 doesn't need net462 or Mono.Cause:
build.proj'sTest→Buildcompiles the whole solution, whichincludes the net462
Clojure.Compileproject even if the CI is testing net6.0 whichdoesn't need Mono. Its post-build target
(
Clojure.Compile.csproj) AOT-compiles the standard library by running thenet462 compiler, via Mono for Unix:
So net6.0 CI drags in Mono purely as a build side-effect, to produce net462
artifacts it never loads (net6.0 loads the stdlib from source / embedded resources
at startup; only net462 needs the AOT + ILMerge).
Current stopgap
.github/workflows/tests.ymlnow installs Mono on the Linux/macOS too.Why decouple
Proposed approach
When
TestTargetFramework != net462, don't buildClojure.Compile/Clojure.Main461(or skip the Mono AOT post-build).