Skip to content

Commit

Permalink
setup.py -> eliminate delvewheel mangling and simplify try_unmangle (#26
Browse files Browse the repository at this point in the history
)
  • Loading branch information
jdegenstein authored Apr 19, 2024
1 parent 25ab547 commit be4c950
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,8 @@ def repair_wheel_windows(lib_path, whl, out_dir):
"-m",
"delvewheel",
"repair",
"-vv",
"--no-mangle-all",
f"--wheel-dir={out_dir}",
whl,
]
Expand Down Expand Up @@ -346,10 +348,6 @@ def write_licenses(prefix, whl, always_pkgs, added_files, out):


def try_unmangle(n):
# delvewheel mangling example: "vtkCommonColor-9.0.dll" => "vtkCommonColor-9.0-87ee4902.dll"
m = re.match("^(.+)-[0-9A-Fa-f]{8,}([.]dll)$", n)
if m:
return m.group(1) + m.group(2)
# auditwheel mangling example: "libvtkCommonColor-9.0.so.9.0.1" => "libvtkCommonColor-9-9810eeb7.0.so.9.0.1"
m = re.match("^([^.]+)-[0-9A-Fa-f]{8,}([.].+)$", n)
if m:
Expand Down

0 comments on commit be4c950

Please sign in to comment.