diff options
author | Ash Wolf <ninji@wuffs.org> | 2022-10-14 23:15:32 +0100 |
---|---|---|
committer | Ash Wolf <ninji@wuffs.org> | 2022-10-14 23:15:32 +0100 |
commit | 775b6861666af36d317fb577cf489e2c6377f878 (patch) | |
tree | 2ae8c829eb861c85a6e2b5acf42f51919a0d78f2 /unsorted/ToolHelpers-cc.c | |
parent | b8df05413a4e8b299de07b915cddce73a3bb16e3 (diff) | |
download | MWCC-775b6861666af36d317fb577cf489e2c6377f878.tar.gz MWCC-775b6861666af36d317fb577cf489e2c6377f878.zip |
add tons of stuff
Diffstat (limited to '')
-rw-r--r-- | unsorted/ToolHelpers-cc.c | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/unsorted/ToolHelpers-cc.c b/unsorted/ToolHelpers-cc.c new file mode 100644 index 0000000..dd0bc92 --- /dev/null +++ b/unsorted/ToolHelpers-cc.c @@ -0,0 +1,35 @@ +#include "mwcc_decomp.h" + +int Opt_DummyLinkerRoutine(const char *opt) { + CLPFatalError("Calling linker option '%s'\n", opt); + return 0; +} + +int Opt_DummyLinkerSettingRoutine(const char *var, const char *val) { + CLPFatalError("Calling linker settings option '%s'='%s'\n", var, val ? val : ""); + return 0; +} + +void FinishCompilerTool() { + SInt32 numfiles; + + if (parseopts.lastoutputname[0]) { + numfiles = GetFileCount(); + + if (pCmdLine.stages == CmdLineStageMask_Dp) { + strcpy(pCmdLineCompiler.outMakefile, parseopts.lastoutputname); + } else if (outputOrdering == OutputOrdering2) { + if (parseopts.possibleFiles > 0 || parseopts.userSpecifiedFiles > 0) + CLPReportError(41, parseopts.lastoutputname); + else + CLPReportError(42, parseopts.lastoutputname); + } else { + SetFileOutputName(numfiles - 1, lastStage, parseopts.lastoutputname); + } + + parseopts.lastoutputname[0] = 0; + } + + if (setOutputDirectory) + pCmdLineCompiler.relPathInOutputDir = 0; +} |