From e5f16d506fdafe3cf3a3f21d59213d3d35116390 Mon Sep 17 00:00:00 2001 From: pin Date: Fri, 18 Jun 2010 07:45:29 +0000 Subject: [PATCH 1/1] =?utf8?q?Les=20donn=C3=A9es=20sont=20r=C3=A9cup=C3=A9?= =?utf8?q?r=C3=A9es=20dans=20l'installation=20de=20python,=20plut=C3=B4t?= =?utf8?q?=20que=20dans=20les=20sources.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit git-svn-id: https://svn.cri.ensmp.fr/svn/minwii/trunk@238 fe552daf-6dbe-4428-90eb-1537e0879342 --- setup_win_exe.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/setup_win_exe.py b/setup_win_exe.py index 1fa44dd..ed6aba6 100755 --- a/setup_win_exe.py +++ b/setup_win_exe.py @@ -43,15 +43,18 @@ def findPguThemesDir() : if os.path.isdir(dname): return dname raise IOError('pgu themes folder not found') - + +def findMinwiiDir() : + import minwii + return os.path.dirname(minwii.__file__) class MinWii2exe(py2exe.build_exe.py2exe) : def copy_extensions(self, extensions) : py2exe.build_exe.py2exe.copy_extensions(self, extensions) - - self.copyDataFiles('src/minwii/fonts', 'minwii/fonts') - self.copyDataFiles('src/minwii/soundfonts', 'minwii/soundfonts') - self.copyDataFiles('src/minwii/widgets/data', 'minwii/widgets/data') + minwiiDir = findMinwiiDir() + self.copyDataFiles(os.path.join(minwiiDir, 'fonts'), 'minwii/fonts') + self.copyDataFiles(os.path.join(minwiiDir, 'soundfonts'), 'minwii/soundfonts') + self.copyDataFiles(os.path.join(minwiiDir, 'widgets', 'data'), 'minwii/widgets/data') self.copyDataFiles(findPguThemesDir(), 'data/themes') pygamedir = os.path.dirname(pygame.base.__file__) -- 2.20.1