meson: Add a workaround for finding the Python library on Fedora

This commit is contained in:
Sebastian Dröge 2016-09-14 15:18:17 +02:00
parent 1b60fedc31
commit a7eebda2ae

View file

@ -20,6 +20,14 @@ def get_python_libloc():
pylib_loc = sysconfig.get_config_var("LIBPL")
pylib_ldlibrary = sysconfig.get_config_var("LDLIBRARY")
py_sharedlib = os.path.join(pylib_loc, pylib_ldlibrary)
if os.path.exists(py_sharedlib):
return pylib_loc
# Workaround for Fedora
pylib_loc = sysconfig.get_config_var("LIBDIR")
pylib_ldlibrary = sysconfig.get_config_var("LDLIBRARY")
py_sharedlib = os.path.join(pylib_loc, pylib_ldlibrary)
if os.path.exists(py_sharedlib):
return pylib_loc