dostrip -x functions as a way to exclude individual files from stripping, but unlike the various QA_* variables it does not support directories/wildcards. For example, many npm packages ship ridiculous prebuilt toolchains. These can be excluded from many QA checks (though not all) by adding them to QA_PREBUILT: QA_PREBUILT=".../node_modules/*" But this doesn't work for the "dostrip" command. Tried both: dostrip -x "node_modules" and dostrip -x "node_modules/*" Neither works unfortunately. Only solution is to RESTRICT=strip the whole package. Even worse, from what I am reading this functionality actually used to be available via STRIP_MASK, but this was removed in EAPI 7? Please restore the ability to recursively/wildcard exclude specific directories from stripping, without disabling stripping for the whole package. Reproducible: Always
Directories do work, but you need the full path from ${ED} e.g. dostrip -x /usr/lib/dont-strip-anything-here
Okay thank you, that does work. However it is very nonintuitive from the wording on the Install Functions reference page: dostrip Introduced with EAPI=7, controls the stripping of executables. Normally executed to exclude from stripping. Eg. dostrip -x /path/to/important.so. May also be used to include binaries to strip when RESTRICT=strip without the -x option. Compare this to the documentation for dosym: dosym Create a symlink to the target specified as the first parameter, at the path specified by the second parameter. Note that the target is interpreted verbatim; it needs to either specify a relative path or an absolute path including ${EPREFIX}. Additionally, there is no reference at all to this function in ebuild(5). Would a PR to update the documentation be accepted?