From 412f5ecc2a7ed36e1653d634afaf7dd5a846d982 Mon Sep 17 00:00:00 2001 From: rdb Date: Fri, 9 Nov 2018 17:35:47 +0100 Subject: [PATCH] makepanda: more reliable way to get extension suffix --- makepanda/makepandacore.py | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/makepanda/makepandacore.py b/makepanda/makepandacore.py index a8c578e258..435b45a023 100644 --- a/makepanda/makepandacore.py +++ b/makepanda/makepandacore.py @@ -3260,14 +3260,8 @@ def SetOrigExt(x, v): def GetExtensionSuffix(): if sys.version_info >= (3, 0): - suffix = sysconfig.get_config_var('EXT_SUFFIX') - if suffix == '.so': - # On my FreeBSD system, this is not set correctly, but SOABI is. - soabi = sysconfig.get_config_var('SOABI') - if soabi: - return '.%s.so' % (soabi) - elif suffix: - return suffix + import _imp + return _imp.extension_suffixes()[0] target = GetTarget() if target == 'windows':