-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Open
Labels
platform:windowsWindows support based on the MSVC toolchain / Win32 APIWindows support based on the MSVC toolchain / Win32 APIstatus:discussion
Description
I'm trying to compile a Crystal program on Windows using:
crystal build src/app.cr
The build fails with:
In crystal\share\crystal\src\openssl\lib_crypto.cr:24:27
24 | {% from_libressl = (`sh -c 'hash pkg-config 2> /dev/null || printf %s false'` != "false") &&
^
Error: error executing command: sh -c 'hash pkg-config 2> /dev/null || printf %s false': The system cannot find the file specified.
The compiler is trying to execute a shell command (sh -c ...) during the OpenSSL detection phase, but sh is not available on native Windows. This suggests that the build process relies on Unix tools.
My question: Does Crystal support native development on Windows without requiring a Unix-like environment (like WSL, MSYS2, or Cygwin)? If so, how can I resolve this issue? I'm looking for a solution that works on Windows natively, not by running Crystal in a Linux-like environment.
I'm using:
Windows 11 (64-bit)
Crystal 1.19.1
Thanks.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
platform:windowsWindows support based on the MSVC toolchain / Win32 APIWindows support based on the MSVC toolchain / Win32 APIstatus:discussion