Importing a .pyd (created with SWIG) in Python 2.7.3 on Mac
问题 I have created a .pyd file with SWIG under Windows named (_example.pyd). I am able to send the file to my email and import it with another Windows machine using the same version of Python (Python 2.7.3) with this simple command: .>>> import _example .>>> But when I send it to my email and tried to import the file with a Mac, I get: "No module named _example" Any ideas? In both cases, I saved the file into the Python path. 回答1: This is because Python extensions (.pyd files) are essentially