Files
kumomta/crates/mod-filesystem
Wez Furlong bcd0e3746c lruttl: add predefined cache registry
This commit adds a declare_cache! macro that serves a couple of
purposes:

* Make it slightly less boilerplatey to define a cache
* Register them explicitly as a list of predefined caches, so that
  we can raise an error if lua code would conflict via memoize
* Enable a future change that allows reconfiguring the cache parameters
  for those predefined caches

Note: if you are using clang as a linker via RUSTFLAGS/.make-env,
the linkme crate that is employed for the registry may result
in linker errors. The solution that I have in my `.make-env` is
to add `-Clink-arg=-Wl,-z,nostart-stop-gc` to RUSTFLAGS so that
its sections are not removed too soon in the build process:

```
; cat .make-env
ROCKSDB_LIB_DIR=/usr/lib/x86_64-linux-gnu
RUSTFLAGS=-C linker=clang -C link-arg=-fuse-ld=lld --cfg tokio_unstable -Clink-arg=-Wl,-z,nostart-stop-gc
```
2025-03-05 07:54:21 -07:00
..
2025-03-05 07:54:21 -07:00