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

Cannot build anything under windows #10

Open
rus084 opened this issue Apr 29, 2024 · 2 comments
Open

Cannot build anything under windows #10

rus084 opened this issue Apr 29, 2024 · 2 comments

Comments

@rus084
Copy link

rus084 commented Apr 29, 2024

I tryed to build simple c++ program under linux and it works
But i cannot do same on windows

  1. i got error "ConfigureError: Could not determine custom compiler version: clang-cl.exe"
  2. I tryed to pass compiler via --cxx-compiler flag, but it doesnt work, i got same error
  3. then i tryed to build under "Developer Command Prompt for VS 2022" and it still doesnt work with same error
  4. i tryed to set USE_CLANG_CL = "no" in ya.conf file, after that i got multiple errors like this:
    Error[-WBadIncl]: in $B/util/charset/util-charset.lib: could not resolve include file: $S/contrib/libs/cxxsupp/libcxxmsvc/include/__utility/forward.h included from here: $S/contrib/libs/cxxsupp/libcxx/include/__algorithm/ranges_make_heap.h
    Seems there is no files in https://github.com/yandex/yatool/tree/main/contrib/libs/cxxsupp/libcxxmsvc
@frazenshtein
Copy link
Contributor

Hello!
I don't have access to any Windows host currently, so I can't show a guaranteed working example. But it seems to me that you need to add a build option -DOS_SDK=local. This option will tell the build system to use the SDK from your local system.

@rus084
Copy link
Author

rus084 commented Apr 30, 2024

Hello!
I set -DOS_SDK=local and got same errors:

Error[-WBadIncl]: in $B/contrib/libs/cxxsupp/libcxxmsvc/libs-cxxsupp-libcxxmsvc.lib: could not resolve include file: $S/contrib/libs/cxxsupp/libcxxmsvc/include/__algorithm/in_out_result.h included from here: $S/contrib/libs/cxxsupp/libcxx/include/__algorithm/ranges_transform.h

But when i set compiler via --cxx-compiler flag, i got another error:

Traceback (most recent call last):
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 2614, in <module>
    main()
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 2608, in main
    build.print_build()
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 623, in print_build
    self._print_other_settings(compiler)
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 750, in _print_other_settings
    cuda = Cuda(self)
           ^^^^^^^^^^
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 2353, in __init__
    if self.cuda_host_compiler.value:
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 2290, in value
    self._value = self.calculate_value()
                  ^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 2295, in calculate_value
    return self.auto if not callable(self.auto) else self.auto()
                                                     ^^^^^^^^^^^
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 2495, in auto_cuda_host_compiler
    return self.cuda_windows_host_compiler()
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\rus08\Documents\yatool\build\ymake_conf.py", line 2508, in cuda_windows_host_compiler
    'Y_SDK_Version': self.build.tc.sdk_version,
                     ^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'GnuToolchainOptions' object has no attribute 'sdk_version'

Why its try to use CUDA compiler when i pass clang compiler?

this is my ya,make file:

PROGRAM(test-proj)

SRCS(
    main.cpp
)
END()

robot-piglet pushed a commit that referenced this issue Jun 14, 2024
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

No branches or pull requests

2 participants