Skip to content

Gfortran DLLs hash computed from input files, not DLLs #11415

@pv

Description

@pv

The gfortran DLL file names here: https://github.com/numpy/numpy/blob/master/numpy/distutils/fcompiler/gnu.py#L408 are computed from input file content, rather than from the content of the DLL file itself.

Windows DLLs appear to have two possible ways to import symbols --- by name, or by import table ordinal. It appears the functions tend to get imported by ordinal in the way we are doing things currently.

This may be a problem: the SHA1 hash ensures the input files, their content, and the order they are passed to the mingw DLL linker command are identical. However, it does not ensure the mingw linker puts items in the same order in the import table -- different mingw versions might put functions in different orders in the import table.

It would be better to compute the SHA1 has from the DLL file itself --- or to enforce MSVC to use link-by-name.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions