Skip to content

wininst regression: errors when building on linux #53200

Closed

Description

@techtonik
mannequin
BPO 8954
Nosy @mhammond, @birkenfeld, @tarekziade, @merwok, @briancurtin, @zooba
Dependencies
  • bpo-10945: bdist_wininst depends on MBCS codec, unavailable on non-Windows
  • Files
  • suffix.patch: fixed comments version
  • issue1774043_7001.diff
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/merwok'
    closed_at = <Date 2021-02-03.18:37:38.872>
    created_at = <Date 2010-06-09.14:20:42.724>
    labels = ['type-bug', 'library']
    title = 'wininst regression: errors when building on linux'
    updated_at = <Date 2021-02-03.18:37:38.872>
    user = 'https://bugs.python.org/techtonik'

    bugs.python.org fields:

    activity = <Date 2021-02-03.18:37:38.872>
    actor = 'steve.dower'
    assignee = 'eric.araujo'
    closed = True
    closed_date = <Date 2021-02-03.18:37:38.872>
    closer = 'steve.dower'
    components = ['Distutils', 'Distutils2']
    creation = <Date 2010-06-09.14:20:42.724>
    creator = 'techtonik'
    dependencies = ['10945']
    files = ['20325', '20451']
    hgrepos = []
    issue_num = 8954
    keywords = ['patch']
    message_count = 24.0
    messages = ['107398', '107399', '107400', '107432', '107533', '107535', '107536', '108776', '109984', '110075', '110076', '110083', '110109', '118800', '119085', '125847', '126523', '126529', '135893', '135902', '155568', '155592', '161316', '386442']
    nosy_count = 11.0
    nosy_names = ['mhammond', 'georg.brandl', 'jafo', 'techtonik', 'tarek', 'eric.araujo', 'brian.curtin', 'alexis', 'runtux', 'Aaron.Staley', 'steve.dower']
    pr_nums = []
    priority = 'normal'
    resolution = 'out of date'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue8954'
    versions = ['3rd party', 'Python 2.7', 'Python 3.2', 'Python 3.3']

    Activity

    1. techtonik commented on Jun 9, 2010

      techtonikmannequin
      MannequinAuthor

      2.5.1 version of distutils was able to correctly build wininst dists from linux. Right now there are errors which I'll describe in more details once I can get some Linux box.

    2. added
      stdlibStandard Library Python modules in the Lib/ directory
      on Jun 9, 2010
    3. techtonik commented on Jun 9, 2010

      techtonikmannequin
      MannequinAuthor

      At least is was reported that compiled binaries contains wrong platform name, i.e. 'linux' and there are errors about inability to look up some compiler options in windows registry while building.

    4. briancurtin commented on Jun 9, 2010

      @briancurtin
      Member

      Where was that reported?

    5. techtonik commented on Jun 9, 2010

      techtonikmannequin
      MannequinAuthor
    6. techtonik commented on Jun 11, 2010

      techtonikmannequin
      MannequinAuthor
      $ python setup.py build bdist_wininst
      running build
      running build_py
      running bdist_wininst
      installing to build/bdist.linux-i686/wininst
      running install_lib
      creating build/bdist.linux-i686/wininst
      creating build/bdist.linux-i686/wininst/PURELIB
      copying build/lib.linux-i686-2.6/wget.py -> build/bdist.linux-i686/wininst/PURELIB
      running install_egg_info
      Writing build/bdist.linux-i686/wininst/PURELIB/wget-0.6.egg-info
      creating '/tmp/tmpQQZI5O.zip' and adding '.' to it
      adding 'PURELIB/wget-0.6.egg-info'
      adding 'PURELIB/wget.py'
      creating dist
      Warning: Can't read registry to find the necessary compiler setting
      Make sure that Python modules _winreg, win32api or win32con are installed.
      removing 'build/bdist.linux-i686/wininst' (and everything under it)
      $ ls dist
      wget-0.6.linux-i686.exe
    7. merwok commented on Jun 11, 2010

      @merwok
      Member

      The error comes from the msvccompiler module, which shouldn’t get used on non-Windows platforms unless I’m mistaken. Reading the module, I’m not sure at all this command was meant to be run on not-Windows OSes.

    8. techtonik commented on Jun 11, 2010

      techtonikmannequin
      MannequinAuthor

      It did run ok on non-Windows OSes with previous Python versions.

    9. birkenfeld commented on Jun 27, 2010

      @birkenfeld
      Member

      It certainly should be possible to build these installers, and if I understand your output correctly, an installer *was* built. The warning is, after all, just a warning, and probably just the warning got added compared to 2.5, but the behavior is the same.

      The platform name is a regression though.

    10. techtonik commented on Jul 11, 2010

      techtonikmannequin
      MannequinAuthor

      The regression is two-fold:

      1. platform name regression is caused by r62197 by Mark Hammond - Issue bpo-2513: enable 64bit cross compilation on windows

      2. when wininst stub selection started to depend on MSVC compiler version is yet to be investigated, but I am sure that wininst stub selection should only be affected by compatibility with operating system only

      More complete research notes are at https://wave.google.com/wave/waveref/googlewave.com/w+GnQ9tjc8A

    11. techtonik commented on Jul 12, 2010

      techtonikmannequin
      MannequinAuthor
    12. birkenfeld commented on Jul 12, 2010

      @birkenfeld
      Member

      Did you test that patch? ISTM that it contains a syntax error:

      + if not self.distribution.has_ext_modules()
      + and not self.distribution.has_c_libraries():

    13. techtonik commented on Jul 12, 2010

      techtonikmannequin
      MannequinAuthor

      reuploaded correct version to rietveld.

    14. 1 remaining item

    15. birkenfeld commented on Oct 15, 2010

      @birkenfeld
      Member

      Raising priority.

    16. merwok commented on Oct 18, 2010

      @merwok
      Member

      I get an error trying to run the command because of the use of the mbcs codec.

      Ezio made some comments on Rietveld, I addressed them in a local clone.

      Question for Windows users/experts: Do the terms “binary extension” and “binary code” make sense? If not, I can change them to the clearer “extension modules” and “C code”.

    17. assigned and unassigned on Oct 18, 2010
    18. techtonik commented on Jan 9, 2011

      techtonikmannequin
      MannequinAuthor

      Fixed Ezio comments at http://codereview.appspot.com/1774043

      Eric, if I understand you correctly, the mbcs issue you're experiencing is unrelated to the patch. What else do you need?

    19. techtonik commented on Jan 19, 2011

      techtonikmannequin
      MannequinAuthor

      Is this issue really critical?
      Bump.

    20. merwok commented on Jan 19, 2011

      @merwok
      Member

      I opened another bug for the MBCS problem which prevents me from testing Anatoly’s patch.

    21. runtux commented on May 13, 2011

      runtuxmannequin
      Mannequin

      2.6 already produces a .linux-i686.exe package instead of .win32.exe when running bdist_wininst. I've now used python2.5 for producing a binary windows installer for roundup.

    22. merwok commented on May 13, 2011

      @merwok
      Member

      2.6 only gets security fixes.

    23. jafo commented on Mar 13, 2012

      jafomannequin
      Mannequin

      Éric: In http://bugs.python.org/issue8954#msg135902 are you saying:

      This issue needs to be re-targeted to a newer Python.
      Close -- won't fix.
      Something else?

      This issue seems to be stuck here, any ideas on what needs to be done to move this forward?

    24. merwok commented on Mar 13, 2012

      @merwok
      Member

      Sean: In msg135902 I am merely explaining why I removed 2.6 from the list of versions. Only 2.7, 3.2 and 3.3 can get fixed.

      If you look at my previous message or the list of dependencies, you can see that bpo-10945 needs to be fixed first before I can review the patch provided for this issue.

    25. AaronStaley commented on May 22, 2012

      AaronStaleymannequin
      Mannequin

      I was looking over this patch (as it relates to my bug report: http://bugs.python.org/issue14877?@ok_message=msg%20161314%20created%3Cbr%3Eissue%2014877%20message_count%2C%20messages%20edited%20ok&@template=item) and noticed that this line:

      + if (not self.distribution.has_ext_modules() and
      + not self.distribution.has_c_libraries()):
      + basename = "%s.%s" % (fullname, "win32")

      I feel it may be better to insert plat_name there if it exists. That way, users can create installers targeted for win-amd64. Why is this needed for a pure python packages? This bug: http://bugs.python.org/issue6792

    26. zooba commented on Feb 3, 2021

      @zooba
      Member

      Distutils is now deprecated (see PEP-632) and all tagged issues are being closed. From now until removal, only release blocking issues will be considered for distutils.

      If this issue does not relate to distutils, please remove the component and reopen it. If you believe it still requires a fix, most likely the issue should be re-reported at https://github.com/pypa/setuptools

    27. transferred this issue fromon Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    Labels

    stdlibStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions