Cargo Features

[dependencies]
c-gull = { version = "0.15.44", default-features = false, features = ["std", "thread", "call-main", "define-mem-functions", "use-compiler-builtins", "log", "atomic-dbg-logger", "env_logger", "max_level_off", "experimental-relocate", "eyra", "take-charge", "coexist-with-libc", "malloc-via-rust-global-alloc", "malloc-via-crates", "threadsafe-setenv", "extra-syscalls", "todo", "deprecated-and-unimplemented"] }
default = coexist-with-libc, std, thread, threadsafe-setenv, use-compiler-builtins

These default features are set whenever c-gull is added without default-features = false somewhere in the dependency tree.

std default

Enables std of c-scape, errno, rustix, and tz-rs

rustix:

This enables use of std. Disabling this enables #![no_std], and requires Rust 1.64 or newer.

thread default

Enables thread of c-scape

call-main

In "take-charge" mode, this enables code in c-scape to define the origin_start function documented here and call a C ABI-compatible extern main function.

Enables call-main of c-scape

define-mem-functions

Should c-scape provide C ABI definitions of memcpy etc. (using compiler_builtins::mem) or should it rely on compiler_builtins being linked in and providing those definitions?

Enables define-mem-functions of c-scape

use-compiler-builtins default

Should c-scape's memcpy etc. use compiler-builtins?

Enables use-compiler-builtins of c-scape

log

Enable logging of program and thread startup and shutdown.

Enables log of c-scape

atomic-dbg-logger

Install atomic_dbg::log as a logger.

Enables atomic-dbg-logger of c-scape

env_logger

Install the env_logger crate as a logger.

Enables env_logger of c-scape

max_level_off

Disable logging.

Enables max_level_off of c-scape

experimental-relocate

Enable highly experimental support for performing startup-time relocations,
needed to support statically-linked PIE executables.

Enables experimental-relocate of c-scape

eyra

A feature that pulls in all the individual features needed to use c-gull to write Rust programs completely implemented in Rust.

Enables eyra of c-scape

take-charge

One of the following two features must be enabled:

Enable this to tell c-gull to take control of the process.

Enables take-charge of c-scape

coexist-with-libc default

Enable this to tell c-gull to let a libc be in control of the process.

Enables coexist-with-libc of c-scape

malloc-via-rust-global-alloc

One of the following two features must be enabled:

Enable this to implement malloc using Rust's global allocator.

Enables malloc-via-rust-global-alloc of c-scape

malloc-via-crates

Enable this to implement malloc using third-party crates, which is useful to do when using the Rust global allocator is using malloc.

Enables malloc-via-crates of c-scape

threadsafe-setenv default

This makes setenv and friends thread-safe by leaking memory.

Enables threadsafe-setenv of c-scape

extra-syscalls

This extends the syscall function with suppport for more syscalls. This is not enabled by default because it increases the code size of syscall by several kibibytes and isn't needed by most Rust programs.

Enables extra-syscalls of c-scape

todo

Enable todo!() stubs for unimplemented functions.

Enables todo of c-scape

deprecated-and-unimplemented

Enable unimplemented!() stubs for deprecated functions.

Enables deprecated-and-unimplemented of c-scape

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

errno std
tz-rs std
rustix std