RTD apparently tries to use the Ubuntu libclang.so even though the libclang Python package provides its own copy. A docs build on vanilla Ubuntu 22.04 doesn't, and it's not clear why. Since pinning to an older clang Python package is known to work, use that approach in a separate requirements-rtd.txt.
Install the libclang-dev package in RTD to get the libclang.so symlink, so we don't have to reinstate the search logic in conf.py.
RTD apparently tries to use the Ubuntu
libclang.so
even though thelibclang
Python package provides its own copy. A docs build on vanilla Ubuntu 22.04 doesn't, and it's not clear why. Since pinning to an olderclang
Python package is known to work, use that approach in a separaterequirements-rtd.txt
.Install the
libclang-dev
package in RTD to get thelibclang.so
symlink, so we don't have to reinstate the search logic inconf.py
.