Skip to content

Commit 4f4f792

Browse files
authored
Use "shared" msvc hermetic toolchain (bazel-contrib#694)
Using python packages with C modules, e.g. numpy, would fail when using the "static" toolchain. See astral-sh/python-build-standalone#124 When using the "shared" toolchain, importing numpy is successful
1 parent d086a0d commit 4f4f792

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

python/repositories.bzl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,7 @@ filegroup(
117117
srcs = glob(
118118
include = [
119119
"*.exe",
120+
"*.dll",
120121
"bin/**",
121122
"DLLs/**",
122123
"extensions/**",

python/versions.bzl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ TOOL_VERSIONS = {
4242
"aarch64-apple-darwin": "f9a3cbb81e0463d6615125964762d133387d561b226a30199f5b039b20f1d944",
4343
# no aarch64-unknown-linux-gnu build available for 3.8.12
4444
"x86_64-apple-darwin": "f323fbc558035c13a85ce2267d0fad9e89282268ecb810e364fff1d0a079d525",
45-
"x86_64-pc-windows-msvc": "924f9fd51ff6ccc533ed8e96c5461768da5781eb3dfc11d846f9e300fab44eda",
45+
"x86_64-pc-windows-msvc": "4658e08a00d60b1e01559b74d58ff4dd04da6df935d55f6268a15d6d0a679d74",
4646
"x86_64-unknown-linux-gnu": "5be9c6d61e238b90dfd94755051c0d3a2d8023ebffdb4b0fa4e8fedd09a6cab6",
4747
},
4848
"strip_prefix": "python",
@@ -53,7 +53,7 @@ TOOL_VERSIONS = {
5353
"aarch64-apple-darwin": "ad66c2a3e7263147e046a32694de7b897a46fb0124409d29d3a93ede631c8aee",
5454
"aarch64-unknown-linux-gnu": "12dd1f125762f47975990ec744532a1cf3db74ad60f4dfb476ca42deb7f78ca4",
5555
"x86_64-apple-darwin": "fdaf594142446029e314a9beb91f1ac75af866320b50b8b968181e592550cd68",
56-
"x86_64-pc-windows-msvc": "5bc65ce023614bf496a6748e41dca934b70fc5fac6dfacc46aa8dbcad772afc2",
56+
"x86_64-pc-windows-msvc": "c145d9d8143ce163670af124b623d7a2405143a3708b033b4d33eed355e61b24",
5757
"x86_64-unknown-linux-gnu": "455089cc576bd9a58db45e919d1fc867ecdbb0208067dffc845cc9bbf0701b70",
5858
},
5959
"strip_prefix": "python",
@@ -64,7 +64,7 @@ TOOL_VERSIONS = {
6464
"aarch64-apple-darwin": "1409acd9a506e2d1d3b65c1488db4e40d8f19d09a7df099667c87a506f71c0ef",
6565
"aarch64-unknown-linux-gnu": "8f351a8cc348bb45c0f95b8634c8345ec6e749e483384188ad865b7428342703",
6666
"x86_64-apple-darwin": "8146ad4390710ec69b316a5649912df0247d35f4a42e2aa9615bffd87b3e235a",
67-
"x86_64-pc-windows-msvc": "a293c5838dd9c8438a84372fb95dda9752df63928a8a2ae516438f187f89567d",
67+
"x86_64-pc-windows-msvc": "a1d9a594cd3103baa24937ad9150c1a389544b4350e859200b3e5c036ac352bd",
6868
"x86_64-unknown-linux-gnu": "9b64eca2a94f7aff9409ad70bdaa7fbbf8148692662e764401883957943620dd",
6969
},
7070
"strip_prefix": "python",
@@ -151,7 +151,7 @@ def get_release_url(platform, python_version, base_url = DEFAULT_RELEASE_BASE_UR
151151
release_filename = url.format(
152152
platform = platform,
153153
python_version = python_version,
154-
build = "static-install_only" if (WINDOWS_NAME in platform) else "install_only",
154+
build = "shared-install_only" if (WINDOWS_NAME in platform) else "install_only",
155155
)
156156
url = "/".join([base_url, release_filename])
157157
return (release_filename, url, strip_prefix)

0 commit comments

Comments
 (0)