It is possible for a python script to detect if it's running natively, or is a pyinstaller package, so it shouldn't be too hard to have some code that adapts and uses the bundled xpack-openocd package. And since it's MIT licensed, it can be distributed without any issue.
https://github.com/xpack-dev-tools/openocd-xpack/blob/xpack/LICENSE