|
120 | 120 | //!
|
121 | 121 | //! ## Optional Cargo crate features
|
122 | 122 | //!
|
| 123 | +//! A list of recommended default features follows below. |
| 124 | +//! |
| 125 | +//! ### Feature List |
| 126 | +//! |
123 | 127 | //! - `alloc`: Enable functionality requiring the [`alloc`] crate from
|
124 | 128 | //! the Rust standard library. For example, methods that return a
|
125 | 129 | //! `Vec` rather than filling a statically-sized array. This requires
|
|
130 | 134 | //! allocator. This is a simple allocator that relies on the UEFI pool
|
131 | 135 | //! allocator. You can choose to provide your own allocator instead of
|
132 | 136 | //! using this feature, or no allocator at all if you don't need to
|
133 |
| -//! dynamically allocate any memory. |
| 137 | +//! dynamically allocate any memory. Note that even without that feature, |
| 138 | +//! some code might use the internal UEFI allocator. |
134 | 139 | //! - `logger`: Logging implementation for the standard [`log`] crate
|
135 | 140 | //! that prints output to the UEFI console. No buffering is done; this
|
136 | 141 | //! is not a high-performance logger.
|
| 142 | +//! - `log-debugcon`: Whether the logger set up by `logger` should also log |
| 143 | +//! to the debugcon device (available in QEMU or Cloud Hypervisor on x86). |
137 | 144 | //! - `panic_handler`: Add a default panic handler that logs to `stdout`.
|
138 | 145 | //! - `unstable`: Enable functionality that depends on [unstable
|
139 | 146 | //! features] in the nightly compiler.
|
|
147 | 154 | //! only unfold their potential when you invoke `uefi::helpers::init` as soon
|
148 | 155 | //! as possible in your application.
|
149 | 156 | //!
|
| 157 | +//! ### Recommended Default Features |
| 158 | +//! |
| 159 | +//! In typical use-cases, the following features are useful for you: |
| 160 | +//! - Building a UEFI image: |
| 161 | +//! - Recommended: `alloc`, `global_allocator`, `logger`, `panic_handler` |
| 162 | +//! - Optional: `log-debugcon`, `qemu`, `unstable` |
| 163 | +//! - Building another application/library: |
| 164 | +//! - Recommended: `alloc` |
| 165 | +//! - Optional: `unstable` |
| 166 | +//! |
150 | 167 | //! # Discuss and Contribute
|
151 | 168 | //!
|
152 | 169 | //! For general discussions, feel free to join us in our [Zulip] and ask
|
|
0 commit comments