Cross-compilation fails
Compilation fails when trying to compile from Linux to Windows. It appears to be an error in the way the path to the civetweb.c is formatted. I think that changing the way the path is handled depending the selected OS should fix the problem.
Log
[chiguire@nixos-home:~/Documents/Projects/test]$ nimble build --debug --os:windows
Info: Nimble data file "/home/chiguire/.nimble/nimbledata2.json" has been loaded.
Executing git -C /home/chiguire/Documents/Projects/test ls-files
Executing git -C /home/chiguire/Documents/Projects/test rev-parse HEAD
Executing git -C /home/chiguire/Documents/Projects/test rev-parse --abbrev-ref --symbolic-full-name @{u}
Executing git -C /home/chiguire/Documents/Projects/test branch --show-current
Executing git -C /home/chiguire/Documents/Projects/test remote get-url origin
Executing /nix/store/caak801vp479rl850kmwrmshnz90078d-x86_64-unknown-linux-gnu-nim-wrapper-2.2.4/bin/x86_64-unknown-linux-gnu-nim e --hints:off --verbosity:0 --define:nimbleExe=/nix/store/3f35yjdlbk7dmaywaqvsnsb4g8173bin-nimble-0.18.2/bin/.nimble-wrapped --colors:on --define:NimbleVersion=0.18.2 --define:NimbleMajor=0 --define:NimbleMinor=18 --define:NimblePatch=2 /tmp/nix-shell.P6QtTE/nimblecache-1361166557672987771/nimiSlides_2928252294306805980/nimiSlides.nims /home/chiguire/.nimble/pkgs2/nimiSlides-0.2.6-61de4f10c06a123d4256f9ea0aadc0afe9ddacaa/nimiSlides.nimble /tmp/nix-shell.P6QtTE/nimble_12039.out printPkgInfo
Warning: Not removing temporary path because of debug verbosity: /tmp/nix-shell.P6QtTE/nimble_12039.out
Reading official package list
Reading official package list
Building test/test using c backend
Info: compiling nim package using /nix/store/caak801vp479rl850kmwrmshnz90078d-x86_64-unknown-linux-gnu-nim-wrapper-2.2.4/bin/x86_64-unknown-linux-gnu-nim
Executing /nix/store/caak801vp479rl850kmwrmshnz90078d-x86_64-unknown-linux-gnu-nim-wrapper-2.2.4/bin/x86_64-unknown-linux-gnu-nim c --colors:on --noNimblePath --os:windows -d:NimblePkgVersion=0.1.0 --path:/home/chiguire/.nimble/pkgs2/webui-2.5.0.0-a867ccb9f7b6cabadbf6986bcc1847c44fbc8099 -o:/home/chiguire/Documents/Projects/test/test /home/chiguire/Documents/Projects/test/src/test.nim
Output Hint: used config file '/nix/store/caak801vp479rl850kmwrmshnz90078d-x86_64-unknown-linux-gnu-nim-wrapper-2.2.4/etc/nim/nim.cfg' [Conf]
... Hint: used config file '/nix/store/caak801vp479rl850kmwrmshnz90078d-x86_64-unknown-linux-gnu-nim-wrapper-2.2.4/etc/nim/config.nims' [Conf]
... Hint: used config file '/home/chiguire/Documents/Projects/test/config.nims' [Conf]
... ........................................................................................................................
... /home/chiguire/.nimble/pkgs2/webui-2.5.0.0-a867ccb9f7b6cabadbf6986bcc1847c44fbc8099/webui/bindings.nim(121, 12) Error: cannot find: \home\chiguire\.nimble\pkgs2\webui-2.5.0.0-a867ccb9f7b6cabadbf6986bcc1847c44fbc8099\webui\webui\src\civetweb\civetweb.c
nimble.nim(415) buildFromDir
Error: Build failed for the package: test
Warning: Not removing temporary path because of debug verbosity: /tmp/nix-shell.P6QtTE/nimble_12039
Info: Nimble data file "/home/chiguire/.nimble/nimbledata2.json" has been saved.
Thank you for reporting this out, if you find a solution feel free to create a PR
Thanks, I'll modify bindings.nim and submit it later
Sorry, but it turns out that the problem was that I forgot to add the '-d:mingw' flag when calling the compiler. The bindings work fine
Glad it's working, Thank you @CarmeloMaitaO