Replace HB_DEPEND_API with HB_NO_SUBSET_DEPEND gated on HB_EXPERIMENTAL_API and HB_LEAN in hb-config.hh, with HB_SUBSET_DEPEND_API opt-in to allow enabling without full experimental API. Remove depend_api meson option; depend tests now build under experimental_api=true. Fold depend symbols into experimental symbols in gen-def.py. Internal fixes: use free_set_list.pop(), push_or_fail() for allocation safety, return const hb_set_t* from internal get_set_from_index. Ligature.hh: use hb_sink iterator, rename ligset→ligset_idx, source→gid. Remove stale test_depend_cmap unit test (cmap extraction was removed in d4d4c635). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Security Fuzzers
To build the fuzzers with libFuzzer to perform actual fuzzing, build with:
CXX=clang++ CXXFLAGS="-fsanitize=address,fuzzer-no-link" meson fuzzbuild --default-library=static -Dfuzzer_ldflags="-fsanitize=address,fuzzer"
ninja -Cfuzzbuild
Then, run the fuzzer like this:
fuzzbuild/test/fuzzing/hb-{shape,raster,vector,subset,repacker,depend}-fuzzer [-max_len=2048] [CORPUS_DIR]
Where max_len specifies the maximal length of font files to handle. The smaller the faster.
Note: The depend fuzzer requires -Ddepend_api=true meson option.
For more details consult the following locations:
Depend Closure Parity Test
The hb-depend-closure-parity test is distinct from the security fuzzers.
While security fuzzers test robustness against malformed input, the closure
parity test validates correctness by emulating the glyph closure calculation
used for subsetting with one generated from the dependency graph to avoid
implementation divergence. It should only be run on valid fonts.