forked from OpenCobolIDE/GnuCOBOL-Win32-MinGW
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcobc-help.txt
193 lines (186 loc) · 10.6 KB
/
cobc-help.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
GnuCOBOL compiler for most COBOL dialects with lots of extensions
Usage: cobc [options]... file...
Options:
-h, -help display this help and exit
-V, -version display compiler version and exit
-i, -info display compiler information (build/environment)
-v, -verbose display the commands invoked by the compiler
-vv display compiler version and the commands
invoked by the compiler
-q, -brief reduced displays, commands invoked not shown
-x build an executable program
-m build a dynamically loadable module (default)
-j [<args>], -job[=<args>] run program after build, passing <args>
-std=<dialect> warnings/features for a specific dialect
<dialect> can be one of:
cobol2014, cobol2002, cobol85, default,
ibm, mvs, bs2000, mf, acu;
see configuration files in directory config
-F, -free use free source format
-fixed use fixed source format (default)
-O, -O2, -Os enable optimization
-g enable C compiler debug / stack check / trace
-d, -debug enable all run-time error checking
-o <file> place the output into <file>
-b combine all input files into a single
dynamically loadable module
-E preprocess only; do not compile or link
-C translation only; convert COBOL to C
-S compile only; output assembly file
-c compile and assemble, but do not link
-T <file> generate and place a wide program listing into <file>
-t <file> generate and place a program listing into <file>
--tlines=<lines> specify lines per page in listing, default = 55
--no-symbols specify no symbols in listing
-P[=<dir or file>] generate preprocessed program listing (.lst)
-Xref generate cross reference through 'cobxref'
(V. Coen's 'cobxref' must be in path)
-I <directory> add <directory> to copy/include search path
-L <directory> add <directory> to library search path
-l <lib> link the library <lib>
-A <options> add <options> to the C compile phase
-Q <options> add <options> to the C link phase
-D <define> define <define> for COBOL compilation
-K <entry> generate CALL to <entry> as static
-conf=<file> user-defined dialect configuration; see -std
-list-reserved display reserved words
-list-intrinsics display intrinsic functions
-list-mnemonics display mnemonic names
-list-system display system routines
-save-temps[=<dir>] save intermediate files
- default: current directory
-ext <extension> add file extension for resolving COPY
-W enable all warnings
-Wall enable most warnings (all except as noted below)
-Wno-<warning> disable warning enabled by -W or -Wall
-Wno-unfinished don't warn if unfinished features are used
- ALWAYS active
-Wobsolete warn if obsolete features are used
-Warchaic warn if archaic features are used
-Wredefinition warn incompatible redefinition of data items
-Wconstant warn inconsistent constant
-Woverlap warn overlapping MOVE items
-Wpossible-overlap warn MOVE items that may overlap depending on variables
- NOT set with -Wall
-Wparentheses warn lack of parentheses around AND within OR
-Wstrict-typing warn type mismatch strictly
-Wimplicit-define warn implicitly defined data items
-Wcorresponding warn CORRESPONDING with no matching items
-Wexternal-value warn EXTERNAL item with VALUE clause
-Wprototypes warn missing FUNCTION prototypes/definitions
-Wcall-params warn non 01/77 items for CALL params
- NOT set with -Wall
-Wcolumn-overflow warn text after program-text area, FIXED format
- NOT set with -Wall
-Wterminator warn lack of scope terminator END-XXX
- NOT set with -Wall
-Wtruncate warn possible field truncation
- NOT set with -Wall
-Wlinkage warn dangling LINKAGE items
- NOT set with -Wall
-Wunreachable warn unreachable statements
- NOT set with -Wall
-fsign=[ASCII|EBCDIC] define display sign representation
- default: machine native
-ffold-copy=[UPPER|LOWER] fold COPY subject to value
- default: no transformation
-ffold-call=[UPPER|LOWER] fold PROGRAM-ID, CALL, CANCEL subject to value
- default: no transformation
-fdefaultbyte=0..255 initialize fields without VALUE to decimal value
- default: initialize to picture
-fintrinsics=[ALL|intrinsic function name(,name,...)] intrinsics to be used without FUNCTION keyword
-ftrace generate trace code
- executed SECTION/PARAGRAPH
-ftraceall generate trace code
- executed SECTION/PARAGRAPH/STATEMENTS
- turned on by -debug
-fsyntax-only syntax error checking only; don't emit any output
-fdebugging-line enable debugging lines
- 'D' in indicator column or floating >>D
-fsource-location generate source location code
- turned on by -debug/-g/-ftraceall
-fimplicit-init automatic initialization of the COBOL runtime system
-fstack-check PERFORM stack checking
- turned on by -debug or -g
-fsyntax-extension allow syntax extensions
- e.g. switch name SW1, etc.
-fwrite-after use AFTER 1 for WRITE of LINE SEQUENTIAL
- default: BEFORE 1
-fmfcomment '*' or '/' in column 1 treated as comment
- FIXED format only
-facucomment '$' in indicator area treated as '*',
'|' treated as floating comment
-fnotrunc allow numeric field overflow
- non-ANSI behaviour
-fodoslide adjust items following OCCURS DEPENDING
- requires implicit/explicit relaxed syntax
-fsingle-quote use a single quote (apostrophe) for QUOTE
- default: double quote
-frecursive-check check recursive program call
-foptional-file treat all files as OPTIONAL
- unless NOT OPTIONAL specified
-ftab-width=1..12 set number of spaces that are asumed for tabs
-ftext-column=72..255 set right margin for source (fixed format only)
-fpic-length=<number> maximum number of characters allowed in the character-string
-fword-length=1..61 maximum word-length for COBOL words / Programmer defined words
-fliteral-length=<number> maximum literal size in general
-fnumeric-literal-length=1..38 maximum numeric literal size
-fassign-clause=<value> set way of interpreting ASSIGN
-fbinary-size=<value> binary byte size - defines the allocated bytes according to PIC
-fbinary-byteorder=<value> binary byte order
-ffilename-mapping resolve file names at run time using environment variables.
-fpretty-display alternate formatting of numeric fields
-fbinary-truncate numeric truncation according to ANSI
-fcomplex-odo allow complex OCCURS DEPENDING ON
-findirect-redefines allow REDEFINES to other than last equal level number
-flarger-redefines-ok allow larger REDEFINES items
-frelax-syntax-checks allow certain syntax variations (e.g. REDEFINES position)
-fperform-osvs exit point of any currently executing perform is recognized if reached
-fsticky-linkage linkage-section items remain allocated between invocations
-frelax-level-hierarchy allow non-matching level numbers
-fhostsign allow hexadecimal value 'F' for NUMERIC test of signed PACKED DECIMAL field
-faccept-update set WITH UPDATE clause as default for ACCEPT dest-item, instead of WITH NO UPDATE
-faccept-auto set WITH AUTO clause as default for ACCEPT dest-item, instead of WITH TAB
-fconsole-is-crt assume CONSOLE IS CRT if not set otherwise
-fprogram-name-redefinition program names don't lead to a reserved identifier
-fno-echo-means-secure NO-ECHO hides input with asterisks like SECURE
-fcomment-paragraphs=<support> comment paragraphs in IDENTIFICATION DIVISION (AUTHOR, DATE-WRITTEN, ...)
-fmemory-size-clause=<support> MEMORY-SIZE clause
-fmultiple-file-tape-clause=<support> MULTIPLE-FILE-TAPE clause
-flabel-records-clause=<support> LABEL-RECORDS clause
-fvalue-of-clause=<support> VALUE-OF clause
-fdata-records-clause=<support> DATA-RECORDS clause
-ftop-level-occurs-clause=<support> OCCURS clause on top-level
-fsynchronized-clause=<support> SYNCHRONIZED clause
-fgoto-statement-without-name=<support> GOTO statement without name
-fstop-literal-statement=<support> STOP-LITERAL statement
-fdebugging-line=<support> DEBUGGING MODE and indicator 'D'
-fpadding-character-clause=<support> PADDING CHARACTER clause
-fnext-sentence-phrase=<support> NEXT SENTENCE phrase
-feject-statement=<support> EJECT statement
-fentry-statement=<support> ENTRY statement
-fmove-noninteger-to-alphanumeric=<support> move noninteger to alphanumeric
-fodo-without-to=<support> OCCURS DEPENDING ON without to
-fsection-segments=<support> section segments
-falter-statement=<support> ALTER statement
-fcall-overflow=<support> OVERFLOW clause for CALL
-fnumeric-boolean=<support> boolean literals (B'1010')
-fhexadecimal-boolean=<support> hexadecimal-boolean literals (BX'A')
-fnational-literals=<support> national literals (N'UTF-16 string')
-fhexadecimal-national-literals=<support> hexadecimal-national literals (NX'265E')
-facucobol-literals=<support> ACUCOBOL-GT literals (#B #O #H #X)
-fword-continuation=<support> continuation of COBOL words
-fnot-exception-before-exception=<support> NOT ON EXCEPTION before ON EXCEPTION
-faccept-display-extensions=<support> extensions to ACCEPT and DISPLAY
-frenames-uncommon-levels=<support> RENAMES of 01-, 66- and 77-level items
-fprogram-prototypes=<support> CALL/CANCEL with program-prototype-name
-freference-out-of-declaratives=<support> references to sections not in DECLARATIVES from within DECLARATIVES
where <support> is one of the following:
'ok', 'warning', 'archaic', 'obsolete', 'skip', 'ignore', 'error', 'unconformable'
-fnot-reserved=<word> word to be taken out of the reserved words list
-freserved=<word> word to be added to reserved words list
-freserved=<word>:<alias> word to be added to reserved words list as alias
Report bugs to: [email protected]
or (preferably) use the issue tracker via the home page.
GnuCOBOL home page: <http://www.gnu.org/software/gnucobol/>
General help using GNU software: <http://www.gnu.org/gethelp/>