Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: windows support #1

Closed
wants to merge 3 commits into from
Closed

WIP: windows support #1

wants to merge 3 commits into from

Conversation

Sahnvour
Copy link

@Sahnvour Sahnvour commented Mar 28, 2020

Tried to run the bootstrap script from windows with msvc as initial compiler.

I got it running until trying to build LLVM with Zig, at the moment for x86_64-windows-gnu.

C:\dev\Zig\bootstrap\out\build-zig-x86_64-windows-gnu>cmake -GNinja C:\dev\Zig\bootstrap\zig   -DCMAKE_C_COMPILER="C:/dev/Zig/bootstrap/out/host/bin/zig.exe"   -DCMAKE_CXX_COMPILER="C:/dev/Zig/bootstrap/out/host/bin/zig.exe"   -DCMAKE_INSTALL_PREFIX=C:\dev\Zig\bootstrap\out\zig-x86_64-windows-gnu   -DCMAKE_PREFIX_PATH=C:\dev\Zig\bootstrap\out\x86_64-windows-gnu   -DCMAKE_CROSSCOMPILING=True   -DCMAKE_BUILD_TYPE=Release   -DZIG_TARGET_TRIPLE=x86_64-windows-gnu   -DZIG_EXECUTABLE=
-- The C compiler identification is Clang 10.0.0
-- The CXX compiler identification is Clang 10.0.0
-- Check for working C compiler: C:/dev/Zig/bootstrap/out/host/bin/zig.exe
-- Check for working C compiler: C:/dev/Zig/bootstrap/out/host/bin/zig.exe -- broken
CMake Error at cmake/3.16.4/share/cmake-3.16/Modules/CMakeTestCCompiler.cmake:60 (message):
  The C compiler

    "C:/dev/Zig/bootstrap/out/host/bin/zig.exe"

  is not able to compile a simple test program.

  It fails with the following output:

    Change Dir: C:/dev/Zig/bootstrap/out/build-zig-x86_64-windows-gnu/CMakeFiles/CMakeTmp

    Run Build Command(s):ninja.exe cmTC_ad170 && [1/2] Building C object CMakeFiles/cmTC_ad170.dir/testCCompiler.c.obj

    [2/2] Linking C executable cmTC_ad170.exe
    FAILED: cmTC_ad170.exe
    cmd.exe /C "cd . && C:\dev\Zig\bootstrap\out\host\bin\zig.exe cc -target x86_64-windows-gnu   CMakeFiles/cmTC_ad170.dir/testCCompiler.c.obj  -o cmTC_ad170.exe -Wl,--out-implib,libcmTC_ad170.dll.a -Wl,--major-image-version,0,--minor-image-version,0  -lkernel32 -luser32 -lgdi32 -lwinspool -lshell32 -lole32 -loleaut32 -luuid -lcomdlg32 -ladvapi32 && cd ."
    warning: unsupported linker arg: --out-implib
    warning: unsupported linker arg: libcmTC_ad170.dll.a
    warning: unsupported linker arg: --major-image-version
    warning: unsupported linker arg: 0
    warning: unsupported linker arg: --minor-image-version
    warning: unsupported linker arg: 0
    lld: error: could not open 'libuuid.a': no such file or directory

    ninja: build stopped: subcommand failed.

I think it should

@andrewrk
Copy link
Member

andrewrk commented Apr 7, 2020

I got this working on POSIX - I think if you update build.bat and carefully match all the changes to the posix shell script, it will work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants