2000-05-28 13:40:48 +00:00
|
|
|
/*****************************************************************************/
|
|
|
|
/* */
|
2013-05-09 11:56:54 +00:00
|
|
|
/* global.c */
|
2000-05-28 13:40:48 +00:00
|
|
|
/* */
|
2013-05-09 11:56:54 +00:00
|
|
|
/* Global variables for the ca65 macroassembler */
|
2000-05-28 13:40:48 +00:00
|
|
|
/* */
|
|
|
|
/* */
|
|
|
|
/* */
|
2013-01-12 19:07:31 +00:00
|
|
|
/* (C) 1998-2013, Ullrich von Bassewitz */
|
2010-05-01 11:59:55 +00:00
|
|
|
/* Roemerstrasse 52 */
|
|
|
|
/* D-70794 Filderstadt */
|
|
|
|
/* EMail: uz@cc65.org */
|
2000-05-28 13:40:48 +00:00
|
|
|
/* */
|
|
|
|
/* */
|
|
|
|
/* This software is provided 'as-is', without any expressed or implied */
|
|
|
|
/* warranty. In no event will the authors be held liable for any damages */
|
|
|
|
/* arising from the use of this software. */
|
|
|
|
/* */
|
|
|
|
/* Permission is granted to anyone to use this software for any purpose, */
|
|
|
|
/* including commercial applications, and to alter it and redistribute it */
|
|
|
|
/* freely, subject to the following restrictions: */
|
|
|
|
/* */
|
|
|
|
/* 1. The origin of this software must not be misrepresented; you must not */
|
|
|
|
/* claim that you wrote the original software. If you use this software */
|
|
|
|
/* in a product, an acknowledgment in the product documentation would be */
|
|
|
|
/* appreciated but is not required. */
|
|
|
|
/* 2. Altered source versions must be plainly marked as such, and must not */
|
|
|
|
/* be misrepresented as being the original software. */
|
|
|
|
/* 3. This notice may not be removed or altered from any source */
|
|
|
|
/* distribution. */
|
|
|
|
/* */
|
|
|
|
/*****************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
2003-11-23 21:38:54 +00:00
|
|
|
/* common */
|
|
|
|
#include "addrsize.h"
|
|
|
|
|
|
|
|
/* ca65 */
|
2003-11-28 22:12:14 +00:00
|
|
|
#include "global.h"
|
2000-05-28 13:40:48 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*****************************************************************************/
|
2013-05-09 11:56:54 +00:00
|
|
|
/* Data */
|
2000-05-28 13:40:48 +00:00
|
|
|
/*****************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* File names */
|
2013-05-09 11:56:54 +00:00
|
|
|
const char* InFile = 0; /* Name of input file */
|
|
|
|
const char* OutFile = 0; /* Name of output file */
|
2011-02-06 20:10:19 +00:00
|
|
|
StrBuf ListingName = STATIC_STRBUF_INITIALIZER; /* Name of listing file */
|
2010-05-01 11:59:55 +00:00
|
|
|
StrBuf DepName = STATIC_STRBUF_INITIALIZER; /* Dependency file */
|
|
|
|
StrBuf FullDepName = STATIC_STRBUF_INITIALIZER; /* Full dependency file */
|
2000-05-28 13:40:48 +00:00
|
|
|
|
|
|
|
/* Default extensions */
|
2013-05-09 11:56:54 +00:00
|
|
|
const char ObjExt[] = ".o";/* Default object extension */
|
2000-05-28 13:40:48 +00:00
|
|
|
|
2013-05-09 11:56:54 +00:00
|
|
|
char LocalStart = '@'; /* This char starts local symbols */
|
2000-05-28 13:40:48 +00:00
|
|
|
|
2002-02-14 10:05:51 +00:00
|
|
|
unsigned char IgnoreCase = 0; /* Ignore case on identifiers? */
|
|
|
|
unsigned char AutoImport = 0; /* Mark unresolveds as import */
|
2013-05-09 11:56:54 +00:00
|
|
|
unsigned char SmartMode = 0; /* Smart mode */
|
|
|
|
unsigned char DbgSyms = 0; /* Add debug symbols */
|
|
|
|
unsigned char LineCont = 0; /* Allow line continuation */
|
2011-12-27 22:54:52 +00:00
|
|
|
unsigned char LargeAlignment = 0; /* Don't warn about large alignments */
|
2012-08-20 20:07:05 +00:00
|
|
|
unsigned char RelaxChecks = 0; /* Relax a few assembler checks */
|
2019-01-05 19:29:54 +00:00
|
|
|
unsigned char StringEscapes = 0; /* Allow C-style escapes in strings */
|
2023-02-21 03:24:26 +00:00
|
|
|
unsigned char WarningsAsErrors = 0; /* Error if any warnings */
|
2003-11-28 22:12:14 +00:00
|
|
|
|
2008-08-21 19:35:39 +00:00
|
|
|
/* Emulation features */
|
2002-02-14 10:05:51 +00:00
|
|
|
unsigned char DollarIsPC = 0; /* Allow the $ symbol as current PC */
|
|
|
|
unsigned char NoColonLabels = 0; /* Allow labels without a colon */
|
2013-05-09 11:56:54 +00:00
|
|
|
unsigned char LooseStringTerm = 0; /* Allow ' as string terminator */
|
|
|
|
unsigned char LooseCharTerm = 0; /* Allow " for char constants */
|
|
|
|
unsigned char AtInIdents = 0; /* Allow '@' in identifiers */
|
2002-02-14 10:05:51 +00:00
|
|
|
unsigned char DollarInIdents = 0; /* Allow '$' in identifiers */
|
|
|
|
unsigned char LeadingDotInIdents = 0; /* Allow '.' to start an identifier */
|
2013-05-09 11:56:54 +00:00
|
|
|
unsigned char PCAssignment = 0; /* Allow "* = $XXX" or "$ = $XXX" */
|
2004-03-29 15:58:34 +00:00
|
|
|
unsigned char MissingCharTerm = 0; /* Allow lda #'a (no closing term) */
|
2004-04-20 12:49:36 +00:00
|
|
|
unsigned char UbiquitousIdents = 0; /* Allow ubiquitous identifiers */
|
2007-08-23 19:48:43 +00:00
|
|
|
unsigned char OrgPerSeg = 0; /* Make .org local to current seg */
|
2008-08-21 19:35:39 +00:00
|
|
|
unsigned char CComments = 0; /* Allow C like comments */
|
2012-01-18 19:50:34 +00:00
|
|
|
unsigned char ForceRange = 0; /* Force values into expected range */
|
2013-01-12 19:07:31 +00:00
|
|
|
unsigned char UnderlineInNumbers = 0; /* Allow underlines in numbers */
|
2015-04-20 03:21:56 +00:00
|
|
|
unsigned char AddrSize = 0; /* Allow .ADDRSIZE function */
|
2016-02-25 20:40:31 +00:00
|
|
|
unsigned char BracketAsIndirect = 0; /* Use '[]' not '()' for indirection */
|