Cargo Features

memflow = { version = "0.2.0-beta9", default-features = false, features = ["std", "dummy_mem", "serde_derive", "memmapfiles", "plugins", "filemap", "64_bit_mem", "os_helpers", "128_bit_mem"] }
default = 64_bit_mem, filemap, memmapfiles, os_helpers, plugins, serde_derive, std

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

std default = coarsetime

Enables std of cglue and no-std-compat

Affects connector::fileio, memory_view::cursor, memory_view::MemoryView.cursor, memory_view::MemoryView.into_cursor, memory_view::MemoryView.cursor_at, memory_view::MemoryView.into_cursor_at, cache::timed_validator, cache::DefaultCacheValidator

dummy_mem = rand, rand_xorshift
serde_derive default memmapfiles = serde

Enables serde of cglue

memmapfiles default = serde_derive, toml
plugins default = abi_stable, dirs, goblin, libloading, once_cell, os_helpers

Enables layout_checks of cglue, std of log

Affects memflow::plugins

filemap default = memmap

Affects connector::filemap

64_bit_mem default

Affects address::umem, address::imem

os_helpers default plugins = goblin, pelite

use 128 bit addressing.
If 64_bit_mem is also enabled, 64-bit mode takes precedence.
This is because 128-bit mode is not necessary to date, and u128 is not FFI-safe.

Affects address::umem, address::imem

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features.

coarsetime std
rand dummy_mem?

With default features

rand_xorshift dummy_mem?
memmap filemap
libloading plugins

Enables libloading ^0.7.2


dirs plugins

Enables dirs ^4.0.0

pelite os_helpers

Enables unsafe_alignment of pelite =0.9.0

enable unsafe_alignment for now, this is UB, but the idea is to fix pelite in upstream

abi_stable plugins

Enables default features of abi_stable ^0.10.3

Affects memflow::abi_stable

once_cell plugins

With default (std)

goblin os_helpers plugins

Enables pe32, pe64, elf32, elf64, mach32, mach64 and default features of goblin ^0.5.1

serde serde_derive

With derive and alloc

toml memmapfiles

Enables toml ^0.5.8