X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=src%2Fcc65%2Fmain.c;h=3ed7127e3120c9a31d4f8a0b1e6b7e126256e803;hb=b3496bb343a2c93284a8669da4b52cf45b3db3dd;hp=3a548b5cc216955fde6077a44c8b11497c14e05e;hpb=9aa85743ba769c056bc36e8214dc65c15ac5c45a;p=cc65 diff --git a/src/cc65/main.c b/src/cc65/main.c index 3a548b5cc..3ed7127e3 100644 --- a/src/cc65/main.c +++ b/src/cc65/main.c @@ -104,7 +104,7 @@ static void Usage (void) " --check-stack\t\tGenerate stack overflow checks\n" " --code-name seg\tSet the name of the CODE segment\n" " --codesize x\t\tAccept larger code by factor x\n" - " --cpu type\t\tSet cpu type\n" + " --cpu type\t\tSet cpu type (6502, 65c02)\n" " --create-dep\t\tCreate a make dependency file\n" " --data-name seg\tSet the name of the DATA segment\n" " --debug\t\tDebug mode\n" @@ -112,6 +112,7 @@ static void Usage (void) " --debug-opt name\tDebug optimization steps\n" " --disable-opt name\tDisable an optimization step\n" " --enable-opt name\tEnable an optimization step\n" + " --forget-inc-paths\tForget include search paths\n" " --help\t\tHelp (this text)\n" " --include-dir dir\tSet an include directory search path\n" " --list-opt-steps\tList all optimizer steps and exit\n" @@ -382,6 +383,7 @@ static void OptCreateDep (const char* Opt attribute ((unused)), static void OptCPU (const char* Opt, const char* Arg) /* Handle the --cpu option */ { + /* Find the CPU from the given name */ CPU = FindCPU (Arg); if (CPU != CPU_6502 && CPU != CPU_65C02) { AbEnd ("Invalid argument for %s: `%s'", Opt, Arg); @@ -503,6 +505,15 @@ static void OptEnableOpt (const char* Opt attribute ((unused)), const char* Arg) +static void OptForgetIncPaths (const char* Opt attribute ((unused)), + const char* Arg attribute ((unused))) +/* Forget all currently defined include paths */ +{ + ForgetAllIncludePaths (); +} + + + static void OptHelp (const char* Opt attribute ((unused)), const char* Arg attribute ((unused))) /* Print usage information and exit */ @@ -629,7 +640,8 @@ int main (int argc, char* argv[]) { "--debug-info", 0, OptDebugInfo }, { "--debug-opt", 1, OptDebugOpt }, { "--disable-opt", 1, OptDisableOpt }, - { "--enable-opt", 1, OptEnableOpt, }, + { "--enable-opt", 1, OptEnableOpt }, + { "--forget-inc-paths", 0, OptForgetIncPaths }, { "--help", 0, OptHelp }, { "--include-dir", 1, OptIncludeDir }, { "--list-opt-steps", 0, OptListOptSteps },