Conversation
- zlib builds: remove `.dll`: As in Unix builds, avoid that a `.dll` can ever be picked up. - bump version to `0.15.0.post2`
478a545 to
5ce4e14
Compare
|
|
||
| set "zlib_dll=%BUILD_PREFIX:~1,-1%/zlib/bin/zlib.dll" | ||
| set "zlib_dll=%zlib_dll:/=\%" | ||
| del "%zlib_dll%" |
There was a problem hiding this comment.
Windows builds still pick up a zlib.dll somewhere, probably from the system...
There was a problem hiding this comment.
HDF5:
2023-03-28T19:36:25.6925189Z -- Could NOT find ZLIB (missing: ZLIB_DIR)
2023-03-28T19:36:25.8188114Z -- Found ZLIB: C:/Program Files (x86)/zlib/lib/zlib.lib (found version "1.2.12")
There was a problem hiding this comment.
Compiled without any backends, the .dll dependencies are reduced to only allowed ones:
$ objdump -p openpmd_api_cxx.cp311-win_amd64.pyd | grep dll
DLL Name: python311.dll
DLL Name: KERNEL32.dll
DLL Name: MSVCP140.dll
DLL Name: VCRUNTIME140_1.dll
DLL Name: VCRUNTIME140.dll
DLL Name: api-ms-win-crt-string-l1-1-0.dll
DLL Name: api-ms-win-crt-heap-l1-1-0.dll
DLL Name: api-ms-win-crt-runtime-l1-1-0.dll
211e44 63 _seh_filter_dll
DLL Name: api-ms-win-crt-convert-l1-1-0.dll
DLL Name: api-ms-win-crt-math-l1-1-0.dll
DLL Name: api-ms-win-crt-stdio-l1-1-0.dll
DLL Name: api-ms-win-crt-locale-l1-1-0.dll
DLL Name: api-ms-win-crt-filesystem-l1-1-0.dll
DLL Name: api-ms-win-crt-environment-l1-1-0.dll
DLL Name: api-ms-win-crt-time-l1-1-0.dll
There was a problem hiding this comment.
Building only zlib & HDF5 already pulls in a zlib.dll again, even with zlib.dll removed in the zlib install path.
Unrelated: also found a PREFER_EXTERNAL_ZLIB option in blosc to avoid building an internal one.
There was a problem hiding this comment.
- setting the HDF5 hints to our zlib explicitly does not help.
- building HDF5 w/o zlib support also pulls in
zlib.dll:-o (zlib built) - building HDF5 w/o zlib support (zlib not built) - this one does not pull a dep in!
- test CMake 3.24+ option: ZLIB_USE_STATIC_LIBS - this one does not pull a dep in!
- also, activates
BUILD_SHARED_LIBS=ONfor zlib, because it cannot be turned off conditionally with current zlib's CMake target logic andzlib1.dllis the correct target to build (and then remove)
- also, activates
- also set zlib options for c-blosc and activate ADIOS2 again
5959f25 to
6e7013d
Compare
3158723 to
e70c2a3
Compare
requries CMake 3.24+
e70c2a3 to
5bc62b9
Compare
a09b8d1 to
60215c6
Compare
60215c6 to
2058077
Compare
| CIBW_ENVIRONMENT: HDF5_USE_STATIC_LIBRARIES='ON' ZLIB_USE_STATIC_LIBS='ON' ADIOS_USE_STATIC_LIBS='ON' openPMD_CMAKE_openPMD_USE_HDF5='ON' openPMD_CMAKE_openPMD_USE_ADIOS2='ON' | ||
| CIBW_ENVIRONMENT_WINDOWS: HDF5_USE_STATIC_LIBRARIES='ON' ZLIB_USE_STATIC_LIBS='ON' openPMD_CMAKE_openPMD_USE_HDF5='ON' openPMD_CMAKE_openPMD_USE_ADIOS2='ON' CMAKE_PREFIX_PATH='C:/Program Files (x86)/ADIOS2;C:/Program Files (x86)/blosc;C:/Program Files (x86)/HDF5;C:/Program Files (x86)/ZFP;C:/Program Files (x86)/zlib' |
There was a problem hiding this comment.
The ZLIB_USE_STATIC_LIBS='ON' env var here has probably no effect: not added to setup.py in #1410
We mostly need to pass this in library_builders.sh/bat when we build dependencies that directly pick up ZLIB.
Applied Post-Release Patches
0.15.0wheel via Wheels: 0.15.0 #1392)0.15.0wheel via Wheels: 0.15.0 #1392)0.15.0.post2.dllcan ever be picked up.zlib.dllreference vanishes inobjectdump -p *.pyd | grep \.dllSkipped