You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
Go to file
Stephen Heumann 137188ff4f Comment out an obsolete error message. 4 days ago
ORCACDefs Add constants in tool headers for System 6.0.1 functionality. 2 months ago
Tests Add tests for <time.h> functions. 2 months ago
obj ORCA/C 2.1.0 source from the Opus ][ CD 6 years ago
Asm.pas Count variables referenced in assembly code as used. 3 months ago
C.Update.ReadMe Update ORCA/C version number to 2.2.0 B6. 8 months ago
CC.pas Add lint option to check for unused variables. 3 months ago
CC.rez Add lint check for implicit conversions that change a constant's value. 3 months ago
CC.rez2 Change all text/source files to LF line endings. 5 years ago
CCommon.asm Use an improved hash function for symbol tables. 2 weeks ago
CCommon.macros Change all text/source files to LF line endings. 5 years ago
CCommon.pas Add lint check for implicit conversions that change a constant's value. 3 months ago
CGC.asm Increase some size limits. 9 months ago
CGC.macros Process floating-point values within the compiler using the extended type. 2 years ago
CGC.pas Add a new optimize flag for FP math optimizations that break IEEE rules. 1 year ago
CGI.Comments Add debugging option to detect illegal use of null pointers. 1 month ago
CGI.Debug Add debugging option to detect illegal use of null pointers. 1 month ago
CGI.pas Give an error if assembly code tries to use direct page addressing for a local variable that is out of range. 2 weeks ago
Charset.pas Support UTF-8/16/32 string literals and character constants (C11). 1 year ago
DAG.pas Add debugging option to detect illegal use of null pointers. 1 month ago
DAG2.pas Change all text/source files to LF line endings. 5 years ago
Debugger.md Update the debugging format for long long values. 2 years ago
Exp.macros Evaluate arithmetic and shifts in long long constant expressions. 2 years ago
Expression.asm Evaluate 64-bit comparisons in constant expressions. 2 years ago
Expression.pas Prevent a tag declared in an inner scope from shadowing a typedef. 2 weeks ago
Gen.pas Generate more efficient code for certain conditionals. 6 days ago
Header.pas Use an improved hash function for symbol tables. 2 weeks ago
Header2.pas Change all text/source files to LF line endings. 5 years ago
LICENSE ORCA/C 2.1.0 source from the Opus ][ CD 6 years ago
MM.asm Move some more code out of the blank segment to make space for static data. 5 years ago
MM.macros Change all text/source files to LF line endings. 5 years ago
MM.pas Move memory allocation code to a new function in MM. 4 months ago
Native.asm Avoid out-of-range branches around asm code using dcl directives. 5 months ago
Native.macros Change all text/source files to LF line endings. 5 years ago
Native.pas Generate more efficient code for certain conditionals. 6 days ago
Native2.pas Change all text/source files to LF line endings. 5 years ago
ObjOut.asm Make the object buffer dynamically resizable. 3 months ago
ObjOut.macros Expand the size of the object buffer from 64K to 128K, and use 32-bit values to track related sizes. 5 years ago
ObjOut.pas Never make the segment in the root file dynamic. 3 months ago
ObjOut2.asm Expand all tabs in assembly files to spaces. 5 years ago
ObjOut2.pas Change all text/source files to LF line endings. 5 years ago
Parser.pas Do not inhibit sym file generation if there is a segment directive before an #include. 2 weeks ago
Printf.pas Do not print "\000" at end of printf/scanf format strings. 5 months ago
README.md Add link to binary downloads in the readme shown on GitHub. 5 years ago
Scanner.asm Do not give an error for files that end with an #endif with no newline. 6 days ago
Scanner.debug Change all text/source files to LF line endings. 5 years ago
Scanner.macros Allow line continuations within // comments. 4 months ago
Scanner.pas Comment out an obsolete error message. 4 days ago
Symbol.Print Record volatile and restrict qualifiers in types. 2 years ago
Symbol.asm Maintain a pool of empty symbol tables that can be reused. 3 months ago
Symbol.macros Change all text/source files to LF line endings. 5 years ago
Symbol.pas Remove unneeded extern declarations. 4 days ago
Table.asm Treat unary + as an actual operator, not a no-op. 3 months ago
Table.macros Recognize the new keywords from C99 and C11 as such. 3 years ago
Table.pas Add a command-line option to select the C standard to use. 3 months ago
backup Change all text/source files to LF line endings. 5 years ago
cc.notes Avoid listing the first line twice when a pre-include file is used. 5 days ago
count Change all text/source files to LF line endings. 5 years ago
linkit Add initial support for universal character names. 3 years ago
linkit2 Change all text/source files to LF line endings. 5 years ago
make Add initial support for universal character names. 3 years ago
make2 Change all text/source files to LF line endings. 5 years ago
settypes Add settypes script for setting file types, and update README to refer to it. 5 years ago
smake Change all text/source files to LF line endings. 5 years ago

README.md

ORCA-C

Apple IIGS ORCA/C Compiler, an ANSI C compiler for the 65816 with libraries for the Apple IIGS

Binary downloads for the latest ORCA/C release are on the releases page.

If you would like to make changes to this compiler and distribute them to others, feel free to submit them here. If the changes apply to compilation on and for an Apple IIGS, they will generally be approved for distribution on the master branch unless the changes deviate significantly from the ANSI C standard. For changes that deviate form ANSI C or changes that retarget the compiler to run on a different platform or generate code for a different platform, the project will either be forked or a new repository will be created, as appropriate.

The general conditions that must be met before a change is released on master are:

  1. The modified compiler must compile under the currently released version of ORCA/M and ORCA/Pascal.

  2. All samples from the original ORCA/C distribution must compile and execute under the modified compiler, or the sample must be updated, too.

  3. The compiler must pass the ORCA/C tset suite, or the test suite must be suitably modified, too.

  4. The compiler must work with the current ORCA/C libraries, or the libraries must be modified, too.

Contact support@byteworks.us if you need contributor access.

A complete distribution of the ORCA languages, including installers and documentation, is available from the Juiced GS store at https://juiced.gs/store/category/software/. It is distributed as part of the Opus ][ package.

Line Endings and File Types

The text and source files in this repository originally used CR line endings, as usual for Apple II text files, but they have been converted to use LF line endings because that is the format expected by Git. If you wish to move them to a real or emulated Apple II and build them there, you will need to convert them back to CR line endings.

If you wish, you can configure Git to perform line ending conversions as files are checked in and out of the Git repository. With this configuration, the files in your local working copy will contain CR line endings suitable for use on an Apple II. To set this up, perform the following steps in your local copy of the Git repository (these should be done when your working copy has no uncommitted changes):

  1. Add the following lines at the end of the .git/config file:
[filter "crtext"]
	clean = LC_CTYPE=C tr \\\\r \\\\n
	smudge = LC_CTYPE=C tr \\\\n \\\\r
  1. Add the following line to the .git/info/attributes file, creating it if necessary:
* filter=crtext
  1. Run the following commands to convert the existing files in your working copy:
rm .git/index
git checkout HEAD -- .

Alternatively, you can keep the LF line endings in your working copy of the Git repository, but convert them when you copy the files to an Apple II. There are various tools to do this. One option is udl, which is available both as a IIGS shell utility and as C code that can be built and used on modern systems.

In addition to converting the line endings, you will also have to set the files to the appropriate file types before building ORCA/C on a IIGS. The included settypes script (for use under the ORCA shell) does this for the sources to the ORCA/C compiler itself, although it does not currently cover the test cases and headers.