| @@ -83,7 +83,7 @@ usage: tcc [options] [@var{infile1} @var{infile2}@dots{}] [@option{-run} @var{in · 82 unmodified lines |
| 83 | | 83 | |
| 84 | @noindent | 84 | @noindent |
| 85 | @c man begin DESCRIPTION | 85 | @c man begin DESCRIPTION |
| 86 | TCC options are a very much like gcc options. The main difference is that TCC | 86 | TCC options are very much like gcc options. The main difference is that TCC |
| 87 | can also execute directly the resulting program and give it runtime | 87 | can also execute directly the resulting program and give it runtime |
| 88 | arguments. | 88 | arguments. |
| 89 | | 89 | |
| @@ -185,6 +185,16 @@ Show included files. As sole argument, print search dirs. -vvv shows tries too · 95 unmodified lines |
| 185 | @item -bench | 185 | @item -bench |
| 186 | Display compilation statistics. | 186 | Display compilation statistics. |
| 187 | | 187 | |
| | 188 | @item -pthread |
| | 189 | Preprocess with @option{-D_REENTRANT}, link with @option{-lpthread}. |
| | 190 | |
| | 191 | @item -On |
| | 192 | Pretend to optimise: set @option{-D__OPTIMIZE__} to the numeric value of n. |
| | 193 | Note that TCC performs no additional optimisation. |
| | 194 | |
| | 195 | @item -dt |
| | 196 | With @option{-run}/@option{-E}: auto-define 'test_...' macros |
| | 197 | |
| 188 | @end table | 198 | @end table |
| 189 | | 199 | |
| 190 | Preprocessor options: | 200 | Preprocessor options: |
| @@ -199,6 +209,16 @@ include paths are: @file{/usr/local/include}, @file{/usr/include} · 8 unmodified lines |
| 199 | and @file{PREFIX/lib/tcc/include}. (@file{PREFIX} is usually | 209 | and @file{PREFIX/lib/tcc/include}. (@file{PREFIX} is usually |
| 200 | @file{/usr} or @file{/usr/local}). | 210 | @file{/usr} or @file{/usr/local}). |
| 201 | | 211 | |
| | 212 | @item -isystem dir |
| | 213 | Specify a system include path to be added to the defaults. |
| | 214 | |
| | 215 | @item -nostdinc |
| | 216 | Do not search the default system include paths; only search include paths |
| | 217 | provided on the command line. |
| | 218 | |
| | 219 | @item -include file |
| | 220 | Include @option{file} above each input file. |
| | 221 | |
| 202 | @item -Dsym[=val] | 222 | @item -Dsym[=val] |
| 203 | Define preprocessor symbol @samp{sym} to | 223 | Define preprocessor symbol @samp{sym} to |
| 204 | val. If val is not present, its value is @samp{1}. Function-like macros can | 224 | val. If val is not present, its value is @samp{1}. Function-like macros can |
| @@ -210,6 +230,18 @@ Undefine preprocessor symbol @samp{sym}. · 5 unmodified lines |
| 210 | @item -E | 230 | @item -E |
| 211 | Preprocess only, to stdout or file (with -o). | 231 | Preprocess only, to stdout or file (with -o). |
| 212 | | 232 | |
| | 233 | @item -P |
| | 234 | Do not output @code{#line} directives. |
| | 235 | |
| | 236 | @item -P1 |
| | 237 | Output alternative @code{#line} directives. |
| | 238 | |
| | 239 | @item -dD, -dM |
| | 240 | Output @code{#define} directives. |
| | 241 | |
| | 242 | @item -Wp,-opt |
| | 243 | Same as @option{-opt}. |
| | 244 | |
| 213 | @end table | 245 | @end table |
| 214 | | 246 | |
| 215 | Compilation flags: | 247 | Compilation flags: |
| @@ -238,6 +270,15 @@ behaves like an unnamed one. · 22 unmodified lines |
| 238 | @item -fdollars-in-identifiers | 270 | @item -fdollars-in-identifiers |
| 239 | Allow dollar signs in identifiers | 271 | Allow dollar signs in identifiers |
| 240 | | 272 | |
| | 273 | @item -freverse-funcargs |
| | 274 | Evaluate function arguments right to left. |
| | 275 | |
| | 276 | @item -fgnu89-inline |
| | 277 | @code{extern inline} is like @code{static inline}. |
| | 278 | |
| | 279 | @item -fasynchronous-unwind-tables |
| | 280 | Create eh_frame section [on] |
| | 281 | |
| 241 | @item -ftest-coverage | 282 | @item -ftest-coverage |
| 242 | Create code coverage code. After running the resulting code an executable.tcov | 283 | Create code coverage code. After running the resulting code an executable.tcov |
| 243 | or sofile.tcov file is generated with code coverage. | 284 | or sofile.tcov file is generated with code coverage. |
| @@ -257,7 +298,10 @@ Note: each of the following warning options has a negative form beginning with · 13 unmodified lines |
| 257 | | 298 | |
| 258 | @table @option | 299 | @table @option |
| 259 | @item -Wimplicit-function-declaration | 300 | @item -Wimplicit-function-declaration |
| 260 | Warn about implicit function declaration. | 301 | Warn about implicit function declaration (missing prototype). |
| | 302 | |
| | 303 | @item -Wdiscarded-qualifiers |
| | 304 | Warn when const is dropped. |
| 261 | | 305 | |
| 262 | @item -Wunsupported | 306 | @item -Wunsupported |
| 263 | Warn about unsupported GCC features that are ignored by TCC. | 307 | Warn about unsupported GCC features that are ignored by TCC. |
| @@ -272,7 +316,8 @@ the specified warning and turn it into an error, for example · 8 unmodified lines |
| 272 | @option{-Werror=unsupported}. | 316 | @option{-Werror=unsupported}. |
| 273 | | 317 | |
| 274 | @item -Wall | 318 | @item -Wall |
| 275 | Activate some useful warnings. | 319 | Activate some useful warnings (@option{-Wimplicit-function-declaration}, |
| | 320 | @option{-Wdiscard-qualifiers}). |
| 276 | | 321 | |
| 277 | @end table | 322 | @end table |
| 278 | | 323 | |
| @@ -288,6 +333,9 @@ Link your program with dynamic library libxxx.so or static library · 9 unmodified lines |
| 288 | libxxx.a. The library is searched in the paths specified by the | 333 | libxxx.a. The library is searched in the paths specified by the |
| 289 | @option{-L} option and @env{LIBRARY_PATH} variable. | 334 | @option{-L} option and @env{LIBRARY_PATH} variable. |
| 290 | | 335 | |
| | 336 | @item -nostdlib |
| | 337 | Don't implicitly link with libc, the C runtime files, and libtcc1. |
| | 338 | |
| 291 | @item -Bdir | 339 | @item -Bdir |
| 292 | Set the path where the tcc internal libraries (and include files) can be | 340 | Set the path where the tcc internal libraries (and include files) can be |
| 293 | found (default is @file{PREFIX/lib/tcc}). | 341 | found (default is @file{PREFIX/lib/tcc}). |
| @@ -376,6 +424,13 @@ Misc options: · 82 unmodified lines |
| 376 | | 424 | |
| 377 | @table @option | 425 | @table @option |
| 378 | | 426 | |
| | 427 | @item -std=version |
| | 428 | Define @code{__STDC_VERSION__}: @code{201112} if @option{version} is c11 or |
| | 429 | gnu11; @code{199901} otherwise. |
| | 430 | |
| | 431 | @item -x[c|a|b|n] |
| | 432 | Specify content of next input file: respectively C, assembly, binary, or none. |
| | 433 | |
| 379 | @item -M | 434 | @item -M |
| 380 | Just output makefile fragment with dependencies | 435 | Just output makefile fragment with dependencies |
| 381 | | 436 | |
| @@ -418,8 +473,7 @@ Pass command line to the i386/x86_64 cross compiler. · 36 unmodified lines |
| 418 | | 473 | |
| 419 | @end table | 474 | @end table |
| 420 | | 475 | |
| 421 | Note: GCC options @option{-Ox}, @option{-fx} and @option{-mx} are | 476 | Note: GCC options @option{-fx} and @option{-mx} are ignored. |
| 422 | ignored. | | |
| 423 | @c man end | 477 | @c man end |
| 424 | | 478 | |
| 425 | @c man begin ENVIRONMENT | 479 | @c man begin ENVIRONMENT |