CSC(1)

NAME
csc - driver program for the CHICKEN Scheme compiler

SYNOPSIS
csc [OPTION ...] [FILENAME ...]

DESCRIPTION
csc is a program that invokes the CHICKEN compiler and the host systems C compiler to generate an executable from a Scheme source file or C files generated by CHICKEN.

FILENAME is a Scheme source file name with optional extension or a C/C++/Objective-C source, object or library file name with extension. OPTION may be one of the following:

General options:

-h, -help
    Display usage text and exit.

-v, -verbose
    Show compiler notes and tool-invocations.

-vv Display information about translation progress.

-vvv
    Display information about all compilation stages.

-version
    Display Scheme compiler version and exit.

-release
    Display release number and exit.

File and pathname options:

-o FILENAME, -output-file FILENAME
    Specifies target executable name.

-I PATHNAME, -include-path PATHNAME
    Specifies alternative path for included files.

-to-stdout
    Write compiler to stdout (implies -t).

-s, -shared, -dynamic
    Generate dynamically loadable shared object file.

Language options:

-D SYMBOL, -feature SYMBOL
    Register feature identifier.

-no-feature SYMBOL
    Disable builtin feature identifier.

-c++
    Compile via a C++ source file (.cpp).

-objc
    Compile via Objective-C source file (.m).

Syntax related options:

-i, -case-insensitive
    Don't preserve case of read symbols.

-K, -keyword-style STYLE
    Enable alternative keyword-syntax (prefix, suffix or none).

-no-parentheses-synonyms
    Disables list delimiter synonyms.

-no-symbol-escape
    Disables support for escaped symbols.

-r7rs-syntax
    Disables the CHICKEN extensions to R7RS syntax.

-compile-syntax
    Macros are made available at run-time.

-j MODULE, -emit-import-library MODULE
    Write compile-time module information into separate file.

-J, -emit-all-import-libraries
    Emit import-libraries for all defined modules.

-no-compiler-syntax
    Disable expansion of compiler-macros.

-m NAME, -module NAME
    Wrap compiled code in module of the given name.

-M, -module-registration
    Always generate module registration code, even when import libraries are emitted.

-N, -no-module-registration
    Do not generate module registration code. Overrides -module-registration.

Translation options:

-x, -explicit-use
    Do not use units ‘library’ and ‘eval’ by default.

-P, -check-syntax
    Stop compilation after macro-expansion.

-A, -analyze-only
    Stop compilation after first analysis pass.

Debugging options:

-w, -no-warnings
    Disable warnings.

-d0, -d1, -d2, -d3, -debug-level NUMBER
    Set level of available debugging information.

-no-trace
    Disable rudimentary debugging information.

-profile
    Executable emits profiling information.

-accumulate-profile
    Executable emits profiling information in append mode.

-profile-name FILENAME
    Name of the generated profile information file.

-types FILENAME
    Load additional type database.

Optimization options:

-O, -O0, -O1, -O2, -O3, -O4, -O5, -optimize-level NUMBER
    Enable certain sets of optimization options.

-optimize-leaf-routines
    Enable leaf routine optimization.

-no-usual-integrations
    Standard procedures may be redefined.

-u, -unsafe
    Disable safety checks.

-local
    Assume globals are only modified in current file.

-b, -block
    Enable block-compilation.

-disable-interrupts
    Disable interrupts in compiled code.

-f, -fixnum-arithmetic
    Assume all numbers are fixnums.

-disable-stack-overflow-checks
    Disables detection of stack-overflows.

-inline
    Enable inlining.

-inline-limit LIMIT
    Set inlining threshold.

-inline-global
    Enable cross-module inlining.

-specialize
    Perform type-based specialization of primitive calls.

-oi FILENAME, -emit-inline-file FILENAME
    Generate file with globally inlinable procedures (implies -inline -local).

-consult-inline-file FILENAME
    Explicitly load inline file.

-ot FILENAME, -emit-types-file FILENAME
    Write type-declaration information into file.

-no-argc-checks
    Disable argument count checks.

-no-bound-checks
    Disable bound variable checks.

-no-procedure-checks
    Disable procedure call checks.

-no-procedure-checks-for-usual-bindings
    Disable procedure call checks only for usual bindings.

-no-procedure-checks-for-toplevel-bindings
    Disable procedure call checks for toplevel bindings.

-strict-types
    Assume variable do not change their type.

-lfa2
    Perform additional lightweight flow-analysis pass.

-unroll-limit LIMIT
    Specifies inlining limit for self-recursive calls.

-merge-reusable-closures
    Enables closure reuse.

-merge-shareable-closures
    Enables closure sharing.

Configuration options:

-unit NAME
    Compile file as a library unit.

-uses NAME
    Declare library unit as used.

-heap-size NUMBER
    Specifies heap-size of compiled executable.

-nursery NUMBER -stack-size NUMBER
    Specifies nursery size of compiled executable.

-X FILENAME, -extend FILENAME
    Load file before compilation commences.

-prelude EXPRESSION
    Add expression to beginning of source file.

-postlude EXPRESSION
    Add expression to end of source file.

-prologue FILENAME
    Include file before main source file.

-epilogue FILENAME
    Include file after main source file.

-e, -embedded
    Compile as embedded (don't generate ‘main()’).

-gui
    Compile as GUI application.

-link NAME
    Link extension with compiled executable (implies ‘-uses’).

-R NAME, -require-extension NAME
    Require extension and import in compiled code.

-dll, -library
    Compile multiple units into a dynamic library.

-libdir DIRECTORY
    Override location of runtime library directory.

Options to other passes:

-C OPTION
    Pass option to C compiler.

-L OPTION
    Pass option to linker.

-I<DIR>
    Pass “-I<DIR>” to C compiler (add include path).

-L<DIR>
    Pass “-L<DIR>” to linker (add library path).

-k  Keep intermediate files.

-c  Stop after compilation to object files.

-t  Stop after translation to C.

-cc COMPILER
    Select a C compiler other than the default.

-cxx COMPILER
    Select a C++ compiler other than the default.

-ld COMPILER
    Select a linker other than the default.

-static
    Link with static CHICKEN libraries and extensions.

-F<DIR>
    Pass “-F<DIR>” to C compiler (add framework header path on Mac OS X).

-framework NAME
    Passed to linker on Mac OS X.

-rpath PATHNAME
    Add directory to runtime library search path.

-Wl,...
    Pass linker options.

-strip
    Strip resulting binary.

Inquiry options:

-home
    Show home-directory (where support files go).

-cflags
    Show required C-compiler flags and exit.

-ldflags
    Show required linker flags and exit.

-libs
    Show required libraries and exit.

-cc-name
    Show name of default C compiler used.

-cxx-name
    Show name of default C++ compiler used.

-ld-name
    Show name of default linker used.

-dry-run
    Just show commands executed, don't run them (implies ‘-v’).

Obscure options:

-debug MODES
    Display debugging output for the given modes.

-compiler PATHNAME
    Use a compiler other than the default ‘chicken’.

-raw
    Do not generate implicit init- and exit code.

-emit-external-prototypes-first
    Emit prototypes for callbacks before foreign declarations.

-regenerate-import-libraries
    Always emit import libraries, even when their contents haven't changed. The default behaviour is to preserve existing import libraries.

-ignore-repository
    Do not refer to repository for extensions.

-keep-shadowed-macros
    Do not remove shadowed macros.

-host
    Compile for host when configured for cross-compiling.

-private-repository
    Load extensions from executable path.

-deployed
    Link support file to be used from a deployed executable (sets ‘rpath’ accordingly, if supported on this platform.)

-no-elevation
    Embed manifest on Windows to supress elevation warnings for programs named ‘install’ or ‘setup’.

Options can be collapsed if unambiguous, so “-vkfO” is the same as “-v -k -fixnum-arithmetic -optimize”.

ENVIRONMENT
The following environment variables change the behaviour of csc:

CSC_OPTIONS
    Can hold default options that should be passed to every invocation of csc.

EXIT STATUS

SEE ALSO
chicken(1)

More information can be found in the CHICKEN User's Manual: http://wiki.call-cc.org/manual/index.

AUTHORS
The CHICKEN Team

BUGS
Submit bug reports by e-mail to chicken-janitors@nongnu.org