CommandLineSupport: add a directive for autolinking on Windows

We use functions from Shell32.Lib. Ensure that we indicate the
autolinking to the linker. This aides when building with a static
runtime to avoid having to specify the additional library dependency for
clients that are attempting to link against the runtime. This is
particularly important for the CMake compiler check where we would need
to list Shell32 as a required link library.
This commit is contained in:
Saleem Abdulrasool
2025-05-17 09:17:14 -07:00
parent 50e30709a5
commit 3b968f699a

View File

@@ -37,6 +37,7 @@
#define WIN32_LEAN_AND_MEAN
#include <Windows.h>
#include <shellapi.h>
#pragma comment(lib, "shell32.lib")
#endif
// Backing storage for overrides of `Swift.CommandLine.arguments`.