facebookresearch / CompilerGym

Reinforcement learning environments for compiler and program optimization tasks
https://compilergym.ai/
MIT License
879 stars 123 forks source link

I use cmake to build from source, but I met the problem below. How can I solve it ? #802

Closed sunpeng2020 closed 1 year ago

sunpeng2020 commented 1 year ago

🐛 Bug

I used cmake to build from source, but I met the problem below. How can I solve it ?

To Reproduce

Steps to reproduce the behavior:

1.cd CompilerGym/build 2.cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -S ../ -B ./

error messages: '/home/data2/sp/.local/bin/cmake' '-G' 'Ninja' '-C' '/home/data2/sp/CompilerGym/build/external/boost/boost_initial_cache.cmake' '-S' '/home/data2/sp/CompilerGym/external/boost' '-B' '/home/data2/sp/CompilerGym/build/external/boost' '-D' 'CMAKE_INSTALL_PREFIX=/home/data2/sp/CompilerGym/build/external/boost/install' loading initial cache file /home/data2/sp/CompilerGym/build/external/boost/boost_initial_cache.cmake '/usr/bin/git' '--version' '/usr/sbin/sysctl' '-n' 'hw.ncpu' '/usr/bin/nproc' -- Configuring done -- Generating done -- Build files have been written to: /home/data2/sp/CompilerGym/build/external/boost '/home/data2/sp/.local/bin/cmake' '--build' '/home/data2/sp/CompilerGym/build/external/boost' [1/7] Performing download step (git clone) for 'boost' FAILED: boost/src/boost-stamp/boost-download cd /home/data2/sp/CompilerGym/build/external/boost/boost/src && /home/data2/sp/.local/bin/cmake -P /home/data2/sp/CompilerGym/build/external/boost/boost/tmp/boost-gitclone.cmake && /home/data2/sp/.local/bin/cmake -E touch /home/data2/sp/CompilerGym/build/external/boost/boost/src/boost-stamp/boost-download Cloning into 'boost'... error: RPC failed; curl 56 GnuTLS recv error (-54): Error in the pull function. fatal: the remote end hung up unexpectedly fatal: early EOF fatal: index-pack failed Cloning into 'boost'... fatal: unable to access 'https://github.com/boostorg/boost.git/': GnuTLS recv error (-54): Error in the pull function. Cloning into 'boost'... fatal: unable to access 'https://github.com/boostorg/boost.git/': GnuTLS recv error (-110): The TLS connection was non-properly terminated. -- Had to git clone more than once: 3 times. CMake Error at /home/data2/sp/CompilerGym/build/external/boost/boost/tmp/boost-gitclone.cmake:31 (message): Failed to clone repository: 'https://github.com/boostorg/boost.git'

ninja: build stopped: subcommand failed. CMake Error at build_tools/cmake/build_external_cmake_project.cmake:37 (execute_process): execute_process failed command indexes:

1: "Child return code: 1"

Call Stack (most recent call first): external/external.cmake:386 (build_external_cmake_project) CMakeLists.txt:86 (include)

-- Configuring incomplete, errors occurred! See also "/home/data2/sp/CompilerGym/build/CMakeFiles/CMakeOutput.log". See also "/home/data2/sp/CompilerGym/build/CMakeFiles/CMakeError.log".

Expected behavior

Environment

Please fill in this checklist:

wget https://raw.githubusercontent.com/facebookresearch/CompilerGym/stable/build_tools/collect_env.py
# For security purposes, please check the contents of collect_env.py before running it.
python collect_env.py

Additional context

ChrisCummins commented 1 year ago

Were you able to fix this issue?

sunpeng2020 commented 1 year ago

yes. I have solved it. I download the boost source code and put it into the project.