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

Simplify python3.dll build #85211

Closed
nnemkin mannequin opened this issue Jun 19, 2020 · 5 comments
Closed

Simplify python3.dll build #85211

nnemkin mannequin opened this issue Jun 19, 2020 · 5 comments
Assignees
Labels
3.10 only security fixes OS-windows type-feature A feature request or enhancement

Comments

@nnemkin
Copy link
Mannequin

nnemkin mannequin commented Jun 19, 2020

BPO 41039
Nosy @pfmoore, @tjguk, @zware, @eryksun, @zooba, @nnemkin
PRs
  • bpo-41039: Simplify python3.dll build #20989
  • 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/zooba'
    closed_at = <Date 2020-06-23.19:34:26.248>
    created_at = <Date 2020-06-19.16:27:16.218>
    labels = ['type-feature', '3.10', 'OS-windows']
    title = 'Simplify python3.dll build'
    updated_at = <Date 2020-06-23.19:34:26.247>
    user = 'https://github.com/nnemkin'

    bugs.python.org fields:

    activity = <Date 2020-06-23.19:34:26.247>
    actor = 'steve.dower'
    assignee = 'steve.dower'
    closed = True
    closed_date = <Date 2020-06-23.19:34:26.248>
    closer = 'steve.dower'
    components = ['Windows']
    creation = <Date 2020-06-19.16:27:16.218>
    creator = 'nnemkin'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 41039
    keywords = ['patch']
    message_count = 5.0
    messages = ['371894', '372115', '372130', '372199', '372200']
    nosy_count = 6.0
    nosy_names = ['paul.moore', 'tim.golden', 'zach.ware', 'eryksun', 'steve.dower', 'nnemkin']
    pr_nums = ['20989']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue41039'
    versions = ['Python 3.10']

    @nnemkin
    Copy link
    Mannequin Author

    nnemkin mannequin commented Jun 19, 2020

    python3.dll build process can be simplified if we use linker comment #pragma instead of .def files. Custom build targets become unnecessary and hardcoded Python DLL name can be replaced with a macro.

    Also, python3.dll doesn't need DllMain and can be built with /NOENTRY.

    @nnemkin nnemkin mannequin added 3.10 only security fixes OS-windows type-feature A feature request or enhancement labels Jun 19, 2020
    @zooba
    Copy link
    Member

    zooba commented Jun 22, 2020

    Thanks for the change. It looks good, though I would like to have a NEWS entry for this so that people can find that we made a deliberate change to this DLL.

    I'd also like to do some manual testing to make sure that we aren't going to break any obscure uses. That's basically blocked on me, sorry, but I'll try and get to it asap. Feel free to ping me in a week if I haven't gotten to it.

    @nnemkin
    Copy link
    Mannequin Author

    nnemkin mannequin commented Jun 22, 2020

    Please take your time.

    FWIW, I tested this patch by 1) comparing dumpbin /exports output; 2) comparing bunaries themselves (.dll and .lib) and 3) linking xxlmited module.

    It helps that 7-zip can open .dll and .lib files files as if they were archives.

    @zooba
    Copy link
    Member

    zooba commented Jun 23, 2020

    New changeset 2c6e4e9 by Nikita Nemkin in branch 'master':
    bpo-41039: Simplify python3.dll build (GH-20989)
    2c6e4e9

    @zooba
    Copy link
    Member

    zooba commented Jun 23, 2020

    Thanks!

    @zooba zooba closed this as completed Jun 23, 2020
    @zooba zooba closed this as completed Jun 23, 2020
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.10 only security fixes OS-windows type-feature A feature request or enhancement
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant