Skip to content

Remove the concept of platform-specific directories #72233

Description

@zware
BPO 28046
Nosy @doko42, @vstinner, @ned-deily, @xdegaye, @zware, @moreati, @yan12125
PRs
  • bpo-28046: Remove MACHDEPPATH from Modules/Setup.dist #5289
  • Files
  • remove_plat.diff
  • get_sysconfigdata_name.diff
  • sysconfigdata_env_var.diff
  • sysconfigdata_ABIFLAGS.patch
  • 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 = None
    closed_at = <Date 2018-01-24.16:20:41.981>
    created_at = <Date 2016-09-09.17:58:33.545>
    labels = ['type-feature', '3.7', 'build']
    title = 'Remove the concept of platform-specific directories'
    updated_at = <Date 2018-01-24.16:20:41.980>
    user = 'https://github.com/zware'

    bugs.python.org fields:

    activity = <Date 2018-01-24.16:20:41.980>
    actor = 'vstinner'
    assignee = 'none'
    closed = True
    closed_date = <Date 2018-01-24.16:20:41.981>
    closer = 'vstinner'
    components = ['Build', 'Cross-Build']
    creation = <Date 2016-09-09.17:58:33.545>
    creator = 'zach.ware'
    dependencies = []
    files = ['44506', '44530', '44532', '45232']
    hgrepos = []
    issue_num = 28046
    keywords = ['patch']
    message_count = 35.0
    messages = ['275360', '275363', '275427', '275429', '275430', '275433', '275436', '275438', '275442', '275475', '275477', '275518', '275519', '275532', '275592', '275599', '275635', '275638', '275642', '275643', '275650', '275664', '275667', '275677', '275711', '275845', '275846', '275850', '276245', '279508', '279592', '303426', '310539', '310605', '310608']
    nosy_count = 8.0
    nosy_names = ['doko', 'vstinner', 'ned.deily', 'xdegaye', 'python-dev', 'zach.ware', 'Alex.Willmer', 'yan12125']
    pr_nums = ['5289']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue28046'
    versions = ['Python 3.6', 'Python 3.7']

    Activity

    1. zware commented on Sep 9, 2016

      @zware
      MemberAuthor

      As a follow-on to bpo-28027, the attached patch removes the concept of platform-specific directories (Lib/plat-darwin, Lib/plat-x86_64-linux-gnu, etc). I believe this should be fine for cross-builds (at least as fine as the previous solution for _sysconfigdata), but I'd like someone to test it for me since I have no experience with cross-builds.

    2. self-assigned this
      on Sep 9, 2016
    3. added
      buildThe build process and cross-build
      type-featureA feature request or enhancement
      on Sep 9, 2016
    4. vstinner commented on Sep 9, 2016

      @vstinner
      Member

      You might also remove Lib/_sysconfigdata.py from .gitignore.

    5. doko42 commented on Sep 9, 2016

      @doko42
      Member

      not sure if I fully understand:

      • The patch encodes the multiarch triplet into the _sysconfigdata
        name and installs it into the standard lib dir.
      • It removes the PLATDIR macro
      • what happens to the constants modules which are currently
        found in the platdir? These vary across architectures and
        should not be install in the standard lib dir.
    6. zware commented on Sep 9, 2016

      @zware
      MemberAuthor

      Those were removed in bpo-28027, by BDFL decree.

    7. doko42 commented on Sep 9, 2016

      @doko42
      Member

      this comes as a surprise. I can't remember that discussion and decision.

    8. zware commented on Sep 9, 2016

      @zware
      MemberAuthor

      Sorry, it happened at the sprint at Instagram. Do you have a use for those modules that we need to reconsider?

    9. vstinner commented on Sep 9, 2016

      @vstinner
      Member

      this comes as a surprise. I can't remember that discussion and decision.

      Removing these modules is not a new idea: I just posted a message to the issue bpo-28027 to complete the history of this change.

    10. doko42 commented on Sep 9, 2016

      @doko42
      Member

      The removal is not following the guidelines to first deprecate these for a release, and then to remove them. I know that at least the RTLD_* constants are used in a number of places, which will just stop working.

      I'm not against removing these in 3.7, however they should be deprecated in 3.6 first. There is no harm done with this approach.

    11. vstinner commented on Sep 9, 2016

      @vstinner
      Member

      Matthias Klose added the comment:

      The removal is not following the guidelines to first deprecate these for a release, and then to remove them. I know that at least the RTLD_* constants are used in a number of places, which will just stop working.

      Please continue the discussion in the issue bpo-28027, reopen it if you want.

    12. zware commented on Sep 9, 2016

      @zware
      MemberAuthor

      Xavier: Could you please make sure this doesn't break anything for Android/cross-builds?

    13. xdegaye commented on Sep 9, 2016

      xdegayemannequin
      Mannequin

      Sure, I was already planning to do it :)

    14. 15 remaining items

    15. xdegaye commented on Sep 11, 2016

      xdegayemannequin
      Mannequin

      Thanks for your help in testing these changes Chi Hsuan Yen.

    16. yan12125 commented on Sep 11, 2016

      yan12125mannequin
      Mannequin

      No No, it's me who should say thank you. Thanks for all efforts on maintaining the Android port of CPython!

    17. doko42 commented on Sep 13, 2016

      @doko42
      Member

      I don't like the _PYTHON_SYSCONFIGDATA_NAME hack. This should be based on the target, not on a name for just a particular file. Following up on that in bpo-28125.

    18. xdegaye commented on Oct 26, 2016

      xdegayemannequin
      Mannequin

      'make install' fails to remove the sysconfigdata module from lib-dynload and prints now instead:

      rm: cannot remove '/path/to/install/lib/python3.7/lib-dynload/_sysconfigdata_m.py': No such file or directory
      

      The patch fixes this. It also removes a useless and now incorrect line that was meant to echo the previously executed command.

    19. python-dev commented on Oct 28, 2016

      python-devmannequin
      Mannequin

      New changeset 86577b7100a4 by Xavier de Gaye in branch '3.6':
      Issue bpo-28046: Fix the removal of the sysconfigdata module
      https://hg.python.org/cpython/rev/86577b7100a4

      New changeset 28205c4cf20b by Xavier de Gaye in branch 'default':
      Issue bpo-28046: Merge with 3.6.
      https://hg.python.org/cpython/rev/28205c4cf20b

    20. zware commented on Sep 30, 2017

      @zware
      MemberAuthor

      Are there any remaining outstanding issues here?

    21. removed their assignment
      on Sep 30, 2017
    22. vstinner commented on Jan 24, 2018

      @vstinner
      Member

      The cleanup is not complete, so I reopen the issue: #5289

    23. vstinner commented on Jan 24, 2018

      @vstinner
      Member

      New changeset 5de15f1 by Victor Stinner in branch 'master':
      bpo-28046: Remove MACHDEPPATH from Modules/Setup.dist (bpo-5289)
      5de15f1

    24. vstinner commented on Jan 24, 2018

      @vstinner
      Member

      Fixed. I close again the issue. I don't want to backport this change, it doesn't hurt Python 3.6.

    25. 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

    No one assigned

      Labels

      3.7 (EOL)end of lifebuildThe build process and cross-buildtype-featureA feature request or enhancement

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions