aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrobot-ya-builder <robot-ya-builder@yandex-team.com>2023-08-28 22:13:11 +0300
committerrobot-ya-builder <robot-ya-builder@yandex-team.com>2023-08-28 22:34:05 +0300
commit01a8c93d0ab16426d212c53c52909af403b1c744 (patch)
tree30836b6f7796e82df0fc902e4efab7c3bab304ba
parente2a75403713aee4d931e95115bbd9ab750c90068 (diff)
downloadydb-01a8c93d0ab16426d212c53c52909af403b1c744.tar.gz
External build system generator release 48
Update tools: yexport
-rw-r--r--build/external_resources/yexport/resources.json2
-rw-r--r--cmake/llvm-tools.cmake79
2 files changed, 46 insertions, 35 deletions
diff --git a/build/external_resources/yexport/resources.json b/build/external_resources/yexport/resources.json
index 4c31cc0536c..60a827abd65 100644
--- a/build/external_resources/yexport/resources.json
+++ b/build/external_resources/yexport/resources.json
@@ -1,7 +1,7 @@
{
"by_platform": {
"linux": {
- "uri": "sbr:4915831389"
+ "uri": "sbr:4991330576"
}
}
}
diff --git a/cmake/llvm-tools.cmake b/cmake/llvm-tools.cmake
index 34017bcdd66..83276f3dde2 100644
--- a/cmake/llvm-tools.cmake
+++ b/cmake/llvm-tools.cmake
@@ -1,45 +1,56 @@
-if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
- set(CLANGPLUSPLUS ${CMAKE_CXX_COMPILER})
- message(STATUS "Using ${CLANGPLUSPLUS} for c++ to LLVM IR translation")
+if (REQUIRED_LLVM_TOOLING_VERSION)
+ if (CMAKE_VERSION VERSION_LESS 3.18)
+ message(FATAL_ERROR "Forcing LLVM tooling versions requires at least cmake 3.18")
+ endif()
+ find_program(CLANGPLUSPLUS clang++-${REQUIRED_LLVM_TOOLING_VERSION} REQUIRED)
+ find_program(CLANGC clang-${REQUIRED_LLVM_TOOLING_VERSION} REQUIRED)
+ find_program(LLVMLINK llvm-link-${REQUIRED_LLVM_TOOLING_VERSION} REQUIRED)
+ find_program(LLVMOPT opt-${REQUIRED_LLVM_TOOLING_VERSION} REQUIRED)
+ find_program(LLVMLLC llc-${REQUIRED_LLVM_TOOLING_VERSION} REQUIRED)
else()
- find_program(CLANGPLUSPLUS NAMES clang++-12 clang++-14 clang++)
- if (CLANGPLUSPLUS MATCHES "CLANGPLUSPLUS-NOTFOUND")
- message(SEND_ERROR "clang++ not found")
- else()
+ if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+ set(CLANGPLUSPLUS ${CMAKE_CXX_COMPILER})
message(STATUS "Using ${CLANGPLUSPLUS} for c++ to LLVM IR translation")
+ else()
+ find_program(CLANGPLUSPLUS NAMES clang++-12 clang++-14 clang++)
+ if (CLANGPLUSPLUS MATCHES "CLANGPLUSPLUS-NOTFOUND")
+ message(SEND_ERROR "clang++ not found")
+ else()
+ message(STATUS "Using ${CLANGPLUSPLUS} for c++ to LLVM IR translation")
+ endif()
endif()
-endif()
-if (CMAKE_C_COMPILER_ID MATCHES "Clang")
- set(CLANGC ${CMAKE_C_COMPILER})
- message(STATUS "Using ${CLANGC} for c++ to LLVM IR translation")
-else()
- find_program(CLANGC NAMES clang-12 clang-14 clang)
- if (CLANGC MATCHES "CLANGC-NOTFOUND")
- message(SEND_ERROR "clang not found")
+ if (CMAKE_C_COMPILER_ID MATCHES "Clang")
+ set(CLANGC ${CMAKE_C_COMPILER})
+ message(STATUS "Using ${CLANGC} for c++ to LLVM IR translation")
else()
- message(STATUS "Using ${CLANGC} for c to LLVM IR translation")
+ find_program(CLANGC NAMES clang-12 clang-14 clang)
+ if (CLANGC MATCHES "CLANGC-NOTFOUND")
+ message(SEND_ERROR "clang not found")
+ else()
+ message(STATUS "Using ${CLANGC} for c to LLVM IR translation")
+ endif()
endif()
-endif()
-find_program(LLVMLINK NAMES llvm-link-12 llvm-link-14 llvm-link)
-if (LLVMLINK MATCHES "LLVMLINK-NOTFOUND")
- message(SEND_ERROR "llvm-link not found")
-else()
- message(STATUS "Using ${LLVMLINK} for LLVM IR linking")
-endif()
-find_program(LLVMOPT NAMES opt-12 opt-14 opt)
-if (LLVMOPT MATCHES "LLVMOPT-NOTFOUND")
- message(SEND_ERROR "llvm opt tool not found")
-else()
- message(STATUS "Using ${LLVMOPT} for LLVM IR optimization")
-endif()
+ find_program(LLVMLINK NAMES llvm-link-12 llvm-link-14 llvm-link)
+ if (LLVMLINK MATCHES "LLVMLINK-NOTFOUND")
+ message(SEND_ERROR "llvm-link not found")
+ else()
+ message(STATUS "Using ${LLVMLINK} for LLVM IR linking")
+ endif()
+ find_program(LLVMOPT NAMES opt-12 opt-14 opt)
+ if (LLVMOPT MATCHES "LLVMOPT-NOTFOUND")
+ message(SEND_ERROR "llvm opt tool not found")
+ else()
+ message(STATUS "Using ${LLVMOPT} for LLVM IR optimization")
+ endif()
-find_program(LLVMLLC NAMES llc-12 llc-14 llc)
-if (LLVMLLC MATCHES "LLVMLLC-NOTFOUND")
- message(SEND_ERROR "llvm llc tool not found")
-else()
- message(STATUS "Using ${LLVMLLC} for LLVM IR to binary code compilation")
+ find_program(LLVMLLC NAMES llc-12 llc-14 llc)
+ if (LLVMLLC MATCHES "LLVMLLC-NOTFOUND")
+ message(SEND_ERROR "llvm llc tool not found")
+ else()
+ message(STATUS "Using ${LLVMLLC} for LLVM IR to binary code compilation")
+ endif()
endif()
function(llvm_compile_cxx Tgt Inpt Out Tool UseC)