mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-23 12:10:06 +02:00
bear: bump version
This commit is contained in:
@@ -1,58 +0,0 @@
|
||||
SUMMARY="Automatically generate compilation database for Clang tooling"
|
||||
DESCRIPTION="Bear records the flags passed to the compiler for each translation unit and \
|
||||
stores them in a JSON file. This file can be used by Clang's tooling interface \
|
||||
and programs like clang-check to process a translation unit.\
|
||||
\
|
||||
cmake supports the generation of JSON compilation databases out of the box. \
|
||||
For any other build system that does not support this, Bear can be used \
|
||||
instead to intercept the invocation of the compiler."
|
||||
HOMEPAGE="https://github.com/rizsotto/Bear"
|
||||
COPYRIGHT="2012-2019 by László Nagy"
|
||||
LICENSE="GNU GPL v3"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/rizsotto/Bear/archive/$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="e80c0d622a8192a1ec0c0efa139e5767c6c4b1defe1c75fc99cf680c6d1816c0"
|
||||
SOURCE_DIR="Bear-$portVersion"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2 ?x86 ?arm"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
bear$secondaryArchSuffix = $portVersion
|
||||
cmd:bear = $portVersion compat >= 3
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:python2
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
"
|
||||
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:cmake
|
||||
cmd:g++
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:python2
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
cmake . -DCMAKE_INSTALL_PREFIX=$prefix \
|
||||
-DCMAKE_BUILD_TYPE=Release
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
mkdir -vp $manDir
|
||||
cp -vrd $prefix/share/man/man1 $manDir
|
||||
|
||||
mkdir -p $dataDir
|
||||
mv -v $prefix/share $dataDir
|
||||
}
|
||||
111
dev-util/bear/bear-3.0.16.recipe
Normal file
111
dev-util/bear/bear-3.0.16.recipe
Normal file
@@ -0,0 +1,111 @@
|
||||
SUMMARY="Automatically generate compilation database for Clang tooling"
|
||||
DESCRIPTION="Bear records the flags passed to the compiler for each translation unit and \
|
||||
stores them in a JSON file. This file can be used by Clang's tooling interface \
|
||||
and programs like clang-check to process a translation unit.\
|
||||
\
|
||||
cmake supports the generation of JSON compilation databases out of the box. \
|
||||
For any other build system that does not support this, Bear can be used \
|
||||
instead to intercept the invocation of the compiler."
|
||||
HOMEPAGE="https://github.com/rizsotto/Bear"
|
||||
COPYRIGHT="2012-2021 by László Nagy"
|
||||
LICENSE="GNU GPL v3"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/rizsotto/Bear/archive/$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="877ee5e89e8445f74df95f2f3896597f04b86a4e5d0dbbca07ac71027dcb362d"
|
||||
SOURCE_DIR="Bear-$portVersion"
|
||||
PATCHES="bear-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="?x86"
|
||||
|
||||
PROVIDES="
|
||||
bear$secondaryArchSuffix = $portVersion
|
||||
cmd:bear = $portVersion compat >= 3
|
||||
cmd:citnames = $portVersion compat >= 3
|
||||
cmd:intercept = $portVersion compat >= 3
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:python2
|
||||
lib:libabsl_bad_optional_access$secondaryArchSuffix
|
||||
lib:libabsl_bad_variant_access$secondaryArchSuffix
|
||||
lib:libabsl_base$secondaryArchSuffix
|
||||
lib:libabsl_city$secondaryArchSuffix
|
||||
lib:libabsl_civil_time$secondaryArchSuffix
|
||||
lib:libabsl_cord$secondaryArchSuffix
|
||||
lib:libabsl_debugging_internal$secondaryArchSuffix
|
||||
lib:libabsl_demangle_internal$secondaryArchSuffix
|
||||
lib:libabsl_exponential_biased$secondaryArchSuffix
|
||||
lib:libabsl_graphcycles_internal$secondaryArchSuffix
|
||||
lib:libabsl_hash$secondaryArchSuffix
|
||||
lib:libabsl_hashtablez_sampler$secondaryArchSuffix
|
||||
lib:libabsl_int128$secondaryArchSuffix
|
||||
lib:libabsl_log_severity$secondaryArchSuffix
|
||||
lib:libabsl_malloc_internal$secondaryArchSuffix
|
||||
lib:libabsl_raw_hash_set$secondaryArchSuffix
|
||||
lib:libabsl_raw_logging_internal$secondaryArchSuffix
|
||||
lib:libabsl_spinlock_wait$secondaryArchSuffix
|
||||
lib:libabsl_stacktrace$secondaryArchSuffix
|
||||
lib:libabsl_status$secondaryArchSuffix
|
||||
lib:libabsl_statusor$secondaryArchSuffix
|
||||
lib:libabsl_strings$secondaryArchSuffix
|
||||
lib:libabsl_strings_internal$secondaryArchSuffix
|
||||
lib:libabsl_str_format_internal$secondaryArchSuffix
|
||||
lib:libabsl_symbolize$secondaryArchSuffix
|
||||
lib:libabsl_synchronization$secondaryArchSuffix
|
||||
lib:libabsl_throw_delegate$secondaryArchSuffix
|
||||
lib:libabsl_time$secondaryArchSuffix
|
||||
lib:libabsl_time_zone$secondaryArchSuffix
|
||||
lib:libabsl_wyhash$secondaryArchSuffix
|
||||
lib:libaddress_sorting$secondaryArchSuffix
|
||||
lib:libcares$secondaryArchSuffix
|
||||
lib:libcrypto$secondaryArchSuffix
|
||||
lib:libfmt$secondaryArchSuffix
|
||||
lib:libgpr$secondaryArchSuffix
|
||||
lib:libgrpc++$secondaryArchSuffix
|
||||
lib:libgrpc$secondaryArchSuffix
|
||||
lib:libprotobuf$secondaryArchSuffix
|
||||
lib:libre2$secondaryArchSuffix
|
||||
lib:libspdlog$secondaryArchSuffix
|
||||
lib:libssl$secondaryArchSuffix
|
||||
lib:libupb$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libfmt$secondaryArchSuffix
|
||||
devel:libgrpc$secondaryArchSuffix
|
||||
devel:libgtest$secondaryArchSuffix
|
||||
devel:libspdlog$secondaryArchSuffix
|
||||
devel:nlohmann_json$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:cmake
|
||||
cmd:g++$secondaryArchSuffix
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python2
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
cmake -B build -S . -DCMAKE_INSTALL_PREFIX=$prefix \
|
||||
-DCMAKE_BUILD_TYPE=Release
|
||||
unset -f cmake
|
||||
cmake --build build $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
unset -f cmake
|
||||
cmake --install build
|
||||
|
||||
mkdir -vp $manDir
|
||||
cp -vrd $prefix/share/man/man1 $manDir
|
||||
|
||||
mkdir -p $dataDir
|
||||
mv -v $prefix/share $dataDir
|
||||
}
|
||||
173
dev-util/bear/patches/bear-3.0.16.patchset
Normal file
173
dev-util/bear/patches/bear-3.0.16.patchset
Normal file
@@ -0,0 +1,173 @@
|
||||
From 057a70653e3fb8f3652b7248fa9fcc25ccb67daa Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Mon, 18 Oct 2021 11:19:05 +0200
|
||||
Subject: protobuf search path
|
||||
|
||||
|
||||
diff --git a/source/intercept/proto/CMakeLists.txt b/source/intercept/proto/CMakeLists.txt
|
||||
index e4fb8c1..8bbd58c 100644
|
||||
--- a/source/intercept/proto/CMakeLists.txt
|
||||
+++ b/source/intercept/proto/CMakeLists.txt
|
||||
@@ -11,6 +11,7 @@ add_custom_command(
|
||||
${_PROTOBUF_PROTOC}
|
||||
ARGS
|
||||
-I "${SUPERVISE_PROTO_PATH}"
|
||||
+ -I "/system/develop/headers"
|
||||
--grpc_out "${CMAKE_CURRENT_BINARY_DIR}"
|
||||
--cpp_out "${CMAKE_CURRENT_BINARY_DIR}"
|
||||
--plugin=protoc-gen-grpc="${_GRPC_CPP_PLUGIN_EXECUTABLE}"
|
||||
@@ -34,6 +35,7 @@ add_custom_command(
|
||||
${_PROTOBUF_PROTOC}
|
||||
ARGS
|
||||
-I "${SUPERVISE_PROTO_PATH}"
|
||||
+ -I "/system/develop/headers"
|
||||
--grpc_out "${CMAKE_CURRENT_BINARY_DIR}"
|
||||
--cpp_out "${CMAKE_CURRENT_BINARY_DIR}"
|
||||
--plugin=protoc-gen-grpc="${_GRPC_CPP_PLUGIN_EXECUTABLE}"
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From 0b60677308b8f180f435a448e86f86f684b756e1 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Mon, 18 Oct 2021 15:22:06 +0200
|
||||
Subject: link against stdc++fs
|
||||
|
||||
workaround gtest with Haiku error definition
|
||||
|
||||
diff --git a/source/bear/CMakeLists.txt b/source/bear/CMakeLists.txt
|
||||
index 376a003..cbcdc35 100644
|
||||
--- a/source/bear/CMakeLists.txt
|
||||
+++ b/source/bear/CMakeLists.txt
|
||||
@@ -7,7 +7,8 @@ target_link_libraries(bear
|
||||
sys_a
|
||||
flags_a
|
||||
fmt::fmt
|
||||
- spdlog::spdlog)
|
||||
+ spdlog::spdlog
|
||||
+ stdc++fs)
|
||||
|
||||
include(GNUInstallDirs)
|
||||
install(TARGETS bear
|
||||
diff --git a/source/citnames/CMakeLists.txt b/source/citnames/CMakeLists.txt
|
||||
index dc9d5f3..7de5477 100644
|
||||
--- a/source/citnames/CMakeLists.txt
|
||||
+++ b/source/citnames/CMakeLists.txt
|
||||
@@ -52,7 +52,8 @@ add_executable(citnames
|
||||
)
|
||||
target_link_libraries(citnames
|
||||
citnames_a
|
||||
- citnames_json_a)
|
||||
+ citnames_json_a
|
||||
+ stdc++fs)
|
||||
|
||||
include(GNUInstallDirs)
|
||||
install(TARGETS citnames
|
||||
@@ -82,6 +83,7 @@ if (ENABLE_UNIT_TESTS)
|
||||
target_link_libraries(citnames_unit_test citnames_a)
|
||||
target_link_libraries(citnames_unit_test citnames_json_a)
|
||||
target_link_libraries(citnames_unit_test PkgConfig::GTest ${CMAKE_THREAD_LIBS_INIT})
|
||||
+ target_link_libraries(citnames_unit_test stdc++fs)
|
||||
|
||||
add_test(NAME bear::citnames_unit_test COMMAND $<TARGET_FILE:citnames_unit_test>)
|
||||
endif ()
|
||||
diff --git a/source/intercept/CMakeLists.txt b/source/intercept/CMakeLists.txt
|
||||
index e9598c0..62b741d 100644
|
||||
--- a/source/intercept/CMakeLists.txt
|
||||
+++ b/source/intercept/CMakeLists.txt
|
||||
@@ -59,7 +59,8 @@ add_executable(intercept
|
||||
source/collect/main.cc)
|
||||
target_link_libraries(intercept
|
||||
main_a
|
||||
- intercept_a)
|
||||
+ intercept_a
|
||||
+ stdc++fs)
|
||||
|
||||
install(TARGETS intercept
|
||||
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
@@ -103,7 +104,8 @@ add_executable(wrapper
|
||||
target_include_directories(wrapper PUBLIC source/)
|
||||
target_link_libraries(wrapper
|
||||
main_a
|
||||
- wrapper_a)
|
||||
+ wrapper_a
|
||||
+ stdc++fs)
|
||||
|
||||
install(TARGETS wrapper
|
||||
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}/bear)
|
||||
@@ -202,6 +204,8 @@ if (ENABLE_UNIT_TESTS)
|
||||
target_include_directories(exec_unit_test PRIVATE test)
|
||||
target_link_libraries(exec_unit_test exec_a)
|
||||
target_link_libraries(exec_unit_test PkgConfig::GTest ${CMAKE_THREAD_LIBS_INIT})
|
||||
+ target_link_libraries(exec_unit_test stdc++fs)
|
||||
+
|
||||
|
||||
add_test(NAME bear::exec_unit_test COMMAND $<TARGET_FILE:exec_unit_test>)
|
||||
|
||||
@@ -212,6 +216,7 @@ if (ENABLE_UNIT_TESTS)
|
||||
target_link_libraries(intercept_unit_test intercept_a)
|
||||
target_link_libraries(intercept_unit_test wrapper_a)
|
||||
target_link_libraries(intercept_unit_test PkgConfig::GTest ${CMAKE_THREAD_LIBS_INIT})
|
||||
+ target_link_libraries(intercept_unit_test stdc++fs)
|
||||
|
||||
add_test(NAME bear::intercept_unit_test COMMAND $<TARGET_FILE:intercept_unit_test>)
|
||||
endif ()
|
||||
diff --git a/source/libsys/CMakeLists.txt b/source/libsys/CMakeLists.txt
|
||||
index a285dd1..0c40b3e 100644
|
||||
--- a/source/libsys/CMakeLists.txt
|
||||
+++ b/source/libsys/CMakeLists.txt
|
||||
@@ -28,6 +28,7 @@ if (ENABLE_UNIT_TESTS)
|
||||
target_include_directories(sys_unit_test PRIVATE source/)
|
||||
target_link_libraries(sys_unit_test sys_a)
|
||||
target_link_libraries(sys_unit_test PkgConfig::GTest ${CMAKE_THREAD_LIBS_INIT})
|
||||
+ target_link_libraries(sys_unit_test stdc++fs)
|
||||
|
||||
add_test(NAME bear::sys_unit_test COMMAND $<TARGET_FILE:sys_unit_test>)
|
||||
endif ()
|
||||
diff --git a/source/libsys/test/ErrorsTest.cc b/source/libsys/test/ErrorsTest.cc
|
||||
index 0ead223..9360cef 100644
|
||||
--- a/source/libsys/test/ErrorsTest.cc
|
||||
+++ b/source/libsys/test/ErrorsTest.cc
|
||||
@@ -23,6 +23,9 @@
|
||||
|
||||
#include <cerrno>
|
||||
|
||||
+#undef ENOENT
|
||||
+#define ENOENT 0x80006003
|
||||
+
|
||||
namespace {
|
||||
|
||||
TEST(errors, ENOENT)
|
||||
@@ -31,4 +34,4 @@ namespace {
|
||||
|
||||
EXPECT_STREQ("No such file or directory", result.data());
|
||||
}
|
||||
-}
|
||||
\ No newline at end of file
|
||||
+}
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From c6151731473c81d2727a48a59017147aa5d8cda2 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Mon, 18 Oct 2021 18:03:47 +0200
|
||||
Subject: Haiku: use libroot as libc name
|
||||
|
||||
|
||||
diff --git a/source/libsys/CMakeLists.txt b/source/libsys/CMakeLists.txt
|
||||
index 0c40b3e..81832bf 100644
|
||||
--- a/source/libsys/CMakeLists.txt
|
||||
+++ b/source/libsys/CMakeLists.txt
|
||||
@@ -50,6 +50,8 @@ if (SUPPORT_PRELOAD AND NOT HAVE_GNU_LIB_NAMES_H)
|
||||
)
|
||||
# cmake_path(GET LIBC_SO_PATH FILENAME LIBC_SO)
|
||||
get_filename_component(LIBC_SO ${LIBC_SO_PATH} NAME)
|
||||
+ elseif (HAIKU)
|
||||
+ set(LIBC_SO "libroot.so")
|
||||
else()
|
||||
set(LIBC_SO "libc.so")
|
||||
endif()
|
||||
--
|
||||
2.30.2
|
||||
|
||||
Reference in New Issue
Block a user