Hello,

it looks like building COM servers was broken in 1.0 because when I switched
to the new build system for bootloader I forgot to change Build.py so that
it would find the bootloader under the new name.

The problem was reported and analyzed by Sebastián Lezica (thanks!). I made
a slightly change to his suggested fix to re-use the existing code.
Committed as r241.
-- 
Giovanni Bajo
Index: Build.py
===================================================================
--- Build.py    (revision 227)
+++ Build.py    (working copy)
@@ -483,22 +483,24 @@
             print "rebuilding %s because pkg is more recent" % outnm
             return 1
         return 0
-    def assemble(self):
-        print "building ELFEXE", os.path.basename(self.out)
-        trash = []
-        outf = open(self.name, 'wb')
+    def _bootloader_postfix(self, exe):
         if iswin:
-            exe = 'support/loader/run_'
+            exe = exe + "_"
             is24 = hasattr(sys, "version_info") and sys.version_info[:2] >= 
(2,4)
             exe = exe + "67"[is24]
             exe = exe + "rd"[self.debug]
             exe = exe + "wc"[self.console]
         else:
-            exe = 'support/loader/run'
             if not self.console:
                 exe = exe + 'w'
             if self.debug:
                 exe = exe + '_d'
+        return exe
+    def assemble(self):
+        print "building ELFEXE", os.path.basename(self.out)
+        trash = []
+        outf = open(self.name, 'wb')
+        exe = self._bootloader_postfix('support/loader/run')
         exe = os.path.join(HOMEPATH, exe)
         if iswin or cygwin:
             exe = exe + '.exe'
@@ -541,9 +543,7 @@
     def assemble(self):
         print "building DLL", os.path.basename(self.out)
         outf = open(self.name, 'wb')
-        dll = 'support/loader/inprocsrvr'
-        if self.debug:
-            dll = dll + '_d'
+        dll = self._bootloader_postfix('support/loader/inprocsrvr')
         dll = os.path.join(HOMEPATH, dll)  + '.dll'
         self.copy(dll, outf)
         self.copy(self.pkg.name, outf)
Index: doc/CHANGES.txt
===================================================================
--- doc/CHANGES.txt     (revision 240)
+++ doc/CHANGES.txt     (working copy)
@@ -8,6 +8,8 @@
  + Fix problem with rare encodings introduced in newer Python versions: now all
    the encodings are automatically found and included, so this problem should
    be gone forever.
+ + Fix building of COM servers (was broken in 1.0 because of the new build
+   system).
  + Mimic Python 2.4 behaviour with broken imports: sys.modules is cleaned up
    afterwise. This allows to package SQLObject applications under Windows
    with Python 2.4 and above.
_______________________________________________
PyInstaller mailing list
[email protected]
http://lists.hpcf.upr.edu/mailman/listinfo/pyinstaller

Reply via email to