summaryrefslogtreecommitdiffstats
path: root/lldb/scripts/Python/finishSwigPythonLLDB.py
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/scripts/Python/finishSwigPythonLLDB.py')
-rw-r--r--lldb/scripts/Python/finishSwigPythonLLDB.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/lldb/scripts/Python/finishSwigPythonLLDB.py b/lldb/scripts/Python/finishSwigPythonLLDB.py
index 45cb8b98887..d6eb10d6c99 100644
--- a/lldb/scripts/Python/finishSwigPythonLLDB.py
+++ b/lldb/scripts/Python/finishSwigPythonLLDB.py
@@ -350,8 +350,10 @@ def make_symlink_liblldb( vDictArgs, vstrFrameworkPythonDir, vstrLiblldbFileName
if eOSType == utilsOsType.EnumOsType.Windows:
# When importing an extension module using a debug version of python, you
# write, for example, "import foo", but the interpreter searches for
- # "foo_d.pyd"
- if is_debug_interpreter():
+ # "foo_d.pyd". This only applies for Python 2, however. Python 3 does
+ # not use the _d suffix for extension modules.
+ import six
+ if is_debug_interpreter() and six.PY2:
strTarget += "_d";
strTarget += ".pyd";
else:
OpenPOWER on IntegriCloud