swift-cross-ui icon indicating copy to clipboard operation
swift-cross-ui copied to clipboard

Error building on Windows

Open timi2506 opened this issue 2 months ago • 4 comments

hi @stackotter, love swift-cross-ui! it works perfectly on my mac and (after a bit of fixing) on linux too! i only got one last problem: Windows.

i tried all sorts of things but it keeps on failing to build! the current log is:

C:\Users\_REDACTED_\HelloWorld>swift-bundler run
info: Loading package manifest
info: Starting debug build
warning: failed to retrieve search paths with pkg-config; maybe pkg-config is not installed
warning: couldn't find pc file for gtk+-3.0
warning: couldn't find pc file for gtk4
warning: couldn't find pc file for gtk+-3.0
warning: couldn't find pc file for gtk4
[1/1] Planning build
Building for debugging...
lld-link: error: undefined symbol: main
>>> referenced by D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:78
>>>               msvcrt.lib(exe_main.obj):(int __cdecl invoke_main(void))
>>> referenced by D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:288
>>>               msvcrt.lib(exe_main.obj):(int __cdecl __scrt_common_main_seh(void))
clang: error: linker command failed with exit code 1 (use -v to see invocation)
[3/172] Linking HotReloadingMacrosPlugin-tool.exe

attached is the Source Code for my testing app and the full log (swift-bundler run -v)

HelloWorld.zip

log.txt

timi2506 avatar Oct 22 '25 18:10 timi2506