From 23ef4fa172cd21edcc5cf7077f5736ad8be3a82d Mon Sep 17 00:00:00 2001 From: cuz Date: Fri, 8 Oct 2004 09:23:02 +0000 Subject: [PATCH] Added the lynx target git-svn-id: svn://svn.cc65.org/cc65/trunk@3217 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- src/cc65/main.c | 8 ++++++-- src/common/target.c | 5 ++++- src/common/target.h | 1 + src/common/tgttrans.c | 1 + 4 files changed, 12 insertions(+), 3 deletions(-) diff --git a/src/cc65/main.c b/src/cc65/main.c index 63e8e8543..787dec0a4 100644 --- a/src/cc65/main.c +++ b/src/cc65/main.c @@ -229,6 +229,10 @@ static void SetSys (const char* Sys) DefineNumericMacro ("__SUPERVISION__", 1); break; + case TGT_SUPERVISION: + DefineNumericMacro ("__LYNX__", 1); + break; + default: AbEnd ("Unknown target system type %d", Target); } @@ -726,7 +730,7 @@ int main (int argc, char* argv[]) /* Initialize the default segment names */ InitSegNames (); - + /* Initialize the include search paths */ InitIncludePaths (); @@ -807,7 +811,7 @@ int main (int argc, char* argv[]) PreprocessOnly = 1; break; - case 'I': + case 'I': OptIncludeDir (Arg, GetArg (&I, 2)); break; diff --git a/src/common/target.c b/src/common/target.c index b302888e5..d0dfefd67 100644 --- a/src/common/target.c +++ b/src/common/target.c @@ -65,13 +65,14 @@ const char* TargetNames [TGT_COUNT] = { "cbm610", "pet", "bbc", - "apple2", + "apple2", "apple2enh", "geos", "lunix", "atmos", "nes", "supervision", + "lynx" }; @@ -98,6 +99,7 @@ const cpu_t DefaultCPU[TGT_COUNT] = { CPU_6502, /* atmos */ CPU_6502, /* nes */ CPU_65SC02, /* supervision */ + CPU_65C02, /* lynx */ }; @@ -138,3 +140,4 @@ target_t FindTarget (const char* Name) + diff --git a/src/common/target.h b/src/common/target.h index 8c6689625..2243ae088 100644 --- a/src/common/target.h +++ b/src/common/target.h @@ -72,6 +72,7 @@ typedef enum { TGT_ATMOS, TGT_NES, TGT_SUPERVISION, + TGT_LYNX, TGT_COUNT /* Number of target systems */ } target_t; diff --git a/src/common/tgttrans.c b/src/common/tgttrans.c index 423455db4..8c047423d 100644 --- a/src/common/tgttrans.c +++ b/src/common/tgttrans.c @@ -160,6 +160,7 @@ void TgtTranslateInit (void) case TGT_ATMOS: memcpy (Tab, CTNone, sizeof (Tab)); break; case TGT_NES: memcpy (Tab, CTNone, sizeof (Tab)); break; case TGT_SUPERVISION: memcpy (Tab, CTNone, sizeof (Tab)); break; + case TGT_LYNX: memcpy (Tab, CTNone, sizeof (Tab)); break; default: AbEnd ("Internal error: Target system unknown (%d)", Target); } -- 2.39.5