diff options
author | Gaius Mulley <gaius.mulley@southwales.ac.uk> | 2022-05-30 21:05:35 +0100 |
---|---|---|
committer | Gaius Mulley <gaius.mulley@southwales.ac.uk> | 2022-05-30 21:05:35 +0100 |
commit | 5eb238ce0b2dcbcb0737def243c9d18651270363 (patch) | |
tree | 114a32353df6728632b0a1cc6fd403fd6807711d /gcc/m2/gm2-compiler/M2Options.mod | |
parent | 622a723be0a71fdc2602882d07e8b00e37ad00fb (diff) | |
download | gcc-5eb238ce0b2dcbcb0737def243c9d18651270363.tar.gz |
Remove m2 front end linking support.
2022-05-30 Gaius Mulley <gaius.mulley@southwales.ac.uk>
All m2 linking assistance by the Modula-2 front end is disabled.
cc1gm2 handles the -c option but currently does nothing with the option.
New gcc/testsuite/gm2/link/externalscaffold added to check the compiler
can link trivial application against a hand built scaffold.
gcc/testsuite/gm2/ChangeLog:
* link/externalscaffold: (New regression test). Manual linking
test using external scaffold.
gcc/m2/ChangeLog:
* gm2-compiler/M2Options.def (cflag): New boolean.
(Setc) New procedure. (Getc) New procedure function.
* gm2-compiler/M2Options.mod (Setc): New procedure.
(Getc) New procedure function. Initialize cflag to
FALSE.
* gm2-gcc/m2options.h (Setc): New external function.
(Getc) New external function.
* gm2-lang.cc: Handle OPT_c and call M2Options_Setc.
* lang-specs.h: Remove all link rules for m2.
* lang.opt: Allow m2 to process the -c option.
Signed-off-by: Gaius Mulley <gaius.mulley@southwales.ac.uk>
Diffstat (limited to 'gcc/m2/gm2-compiler/M2Options.mod')
-rw-r--r-- | gcc/m2/gm2-compiler/M2Options.mod | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc/m2/gm2-compiler/M2Options.mod b/gcc/m2/gm2-compiler/M2Options.mod index ed606cfeda1..510742c3f2a 100644 --- a/gcc/m2/gm2-compiler/M2Options.mod +++ b/gcc/m2/gm2-compiler/M2Options.mod @@ -382,6 +382,26 @@ END GetCpp ; (* + Setc - set the cflag (compile only flag -c) to value. +*) + +PROCEDURE Setc (value: BOOLEAN) ; +BEGIN + cflag := value +END Setc ; + + +(* + Getc - get the cflag (compile only flag -c). +*) + +PROCEDURE Getc () : BOOLEAN ; +BEGIN + RETURN cflag +END Getc ; + + +(* SetM2g - returns TRUE if the -fm2-g flags was used. *) @@ -1016,6 +1036,7 @@ END SetSaveTempsDir ; BEGIN + cflag := FALSE ; (* -c. *) CppArgs := InitString ('') ; CppProgram := InitString ('') ; Pim := TRUE ; |