If a feature is genuinely experimental, keep it in a separate branch.
Otherwise, it will be compiled in, as there may be a user. This becomes inevitable in larger systems: in particular, c-lightning uses both libsecp and libwally. The latter includes libsecp, and you can’t have two libraries with the same symbols, so c-lightning needs to use the libwally one. Packaging systems fix this, but they have the same problem: they must configure in everything.
You can have boutique builds that omit features for embedded use, sure. But the default will be kitchen sink.
I know it’s hard: labelling something experimental is a good way of avoiding commitment. But it is a mere fig leaf which doesn’t work, and mature libraries don’t get that luxury.
If you’re not prepared to commit to an API (ideally an ABI too), you simply cannot include something. In that case, it needs to be a separate library (and if it gets folded in later, all the names have to change!).