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

Error on windows due to missing file include/doc/html/boost_asio/reference/async_result_lt__basic_yield_context_lt__Executor__gt__comma__Signature__gt_/handler_type.html #263

Open
garymm opened this issue Sep 19, 2022 · 0 comments

Comments

@garymm
Copy link
Contributor

garymm commented Sep 19, 2022

Thanks so much for this code!

I'm building on Windows using cmake from rules_foreign_cc and some boost deps.
This works on MacOS and Linux but on Windows the cmake build script tries and fails to find the file include/doc/html/boost_asio/reference/async_result_lt__basic_yield_context_lt__Executor__gt__comma__Signature__gt_/handler_type.html

Any idea why that file might be missing on Windows? Lots of other doc files are present in the parent "reference" dir.

Using rules_boost at 88ce413e61b1b549e44e3dc889251f14d4702abd.

This is my BUILD.bazel:

load("@rules_foreign_cc//foreign_cc:defs.bzl", "cmake")

config_setting(
    name = "dbg",
    values = {"compilation_mode": "dbg"},
)

cmake(
    name = "libthrift",
    generate_args = [
        "-GNinja",
        "-DBUILD_C_GLIB=OFF",
        "-DBUILD_COMPILER=OFF",
        "-DBUILD_JAVA=OFF",
        "-DBUILD_JAVASCRIPT=OFF",
        "-DBUILD_NODEJS=OFF",
        "-DBUILD_PYTHON=OFF",
        "-DBUILD_TESTING=OFF",
        "-DBUILD_TUTORIALS=OFF",
        # So we can build everything else with -Werror
        "-DCMAKE_CXX_FLAGS=-Wno-error",
    ],
    lib_source = "@com_github_apache_thrift//:allfiles",
    out_static_libs = select({
        ":dbg": ["libthriftd.a"],
        "//conditions:default": ["libthrift.a"],
    }),
    visibility = ["//visibility:public"],
    deps = [
        "@boost//:algorithm",
        "@boost//:locale",
        "@boost//:numeric_conversion",
        "@boost//:scope_exit",
        "@boost//:scoped_array",
        "@boost//:shared_array",
        "@boost//:tokenizer",
        "@boost//:version",
    ],
)

Full logs below:

bazel --windows_enable_symlinks build --verbose_failures --sandbox_debug "//third_party:libthrift"
WARNING: Running Bazel server needs to be killed, because the startup options are different.
Starting local Bazel server and connecting to it...
INFO: Analyzed target //third_party:libthrift (54 packages loaded, 15709 targets configured).
INFO: Found 1 target...
ERROR: C:/users/garymm/documents/astera-org/obelisk/third_party/BUILD.bazel:8:6: Foreign Cc - CMake: Building libthrift failed: (Exit 1): bash.exe failed: error executing command
  cd /d C:/users/garymm/_bazel_garymm/djcdc2uf/execroot/__main__
  SET PATH=C:\tools\msys64\usr\bin;C:\tools\msys64\bin;C:\Windows;C:\Windows\System32;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Users\garymm\AppData\Local\bazelisk\downloads\bazelbuild\bazel-5.3.0-windows-x86_64\bin;C:\Program Files\PowerShell\7;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files\PowerShell\7\;C:\ProgramData\chocolatey\bin;C:\tools\msys64\usr\bin;C:\Users\garymm\AppData\Local\Microsoft\WindowsApps;C:\tools\msys64;;C:\Users\garymm\AppData\Local\Programs\Microsoft VS Code\bin
    SET RUNFILES_MANIFEST_ONLY=1
  C:\tools\msys64\usr\bin\bash.exe -c bazel-out/x64_windows-fastbuild/bin/third_party/libthrift_foreign_cc/wrapper_build_script.sh
# Configuration: c1d3b9f10b5a34166b6425313af3e56198fbac70a34238482275e8491e69053f
# Execution platform: @local_config_platform//:host
rules_foreign_cc: Build failed!
rules_foreign_cc: Keeping temp build directory and dependencies directory for debug.
rules_foreign_cc: Please note that the directories inside a sandbox are still cleaned unless you specify --sandbox_debug Bazel command line flag.
rules_foreign_cc: Printing build logs:
_____ BEGIN BUILD LOGS _____

Bazel external C/C++ Rules. Building library libthrift

Environment:______________
BUILD_SCRIPT=bazel-out/x64_windows-fastbuild/bin/third_party/libthrift_foreign_cc/build_script.sh
EXT_BUILD_ROOT=C:\users\garymm\_bazel_garymm\djcdc2uf\execroot\__main__
BUILD_LOG=bazel-out/x64_windows-fastbuild/bin/third_party/libthrift_foreign_cc/CMake.log
PWD=/c/users/garymm/_bazel_garymm/djcdc2uf/execroot/__main__
MSYS_NO_PATHCONV=1
HOME=/home/garymm
BUILD_WRAPPER_SCRIPT=bazel-out/x64_windows-fastbuild/bin/third_party/libthrift_foreign_cc/wrapper_build_script.sh
EXT_BUILD_DEPS=C:\users\garymm\_bazel_garymm\djcdc2uf\execroot\__main__/bazel-out/x64_windows-fastbuild/bin/third_party/libthrift.ext_build_deps
SYSTEMROOT=C:\Windows
TERM=xterm-256color
TEMP=C:\Users\garymm\AppData\Local\Temp
BUILD_TMPDIR=C:\users\garymm\_bazel_garymm\djcdc2uf\execroot\__main__/bazel-out/x64_windows-fastbuild/bin/third_party/libthrift.build_tmpdir
INCLUDE=C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\ATLMFC\include;C:\Program 
Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\include;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\include\um;C:\Program Files (x86)\Windows Kits\10\include\10.0.20348.0\ucrt;C:\Program Files (x86)\Windows Kits\10\include\10.0.20348.0\shared;C:\Program Files (x86)\Windows Kits\10\include\10.0.20348.0\um;C:\Program Files (x86)\Windows Kits\10\include\10.0.20348.0\winrt;C:\Program Files (x86)\Windows Kits\10\include\10.0.20348.0\cppwinrt
SHLVL=2
RUNFILES_MANIFEST_ONLY=1
MSYS2_ARG_CONV_EXCL=*
INSTALLDIR=C:\users\garymm\_bazel_garymm\djcdc2uf\execroot\__main__/bazel-out/x64_windows-fastbuild/bin/third_party/libthrift
TMP=C:\Users\garymm\AppData\Local\Temp
PATH=C:\users\garymm\_bazel_garymm\djcdc2uf\execroot\__main__:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/VC/Tools/MSVC/14.29.30133/bin/HostX64/x64:/usr/bin:/bin:/c/Windows:/c/Windows/System32:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Users/garymm/AppData/Local/bazelisk/downloads/bazelbuild/bazel-5.3.0-windows-x86_64/bin:/c/Program Files/PowerShell/7:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/Program Files/PowerShell/7:/c/ProgramData/chocolatey/bin:/usr/bin:/c/Users/garymm/AppData/Local/Microsoft/WindowsApps:/:/c/Users/garymm/AppData/Local/Programs/Microsoft VS Code/bin:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/VC/Tools/MSVC/14.29.30133/bin/HostX64/x64:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/Common7/IDE/VC/VCPackages:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/Common7/IDE/CommonExtensions/Microsoft/TeamFoundation/Team Explorer:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/MSBuild/Current/bin/Roslyn:/c/Program Files (x86)/Microsoft SDKs/Windows/v10.0A/bin/NETFX 4.8 Tools/x64/:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/Common7/Tools/devinit:/c/Program Files (x86)/Windows Kits/10/bin/10.0.20348.0/x64:/c/Program Files (x86)/Windows Kits/10/bin/x64:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools//MSBuild/Current/Bin:/c/Windows/Microsoft.NET/Framework64/v4.0.30319:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/Common7/IDE/:/c/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/Common7/Tools/::/c/Windows/system32
WINDIR=C:\Windows
LIB=C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\ATLMFC\lib\x64;C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\lib\x64;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\lib\um\x64;C:\Program Files (x86)\Windows Kits\10\lib\10.0.20348.0\ucrt\x64;C:\Program Files (x86)\Windows Kits\10\lib\10.0.20348.0\um\x64
SYSTEMDRIVE=C:
_=/usr/bin/env
__________________________
ln: failed to create symbolic link 'C:\users\garymm\_bazel_garymm\djcdc2uf\execroot\__main__/bazel-out/x64_windows-fastbuild/bin/third_party/libthrift.ext_build_deps/include/doc/html/boost_asio/reference/async_result_lt__basic_yield_context_lt__Executor__gt__comma__Signature__gt_/handler_type.html': No such file or directory
_____ END BUILD LOGS _____
rules_foreign_cc: Build wrapper script location: bazel-out/x64_windows-fastbuild/bin/third_party/libthrift_foreign_cc/wrapper_build_script.sh
rules_foreign_cc: Build script location: bazel-out/x64_windows-fastbuild/bin/third_party/libthrift_foreign_cc/build_script.sh
rules_foreign_cc: Build log location: bazel-out/x64_windows-fastbuild/bin/third_party/libthrift_foreign_cc/CMake.log       

Target //third_party:libthrift failed to build
INFO: Elapsed time: 2118.494s, Critical Path: 2088.70s
INFO: 2 processes: 2 internal.
FAILED: Build did NOT complete successfully
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

1 participant