Discussion:
Excluding system dlls on Windows
Glenn Ramsey
2011-08-07 21:28:42 UTC
Permalink
Hi,

On Windows 7, PyInstaller (1.5.1) includes the following files:

API-MS-Win-Core-ErrorHandling-L1-1-0.dll
API-MS-Win-Core-Interlocked-L1-1-0.dll
API-MS-Win-Core-LibraryLoader-L1-1-0.dll
API-MS-Win-Core-LocalRegistry-L1-1-0.dll
API-MS-Win-Core-Misc-L1-1-0.dll
API-MS-Win-Core-ProcessThreads-L1-1-0.dll
API-MS-Win-Core-Profile-L1-1-0.dll
API-MS-Win-Core-Synch-L1-1-0.dll
API-MS-Win-Core-SysInfo-L1-1-0.dll
API-MS-Win-Security-Base-L1-1-0.dll
HID.dll
SETUPAPI.dll
CFGMGR.dll
DEVOBJ.dll

These appear to be secondary dependencies of an extension module and because of
these the app does not run on Windows XP, but if I manually delete these files
then it does run.

Is this a bug?

I have excluded the files from the Analysis.binaries using:

a.binaries = [x for x in a.binaries if not
os.path.dirname(x[1]).startswith("C:\\Windows\\system32")]

Is that the right way to do it?

Glenn
--
You received this message because you are subscribed to the Google Groups "PyInstaller" group.
To post to this group, send email to pyinstaller-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to pyinstaller+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
For more options, visit this group at http://groups.google.com/group/pyinstaller?hl=en.
Martin Zibricky
2011-08-08 17:15:00 UTC
Permalink
Post by Glenn Ramsey
These appear to be secondary dependencies of an extension module and because of
these the app does not run on Windows XP, but if I manually delete these files
then it does run.
Is this a bug?
Could you please try the svn version?

On windows the approach was changed to not exclude files, but include.
In other words if system dll should be included it has to be explicitly
named, otherwise system dlls are excluded by default.

Maybe we could discuss if this behavior should be backported to 1.5.x or
not.
--
You received this message because you are subscribed to the Google Groups "PyInstaller" group.
To post to this group, send email to pyinstaller-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to pyinstaller+***@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/pyinstaller?hl=en.
Glenn Ramsey
2011-08-09 22:11:22 UTC
Permalink
Post by Martin Zibricky
Post by Glenn Ramsey
These appear to be secondary dependencies of an extension module and because of
these the app does not run on Windows XP, but if I manually delete these files
then it does run.
Is this a bug?
Could you please try the svn version?
r1572 does not include the system files, but it does include the C and C++
runtime libraries, which is correct IMO.
Post by Martin Zibricky
On windows the approach was changed to not exclude files, but include.
In other words if system dll should be included it has to be explicitly
named, otherwise system dlls are excluded by default.
Maybe we could discuss if this behavior should be backported to 1.5.x or
not.
A package that includes system specific files and does not run on other systems
is not very useful. Given that there is a simple workaround for 1.5.x and that
the svn version seems to work fine for this case, wouldn't it be better to
concentrate on the next release? However it would be useful to document the
technique for excluding files in the 1.5.x manual. I had to search the mailing
list archive to find out how to do it.

Glenn
--
You received this message because you are subscribed to the Google Groups "PyInstaller" group.
To post to this group, send email to pyinstaller-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to pyinstaller+***@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/pyinstaller?hl=en.
Loading...