Lenard Lindstrom <len-l@xxxxxxxxx>:
Hi Marcus, Fortunately, from what I can gather, py2exe doesn't actually need a module imported to include it. All it looks for are import statements in the source. It's not necessary for the statement to actually execute. You can see at the bottom of __init__.py: def packager_imports(): """ Some additional things that py2app/py2exe will want to see """ import Numeric import numpy import OpenGL.GL import pygame.macosx import pygame.mac_scrap
So we have to take care that e.g. submodules of numpy, Numeric and co. are also imported correctly within that function, in case they are not by their respective package? What about the following scenario: John User uses pygame, but not OpenGL and Numeric and no pygame modules, which would require them. He has both installed though. What would py2exe do? Package them up, although they do not need to be distributed? If so, that's a waste of resources and clearly a misbehaviour from the user perspective in my opinion. Regards Marcus