mirror of
https://github.com/cc65/cc65.git
synced 2025-01-12 17:30:50 +00:00
New long option: --debug
git-svn-id: svn://svn.cc65.org/cc65/trunk@98 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
3065378c20
commit
7bd93e9e82
@ -113,6 +113,7 @@ static void Usage (void)
|
|||||||
"Long options:\n"
|
"Long options:\n"
|
||||||
" --ansi\t\tStrict ANSI mode\n"
|
" --ansi\t\tStrict ANSI mode\n"
|
||||||
" --cpu type\t\tSet cpu type\n"
|
" --cpu type\t\tSet cpu type\n"
|
||||||
|
" --debug\t\tDebug mode\n"
|
||||||
" --debug-info\t\tAdd debug info to object file\n"
|
" --debug-info\t\tAdd debug info to object file\n"
|
||||||
" --help\t\tHelp (this text)\n"
|
" --help\t\tHelp (this text)\n"
|
||||||
" --include-dir dir\tSet an include directory search path\n"
|
" --include-dir dir\tSet an include directory search path\n"
|
||||||
@ -295,6 +296,14 @@ static void OptCPU (const char* Opt, const char* Arg)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
static void OptDebug (const char* Opt, const char* Arg)
|
||||||
|
/* Compiler debug mode */
|
||||||
|
{
|
||||||
|
Debug = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void OptDebugInfo (const char* Opt, const char* Arg)
|
static void OptDebugInfo (const char* Opt, const char* Arg)
|
||||||
/* Add debug info to the object file */
|
/* Add debug info to the object file */
|
||||||
{
|
{
|
||||||
@ -375,6 +384,7 @@ int main (int argc, char* argv[])
|
|||||||
{ "--add-source", 0, OptAddSource },
|
{ "--add-source", 0, OptAddSource },
|
||||||
{ "--ansi", 0, OptAnsi },
|
{ "--ansi", 0, OptAnsi },
|
||||||
{ "--cpu", 1, OptCPU },
|
{ "--cpu", 1, OptCPU },
|
||||||
|
{ "--debug", 0, OptDebug },
|
||||||
{ "--debug-info", 0, OptDebugInfo },
|
{ "--debug-info", 0, OptDebugInfo },
|
||||||
{ "--help", 0, OptHelp },
|
{ "--help", 0, OptHelp },
|
||||||
{ "--include-dir", 1, OptIncludeDir },
|
{ "--include-dir", 1, OptIncludeDir },
|
||||||
@ -410,10 +420,10 @@ int main (int argc, char* argv[])
|
|||||||
|
|
||||||
case '-':
|
case '-':
|
||||||
LongOption (&I, OptTab, sizeof(OptTab)/sizeof(OptTab[0]));
|
LongOption (&I, OptTab, sizeof(OptTab)/sizeof(OptTab[0]));
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'd': /* debug mode */
|
case 'd':
|
||||||
Debug = 1;
|
OptDebug (Arg, 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'h':
|
case 'h':
|
||||||
|
Loading…
x
Reference in New Issue
Block a user