mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-05 12:38:09 -07:00
dev-util/clazy: move clazy script
Putting the clazy script into CMAKE_RUNTIME_OUTPUT_DIRECTORY gets it covered by the already set PATH. Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
@@ -43,6 +43,7 @@ PATCHES=(
|
||||
"${FILESDIR}"/${P}-LIBRARY_DIRS.patch
|
||||
"${FILESDIR}"/${P}-INCLUDE_DIRS.patch
|
||||
"${FILESDIR}"/${P}-standalone-install-location.patch
|
||||
"${FILESDIR}"/${P}-clazy-install-location.patch
|
||||
)
|
||||
|
||||
pkg_setup() {
|
||||
@@ -78,10 +79,10 @@ src_test() {
|
||||
|
||||
# Run tests against built copy, not installed
|
||||
# bug #811723
|
||||
local -x PATH="${BUILD_DIR}/${LLVM_ROOT}/bin:${BUILD_DIR}/bin:${BUILD_DIR}:${PATH}"
|
||||
local -x PATH="${BUILD_DIR}/${LLVM_ROOT}/bin:${BUILD_DIR}/bin:${PATH}"
|
||||
local -x LD_LIBRARY_PATH="${BUILD_DIR}/lib"
|
||||
|
||||
chmod +x "${BUILD_DIR}"/clazy || die
|
||||
chmod +x "${BUILD_DIR}/bin/clazy" || die
|
||||
|
||||
cmake_src_test
|
||||
}
|
||||
|
||||
25
dev-util/clazy/files/clazy-1.12-clazy-install-location.patch
Normal file
25
dev-util/clazy/files/clazy-1.12-clazy-install-location.patch
Normal file
@@ -0,0 +1,25 @@
|
||||
From b5600e28b0720a9a43d20717e79ba26dae6b9359 Mon Sep 17 00:00:00 2001
|
||||
From: Paul Zander <negril.nx+gentoo@gmail.com>
|
||||
Date: Sun, 10 Nov 2024 22:22:07 +0100
|
||||
Subject: [PATCH] move clazy script to CMAKE_RUNTIME_OUTPUT_DIRECTORY
|
||||
|
||||
Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com>
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 765083c..c7c1cea 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -229,8 +229,8 @@ if (NOT CLAZY_BUILD_WITH_CLANG)
|
||||
endif()
|
||||
file(RELATIVE_PATH BIN_RELATIVE_LIBDIR "${CMAKE_INSTALL_FULL_BINDIR}" "${CMAKE_INSTALL_FULL_LIBDIR}")
|
||||
file(RELATIVE_PATH BIN_RELATIVE_SHAREDIR "${CMAKE_INSTALL_FULL_BINDIR}" "${CMAKE_INSTALL_FULL_DATAROOTDIR}")
|
||||
- configure_file(${CMAKE_CURRENT_LIST_DIR}/clazy.cmake ${CMAKE_BINARY_DIR}/clazy @ONLY)
|
||||
- install(PROGRAMS ${CMAKE_BINARY_DIR}/clazy DESTINATION bin)
|
||||
+ configure_file(${CMAKE_CURRENT_LIST_DIR}/clazy.cmake ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/clazy @ONLY)
|
||||
+ install(PROGRAMS ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/clazy DESTINATION bin)
|
||||
else()
|
||||
install(PROGRAMS ${CMAKE_CURRENT_LIST_DIR}/clazy.bat DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
if(MSVC)
|
||||
--
|
||||
2.47.0
|
||||
|
||||
Reference in New Issue
Block a user