diff options
Diffstat (limited to 'bcc/bcc.doc')
-rw-r--r-- | bcc/bcc.doc | 177 |
1 files changed, 177 insertions, 0 deletions
diff --git a/bcc/bcc.doc b/bcc/bcc.doc new file mode 100644 index 0000000..1c5e930 --- /dev/null +++ b/bcc/bcc.doc @@ -0,0 +1,177 @@ +bcc options +----------- + +bcc [-03EGOPSVcegv] [-Aas_option] [-Bexecutable_prefix] [-Ccc1_option] + [-Ddefine] [-Iinclude_dir] [-Lld_option] [-Qc386_option] [-Ttmpdir] + [-Uundef] [-o outfile] [-fpt error] [ld_options] [infiles] + +The 6809 version does not support -0, -3 or -G. +Only the c386 version supports -Q. + +defaults (off or none except for these): +-03 native +outfile stdout for preprocessor output + somewhere/file.[ci] -> file.s for compiler output + somewhere/file.[cis] -> file.o for assembler output + a.out for ld output + +-ansi Pass the source through '/usr/bin/unprotoize' first +-0 8086 target (works even on 80386 host) +-3 80386 target (works even on 8086 host) +-A pass remainder of option to assembler (e.g. -A-l -Alistfile for a listing) +-B prefix for executable search path (as usual; the search order is all paths + specified using -B, in order, then the path given in the environment + variable BCC_EXEC_PREFIX if that is set, then the compiled-in defaults + (something like /usr/libexec/i386/bcc/ followed by /usr/bin/)) +-C pass remainder of option to cc1 (e.g. -C-c for caller-saves) +-D define (as usual) +-E produce preprocessor output (as usual) +-G produce gnu-Minix objects (link with gnu ld) +-Ix include search path (as usual) +-I don't add default include to search list +-Lx add dir name x to the head of the list of library dirs searched +-L don't add default library to search list +-X pass remainder of option to linker +-O optimize (does nothing) +-P produce preprocessor output with no line numbers (as usual) +-Q pass full option to c386 +-S produce assembler file (as usual) +-T temporary directory (overrides previous value and default; default is + from the environment variable TMPDIR if that is set, otherwise /tmp) +-U undefine (as usual) +-V print names of files being compiled +-c produce object file (as usual) +-e run the preprocess pass separately. This takes less memory, and may help + or harm by giving more traditional semantics like token pasting with /**/. +-f error (float emulation not supported) +-g produce debugging info (does nothing) +-o output file name follows (assembler, object or executable) (as usual) +-p error (profiling not supported) +-t error (substitution of some cc passes not supported) +-v print names and args of subprocesses being run. Two or more -v's: + print names of files being unlinked. Three or more -v's: + print names of paths being searched. + +Other options are passed to the linker, in particular -i-, -lx, -M, -m, -s. +The -i option is always passed to the linker but can be cancelled using -i-. + +This is supposed to match the V7 manual except for -0, -3, -A, -C, -G, -L, +-T, -V, -e, -v and where not supported. + +cc1 options +---------- + +cc1 [-03EPcdfltw[-]] [-Ddefine] [-Iinclude_dir] [-Uundef] [-o outfile] [infile] + +The 6809 version does not support -0 or -3 but it supports -p. + +defaults (off or none except for these): +-03 native +-c on for 6809 +-f on for 6809 +outfile stdout +infile stdin + +-0 8086 target (works even on 80386 host) +-3 80386 target (works even on 8086 host) +-D define (as usual) +-E produce preprocessor output (as usual) +-I include search path (as usual) +-P produce preprocessor output with no line numbers (as usual) +-c produce code with caller saving regs before function calls +-d print debugging information in assembly output +-f produce code with 1st argument passed in a register +-l produce code for 2 3 1 0 long byte order (only works in 16-bit versions) +-o assembler output file name follows +-p produce (almost) position-independent code +-t print source code in assemby output +-w print what cc1 thinks is the location counter in assembly output + +All the options except -D, -I and -o may be turned off by following the +option letter by a '-'. Options are processed left to right so the last +setting has precedence. + +The following is defined before option processing: + +__BCC__ 1 + +The following may be defined after option processing: + +__AS09__ 1 if 6809 version +__AS386_16__ 1 if -0 option on 80*86 +__AS386_32__ 1 if -3 option on 80*86 +__CALLER_SAVES__ 1 if -c option +__FIRST_ARG_IN_AX__ 1 if -f option on 80*86 +__FIRST_ARG_IN_X__ 1 if -f option on 6809 +__LONG_BIG_ENDIAN__ 1 if -l option +__POS_INDEPENDENT__ 1 if -p option on 6809 + +The following are standard builtins: + +__FILE__ stringized name of current input file +__LINE__ current line number + +as options +---------- + +as [-03agjuw] [-b [bin]] [-lm [list]] [-n name] [-o obj] [-s sym] src + +The 6809 version does not support -0, -3, -a or -j. + +defaults (off or none except for these; no output is produced without a flag): +-03 native +list stdout (beware of clobbering next arg) +name basename of the source name + +-0 start with 16-bit code segment +-3 start with 32-bit code segment +-a enable partial compatibility with asld +-b produce binary file, filename may follow (obsolete) +-g only put global symbols in object file +-j force all jumps to be long +-l produce list file, filename may follow +-m print macro expansions in listing +-n name of module follows (goes in object instead of source name) +-o produce object file, filename follows +-s produce symbol file, filename follows (obsolete) +-u take undefined symbols as imported-with-unspecified segment +-w don't print warnings + +The -u and -w options are perhaps back to front because they are needed for +cc1 output and Minix's make does the wrong thing with .s files left around. +However, all assembler code not written by compilers should assemble with +them turned off. + +ld options +---------- + +ld [-03Mimrstz[-]] [-llib_extension] [-o outfile] [-Ccrtfile] + [-Llibdir] [-Olibfile] [-T textaddr] infile... + +The version that produces old Minix a.out format does not support -r. + +The 6809 version does not support -i or -r. + +defaults (off or none except for these): +-03 native +-L/usr/local/lib/m/ (m is machine-dependent) +outfile a.out + +-0 produce header with 16-bit magic and use library subdir i86 for -lx +-3 produce header with 32-bit magic and use library subdir i386 for -lx +-Cx add file libdir-from-search/crtx.o to list of files linked +-Lx add dir name x to the head of the list of library dirs searched +-M print symbols linked on stdout +-Ox add library libdir-from-search/x to list of files linked +-T text base address follows (in format suitable for strtoul) +-i separate I&D output +-lx add library libdir-from-search/libx.a to list of files linked +-m print modules linked on stdout +-o output file name follows +-r produce output suitable for further relocation +-s strip symbols +-t trace modules being looked at on stdout +-z produce "unmapped zero page" executables + +All the options not taking an argument may be turned off by following the +option letter by a '-', as for cc1. |