Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PyInstaller cannot build bootloader for 32-bit or 64-bit #4211

Open
aixtools opened this issue May 4, 2019 · 1 comment

Comments

@aixtools
Copy link

commented May 4, 2019

To get PyInstaller able to successfully build (and install) the bootloader I had to make a few changes to bootloader/wscript

One is simply a 'typo', the other - I am not as sure about - so I just commented it away.

Here is the diff -u (open for reactions before I assemble a PR)

HEAD is now at 0f31b35... Release 3.4.

diff -ru ./wscript /home/root/python/PyInstaller-3.4/bootloader/wscript
--- ./wscript   2019-05-04 09:50:41.000000000 +0000
+++ /home/root/python/PyInstaller-3.4/bootloader/wscript        2019-05-01 14:18:49.000000000 +0000
@@ -461,11 +461,11 @@
          ctx.find_program([assoc_programm(ctx, 'strip')], var='STRIP')
          ctx.load('strip', tooldir='tools')
          # There is a strip flag for AIX environment
-         if ctx.env.DEST_OS == 'aix':
-             if ctx.env.PYI_ARCH == '32bit':
-                 ctx.env.append_value('STRIPFLAGS', '-X32')
-             elif ctx.env.PYI_ARCH == '64bit':
-                 ctx.env.append_value('STRIPFLAGS', '-X64')
+         # if ctx.env.DEST_OS == 'aix':
+         #     if ctx.env.PYI_ARCH == '32bit':
+         #         ctx.env.append_value('STRIPFLAGS', '-X32')
+         #     elif ctx.env.PYI_ARCH == '64bit':
+         #         ctx.env.append_value('STRIPFLAGS', '-X64')

      ### C Compiler optimizations.
      # TODO Set proper optimization flags for MSVC (Visual Studio).
@@ -771,7 +771,7 @@
          if ctx.env.DEST_OS == 'aix':
              # link statically with zlib
              libs.remove('Z')
-             staticlibs.append('Z')
+             staticlibs.append('z')

          if ctx.options.boehmgc:
              libs.append('GC')
@htgoebel

This comment has been minimized.

Copy link
Member

commented Aug 7, 2019

Well, AIX is a contributed platform only, so I can't tell much except:

  • The STRIPFLAGS have been added intentionally somewhen. Why are they not longer needed? How to test whether they are required for a correct build?
  • Regarding "Z": this seems to be intriduced in 47ca3e5 and should be fixed.

I'd appreciate a pull-request containing two commits: one for each change. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.