diff options
| author | 2026-03-19 19:25:41 +0100 | |
|---|---|---|
| committer | 2026-03-19 19:25:41 +0100 | |
| commit | 49ba7f066faa6e73e8f09e2e7ed6a077f6ba0258 (patch) | |
| tree | e3937913113ef201e05a4d95336f03c5ce9b7844 /src/a_main.c | |
| parent | 46fc55e27390ea85eb34ec0367f40426197c9b9f (diff) | |
preeliminary support for openBSD
Diffstat (limited to 'src/a_main.c')
| -rw-r--r-- | src/a_main.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/a_main.c b/src/a_main.c index 3db1f84..6c313a7 100644 --- a/src/a_main.c +++ b/src/a_main.c @@ -120,6 +120,8 @@ static Task task = { .inf = VINIT(infilebuf, countof(infilebuf)) }; static void prihelp(void); +void cpppredef(bool undef, const char *cmd); + static void optparse(char **args) { @@ -229,7 +231,6 @@ optparse(char **args) else if (o == '0') ccopt.o = OPT0; else goto Bad; } else if (*arg == 'D' || *arg == 'U') { - void cpppredef(bool undef, const char *cmd); const char *def = arg[1] ? arg+1 : *++args; if (!def) fatal(NULL, "macro name missing after `-%c`", *arg); cpppredef(*arg == 'U', def); @@ -706,6 +707,9 @@ main(int argc, char **argv) if (!target.arch) fatal(NULL, "unsupported target: %s", task.targ ? task.targ : HOST_TRIPLE); + for (const char *const *p = host_predefs; *p; ++p) + cpppredef(0, *p); + return driver(); } |