I'm writing a setup.py which uses setuptools/distutils to install a python package I wrote.
It need to install two DLL files (actually a DLL file and a PYD file) into location which is available for python to load. Thought this is the DLLs
directory under the installation directory on my python distribution (e.g. c:\Python27\DLLs
).
I've used data_files option to install those files and all work when using pip:
data_files=[(sys.prefix + "/DLLs", ["Win32/file1.pyd", "Win32/file2.dll"])]
But using easy_install I get the following error:
error: Setup script exited with error: SandboxViolation: open('G:\\Python27\\DLLs\\file1.pyd', 'wb') {}
The package setup script has attempted to modify files on your system that are not within the EasyInstall build area, and has been aborted.
So, what's the right way to install those files?