eschnett opened a new issue, #45032: URL: https://github.com/apache/arrow/issues/45032
### Describe the bug, including details regarding any error messages, version, and platform. I want to install Arrow on Windows with the Zstd library. This fails with the error message ``` [14:00:22] src/arrow/CMakeFiles/arrow_shared.dir/build.make:978: *** target pattern contains no '%'. Stop. [14:00:22] make[1]: *** [CMakeFiles/Makefile2:714: src/arrow/CMakeFiles/arrow_shared.dir/all] Error 2 ``` This error message is caused by the following lines in the mentioned file: ``` release/libarrow.dll: /workspace/destdir/lib/liblz4.dll.a release/libarrow.dll: /opt/x86_64-w64-mingw32/x86_64-w64-mingw32/sys-root/usr/local/lib/libsnappy.dll.a release/libarrow.dll: /workspace/destdir/lib/libz.dll.a release/libarrow.dll: zstd::libzstd_shared-NOTFOUND release/libarrow.dll: src/arrow/CMakeFiles/arrow_shared.dir/linklibs.rsp release/libarrow.dll: src/arrow/CMakeFiles/arrow_shared.dir/objects1.rsp release/libarrow.dll: src/arrow/CMakeFiles/arrow_shared.dir/link.txt ``` See the `NOTFOUND` entry. See https://github.com/JuliaPackaging/Yggdrasil/pull/9801 for related discussion. While debugging I saw a cmake warning about a missing `IMPORTED_IMPLIB` declaration. Indeed, adding such a declaration fixed the issue. I made this change: ``` --- a/cpp/cmake_modules/FindzstdAlt.cmake +++ b/cpp/cmake_modules/FindzstdAlt.cmake @@ -136,6 +136,7 @@ endif() set_target_properties(${zstd_TARGET} PROPERTIES IMPORTED_LOCATION "${ZSTD_LIB}" + IMPORTED_IMPLIB /workspace/destdir/bin/libzstd-1.dll INTERFACE_INCLUDE_DIRECTORIES "${ZSTD_INCLUDE_DIR}") message(STATUS "Zstandard library: ${ZSTD_LIB}") message(STATUS "Zstandard include directory: ${ZSTD_INCLUDE_DIR}") ``` ### Component(s) C++ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@arrow.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org