xapian: fix python bindings with system Python

Closes #33085. Fixes #33082.