[Chapel Merge] Incorporate ArgumentParser in mason run and mason

Branch: refs/heads/main
Revision: da30e27
Author: arezaii
Log Message:

Merge pull request #18409 from arezaii/mason-run-build-parsing

Incorporate ArgumentParser in mason run and mason build subcommands

This PR adds the ArgumentParser module to mason run and mason build
subcommands.

The scope of the work is described in cray/chapel-private#2502.

With this change, we will start properly recognizing the -- to indicate
arguments that follow should be directed to the runtime or compiler.
If a user had previously setup a script that mixed the runtime/compiler
arguments with the subcommand arguments, they will likely encounter
a runtime error going forward and will need to restructure their input.

TESTING:

After running make cleanall from $CHPL_HOME:

  • [x] Can make
  • [x] Can make docs
  • [x] Can make mason
  • [x] Can make check
  • [x] Passing tests from util/start_test test/mason/

Reviewed by @mppf, thanks!

Signed-off-by: arezaii ahmad.rezaii@hpe.com

Modified Files:
M doc/rst/tools/mason/mason.rst

M test/library/packages/ArgumentParser/ArgumentParserTests.chpl
M test/library/packages/ArgumentParser/ArgumentParserTests.good
M test/mason/build/noDeps.chpl
M test/mason/mason-example-with-opts/mason-example.chpl
M test/mason/mason-example/mason-example.chpl
M test/mason/mason-external/libtomlc99/mason-external.chpl
M test/mason/run/mason-run.chpl
M test/mason/subdir-commands/mason-run.chpl
M tools/mason/MasonBuild.chpl
M tools/mason/MasonRun.chpl
M tools/mason/mason.chpl

Compare: https://github.com/chapel-lang/chapel/compare/95b0a40bbb0b...da30e2764539