From cd95c7e72a09e65e943ec8e55ced2b36f3ec4967 Mon Sep 17 00:00:00 2001 From: Nikolaj Bjorner Date: Fri, 28 Feb 2025 13:55:44 -0800 Subject: [PATCH] add diagnostics to extraction of Microsoft.pdb/xml/dll Signed-off-by: Nikolaj Bjorner --- scripts/mk_nuget_task.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/scripts/mk_nuget_task.py b/scripts/mk_nuget_task.py index a53012fc9..2dbc8f134 100644 --- a/scripts/mk_nuget_task.py +++ b/scripts/mk_nuget_task.py @@ -77,14 +77,16 @@ def unpack(packages, symbols, arch): replace(f"{tmp}/{package_dir}/bin/libz3.pdb", f"out/runtimes/{dst}/native/libz3.pdb") files = ["Microsoft.Z3.dll", "Microsoft.Z3.pdb", "Microsoft.Z3.xml"] for b in files: - file = f"{package_dir}/bin/{b}" - if os.path.exists(file): - zip_ref.extract(file, f"{tmp}") + file1 = f"{package_dir}/bin/{b}" + file2 = os.path.join(file,"netstandard2.0") + if os.path.exists(file1): + zip_ref.extract(file1, f"{tmp}") replace(f"{tmp}/{package_dir}/bin/{b}", f"out/lib/netstandard2.0/{b}") - file = os.path.join(file,"netstandard2.0") - if os.path.exists(file): - zip_ref.extract(file, f"{tmp}") + elif os.path.exists(file2): + zip_ref.extract(file2, f"{tmp}") replace(f"{tmp}/{package_dir}/bin/netstandard2.0/{b}", f"out/lib/netstandard2.0/{b}") + else: + print(f"Could not find file path {file1} nor {file2}") def mk_targets(source_root):