summaryrefslogtreecommitdiff
path: root/sys-cluster/ceph
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-06-03 03:30:15 +0100
committerV3n3RiX <venerix@koprulu.sector>2023-06-03 03:30:15 +0100
commiteaef2dddc42323859c2525b466b380620534c051 (patch)
tree896c21252a915d64254052580cbe09065160d988 /sys-cluster/ceph
parentabccc7eb204f4c89c47a45acfe0db1cc337585ff (diff)
gentoo auto-resync : 03:06:2023 - 03:30:15
Diffstat (limited to 'sys-cluster/ceph')
-rw-r--r--sys-cluster/ceph/Manifest2
-rw-r--r--sys-cluster/ceph/ceph-17.2.6-r3.ebuild487
-rw-r--r--sys-cluster/ceph/files/ceph-17.2.6-arrow-flatbuffers-c++14.patch92
3 files changed, 581 insertions, 0 deletions
diff --git a/sys-cluster/ceph/Manifest b/sys-cluster/ceph/Manifest
index e41342b4b2fa..c5a79f1a74db 100644
--- a/sys-cluster/ceph/Manifest
+++ b/sys-cluster/ceph/Manifest
@@ -31,6 +31,7 @@ AUX ceph-17.2.5-gcc13-deux.patch 2775 BLAKE2B 9ff9a80a87417206099490d47027df0d75
AUX ceph-17.2.5-gcc13.patch 2917 BLAKE2B 9c41c0490932fc1f28bb647f7911189cf440517673c98b09c50a86467cd4478d11067a14ea57b10113e67e7772525cbee525e2855261322ff9e8cbd47a3268c5 SHA512 a0c720e624cef883c0360d043a4c3d49a4dfca2f0e4b3f73da9318615a3a5ff506baa133a140403b9a90fc87bddb6fbe58691f629f1cb689a21b732855343b44
AUX ceph-17.2.5-link-boost-context.patch 492 BLAKE2B 828665f353890d92b586928421d6eee837a095c371e458d166cf6c6e9663b5ca9f71f74961c3db8731e042c31153f766457813fbcc50114631bb569a15f683f8 SHA512 b794685a7b6fc36267ea668232e12cd480b307f207dbbeafdbc874147925c24bc5497b7056106f2c1feea197835856aaaaeec399fe53f76fc274dc03c9d69a5d
AUX ceph-17.2.5-suppress-cmake-warning.patch 370 BLAKE2B 225ee73ddc24e3b398243603292949da09417c4c928daf0328729d8a69a475e6e5cdd2c9911c4c2ff6f3a6fea8b785a210e4beab5dc7bd910e390e84aa8e4b61 SHA512 e71ead89e494ac5639c08764b4d7bc3a96f87bac4ea8f9adb3e29c568f5d970551bc568c55adfd1b21be575db39a6f494de3e9d091d4ae8c04d2d5421be24f4f
+AUX ceph-17.2.6-arrow-flatbuffers-c++14.patch 3905 BLAKE2B 89e1860ff9be4ae899d99f71986a6616636dd8f5c6e1e06fdb2f5500cf86eb374b65f0364b4ca23e3c933ce3f705a0c0b6125bac77b4d66cb76ee1b4a289ba43 SHA512 8be91877d6d6f64b385e8a3914be761ecff8fb6575480e054aa738b036eace86a4dc923b3de6f554925bde55e95b2a26fd6bb2bf6ec552b12db0801600e50a60
AUX ceph-17.2.6-link-boost-context.patch 522 BLAKE2B 7f50f179324d74a372a038cb183297f9ecac7095a71a810d0d8063d2f80c31013db029e0067ab3b689faa1d4967ed04e077f279a203414e3ce49ddbc6b552e2c SHA512 3b15869a5e9bddbec752f3f612c4c53bf95c8da21a573b92af90f0f9823dddcdeaffef850c2d84bb4ee8bde8ce30a92e0f911c0e9e9007fb44aa8279b5cbec5e
AUX ceph-mds_at.service 282 BLAKE2B 3a51e5d5e0490c021282a37961824d650891c2d84c077c6479a9ee733f8a16fbe65cf204aa74e30ddd24dc01f32740037a6bd137a40464d57e1afeba5a49f893 SHA512 3a37e187f925e1a5fb672ac90937f544f3b98ed5a30b6a6b931a600f9d6a245373085ed61b40e0c64b30dbfac51dd99cbeaeb7538b5f23953bc0dde1df94742d
AUX ceph-mds_at.service.conf 115 BLAKE2B aaaa28074bf47ee98272337b536e6ca89dbbbb0443d7774c38f62da4b210a5b2ffbb53fa2b7f20dffbee08206a0868e33d381a89b613a25b88f897dd32753fd5 SHA512 e0b51882ec864271a6468141fdd185e24cafcd677f312a7658880a30c00fd58d9043b2651548ab23bd01e54be248a1e8c03545a8fda0b699ca051de7ceb925d8
@@ -52,4 +53,5 @@ DIST ceph-xsimd-17.2.6.tar.gz 173025 BLAKE2B 54679c24804c195ae55b9f49589e331dde9
EBUILD ceph-16.2.13.ebuild 12486 BLAKE2B d02ddb432b12e9dea0f7244235dbe6c9232404a6743b6e6222e8d70998ef413ef4a68e453063a15538666dc84895d63f04cfa79c40f9686af5a7f7c25ab3b336 SHA512 fa654d708ff451db30fdebbb4733be6d31c50d962b324986e7272e20a0e136b006749f679dd573d70043c37fa40ec31445fb8ad4301f67cfd260fca26d76e2e3
EBUILD ceph-17.2.5-r6.ebuild 13085 BLAKE2B 7c537acc8ad2a8b8b870b75c097c55a5b42f0fd0273d212092d0ac96e9ba783db89b62372edd1cafb65ab449803753abb68c82da00bc49337d5a2cc9500718f8 SHA512 bfb52a492f873c986834b02d9804981389377d7df51d25103fed1adeb92956d2a81508fcc25f72e4c0eeda81a2af37265120d546e6f8dcca54814fd0367e469b
EBUILD ceph-17.2.6-r2.ebuild 13094 BLAKE2B 9a85e922be0a649fe63723b7621abeacb9148da733c1f0d7b076d96fca1672f2a0742cccf01101d5331d730e23d2b29c41a704fc877329ec7076cea398b2cc15 SHA512 2f5385a1373ad6e4383e69e6c2598ec28e45811b839d3ba1a248b9f8ac9f62b4c17e61ef0c6eec6b4c272be46c8be17d23dd85e9198ec9f12f630ce98876a800
+EBUILD ceph-17.2.6-r3.ebuild 13532 BLAKE2B b64e17d8c01a0d7f17ec72fe23b7b9b25edb5c10be8f469218812bf23daba84893edada6b6835bc0604b73793fd17bfb6e6ae31bf7b63e9a97809296477870ac SHA512 cbf2b278f64da51333fc660ac1dc6d791afb9e9655b1020a0bcb7d7802dcfca1d2002d39abf45e4730f8131c69728b8bc91ff505a690471f053a3f9733d48bf4
MISC metadata.xml 2504 BLAKE2B df35722094ef7fbc1ecd16d3784e8589958a8d4e2f915e84f41e6ce5191256697a73eb9d3d658089afaaa82a5b23bdf7097870a15e43029d2598bb1792a4b571 SHA512 b0c03c35876eccf78360914237fdef8925963b21f78fd8516e8506150cce36a901562e33e6fab102dd5a4e727f9a4422eb136e5b64d46b9538fb4450b3467b2b
diff --git a/sys-cluster/ceph/ceph-17.2.6-r3.ebuild b/sys-cluster/ceph/ceph-17.2.6-r3.ebuild
new file mode 100644
index 000000000000..259638cf91a1
--- /dev/null
+++ b/sys-cluster/ceph/ceph-17.2.6-r3.ebuild
@@ -0,0 +1,487 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{9..11} )
+LUA_COMPAT=( lua5-{3..4} )
+
+inherit check-reqs bash-completion-r1 cmake flag-o-matic lua-single \
+ python-r1 udev readme.gentoo-r1 toolchain-funcs systemd tmpfiles
+
+XSIMD_HASH="aeec9c872c8b475dedd7781336710f2dd2666cb2"
+SRC_URI="
+ https://download.ceph.com/tarballs/${P}.tar.gz
+ parquet? ( https://github.com/xtensor-stack/xsimd/archive/${XSIMD_HASH}.tar.gz -> ceph-xsimd-${PV}.tar.gz )
+"
+KEYWORDS="~amd64 ~arm64"
+
+DESCRIPTION="Ceph distributed filesystem"
+HOMEPAGE="https://ceph.com/"
+
+LICENSE="Apache-2.0 LGPL-2.1 CC-BY-SA-3.0 GPL-2 GPL-2+ LGPL-2+ LGPL-2.1 LGPL-3 GPL-3 BSD Boost-1.0 MIT public-domain"
+SLOT="0"
+
+CPU_FLAGS_X86=(avx2 avx512f pclmul sse{,2,3,4_1,4_2} ssse3)
+
+IUSE="
+ babeltrace +cephfs custom-cflags diskprediction dpdk fuse grafana
+ jemalloc jaeger kafka kerberos ldap lttng +mgr +parquet pmdk rabbitmq
+ +radosgw rbd-rwl rbd-ssd rdma rgw-lua +ssl spdk +sqlite +system-boost
+ systemd +tcmalloc test +uring xfs zbd zfs
+"
+
+IUSE+="$(printf "cpu_flags_x86_%s\n" ${CPU_FLAGS_X86[@]})"
+
+# <dev-libs/libfmt-10 because we're using -DFMT_DEPRECATED_OSTREAM for bug #895254
+# See https://github.com/ceph/ceph/pull/49768 for a fix for newer versions.
+DEPEND="
+ ${LUA_DEPS}
+ ${PYTHON_DEPS}
+ acct-group/ceph
+ acct-user/ceph
+ virtual/libudev:=
+ app-arch/bzip2:=
+ app-arch/lz4:=
+ app-arch/snappy:=
+ >=app-arch/snappy-1.1.9-r1
+ app-arch/zstd:=
+ app-shells/bash:0
+ app-misc/jq:=
+ dev-libs/crypto++:=
+ dev-cpp/gflags:=
+ dev-lang/jsonnet:=
+ <dev-libs/leveldb-1.23:=[snappy,tcmalloc(-)?]
+ dev-libs/libaio:=
+ <dev-libs/libfmt-10:=
+ dev-libs/libnl:3=
+ dev-libs/libxml2:=
+ dev-libs/libevent:=
+ dev-libs/libutf8proc:=
+ dev-libs/nss:=
+ dev-libs/openssl:=
+ <dev-libs/rocksdb-6.15:=
+ dev-libs/thrift:=
+ dev-libs/xmlsec:=[openssl]
+ dev-cpp/yaml-cpp:=
+ dev-python/natsort[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+ net-dns/c-ares:=
+ net-libs/gnutls:=
+ sys-auth/oath-toolkit:=
+ sys-apps/coreutils
+ sys-apps/hwloc:=
+ sys-apps/keyutils:=
+ sys-apps/util-linux:=
+ sys-libs/libcap-ng:=
+ sys-libs/ncurses:0=
+ sys-libs/zlib:=
+ sys-process/numactl:=
+ virtual/libcrypt:=
+ x11-libs/libpciaccess:=
+ babeltrace? ( dev-util/babeltrace )
+ fuse? ( sys-fs/fuse:3= )
+ jemalloc? ( dev-libs/jemalloc:= )
+ !jemalloc? ( >=dev-util/google-perftools-2.6.1:= )
+ jaeger? (
+ dev-cpp/nlohmann_json:=
+ dev-cpp/opentelemetry-cpp:=[jaeger]
+ )
+ kafka? ( dev-libs/librdkafka:= )
+ kerberos? ( virtual/krb5 )
+ ldap? ( net-nds/openldap:= )
+ lttng? ( dev-util/lttng-ust:= )
+ parquet? ( dev-libs/re2:= )
+ pmdk? ( >=dev-libs/pmdk-1.10.0:= )
+ rabbitmq? ( net-libs/rabbitmq-c:= )
+ radosgw? (
+ dev-libs/icu:=
+ dev-libs/expat:=
+ net-misc/curl:=[curl_ssl_openssl]
+ )
+ rbd-rwl? ( dev-libs/pmdk:= )
+ rdma? ( sys-cluster/rdma-core:= )
+ spdk? ( dev-util/cunit )
+ sqlite? ( dev-db/sqlite:= )
+ system-boost? ( dev-libs/boost:=[context,python,${PYTHON_USEDEP},zlib] )
+ uring? ( sys-libs/liburing:= )
+ xfs? ( sys-fs/xfsprogs:= )
+ zbd? ( sys-block/libzbd:= )
+ zfs? ( sys-fs/zfs:= )
+"
+BDEPEND="
+ amd64? ( dev-lang/nasm )
+ x86? ( dev-lang/yasm )
+ app-arch/cpio
+ >=dev-util/cmake-3.5.0
+ dev-python/cython[${PYTHON_USEDEP}]
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ dev-python/sphinx
+ dev-util/gperf
+ dev-util/ragel
+ dev-util/valgrind
+ sys-apps/coreutils
+ sys-apps/grep
+ sys-apps/util-linux
+ sys-apps/which
+ sys-devel/bc
+ sys-devel/patch
+ virtual/pkgconfig
+ jaeger? (
+ sys-devel/bison
+ sys-devel/flex
+ )
+ test? (
+ dev-util/cunit
+ dev-python/coverage[${PYTHON_USEDEP}]
+ dev-python/virtualenv[${PYTHON_USEDEP}]
+ dev-python/requests-mock[${PYTHON_USEDEP}]
+ sys-apps/grep[pcre]
+ sys-fs/btrfs-progs
+ )
+"
+RDEPEND="
+ ${DEPEND}
+ app-admin/sudo
+ net-misc/socat
+ sys-apps/gptfdisk
+ sys-apps/nvme-cli
+ >=sys-apps/smartmontools-7.0
+ sys-block/parted
+ sys-fs/cryptsetup
+ sys-fs/lsscsi
+ sys-fs/lvm2[lvm]
+ app-alternatives/awk
+ dev-python/bcrypt[${PYTHON_USEDEP}]
+ dev-python/cherrypy[${PYTHON_USEDEP}]
+ dev-python/python-dateutil[${PYTHON_USEDEP}]
+ dev-python/flask[${PYTHON_USEDEP}]
+ dev-python/jinja[${PYTHON_USEDEP}]
+ dev-python/pecan[${PYTHON_USEDEP}]
+ dev-python/prettytable[${PYTHON_USEDEP}]
+ dev-python/pyopenssl[${PYTHON_USEDEP}]
+ dev-python/requests[${PYTHON_USEDEP}]
+ dev-python/werkzeug[${PYTHON_USEDEP}]
+ mgr? (
+ dev-python/jsonpatch[${PYTHON_USEDEP}]
+ dev-python/more-itertools[${PYTHON_USEDEP}]
+ dev-python/numpy[${PYTHON_USEDEP}]
+ dev-python/pyjwt[${PYTHON_USEDEP}]
+ dev-python/routes[${PYTHON_USEDEP}]
+ diskprediction? (
+ >=dev-python/scipy-1.4.0[${PYTHON_USEDEP}]
+ )
+ sci-libs/scikit-learn[${PYTHON_USEDEP}]
+ dev-python/six[${PYTHON_USEDEP}]
+ )
+"
+REQUIRED_USE="
+ ${PYTHON_REQUIRED_USE}
+ ${LUA_REQUIRED_USE}
+ ?? ( jemalloc tcmalloc )
+ diskprediction? ( mgr )
+ kafka? ( radosgw )
+ mgr? ( cephfs )
+ rabbitmq? ( radosgw )
+ rgw-lua? ( radosgw )
+"
+
+RESTRICT="
+ !test? ( test )
+"
+
+# tests need root access, and network access
+RESTRICT+="test"
+
+# false positives unless all USE flags are on
+CMAKE_WARN_UNUSED_CLI=no
+
+PATCHES=(
+ "${FILESDIR}/ceph-12.2.0-use-provided-cpu-flag-values.patch"
+ "${FILESDIR}/ceph-14.2.0-cflags.patch"
+ "${FILESDIR}/ceph-12.2.4-boost-build-none-options.patch"
+ "${FILESDIR}/ceph-16.2.2-cflags.patch"
+ "${FILESDIR}/ceph-17.2.1-no-virtualenvs.patch"
+ "${FILESDIR}/ceph-13.2.2-dont-install-sysvinit-script.patch"
+ "${FILESDIR}/ceph-14.2.0-dpdk-cflags.patch"
+ "${FILESDIR}/ceph-16.2.0-rocksdb-cmake.patch"
+ "${FILESDIR}/ceph-16.2.0-spdk-tinfo.patch"
+ "${FILESDIR}/ceph-16.2.0-jaeger-system-boost.patch"
+ "${FILESDIR}/ceph-16.2.0-liburing.patch"
+ "${FILESDIR}/ceph-17.2.0-cyclic-deps.patch"
+ "${FILESDIR}/ceph-17.2.0-pybind-boost-1.74.patch"
+ "${FILESDIR}/ceph-17.2.0-findre2.patch"
+ "${FILESDIR}/ceph-17.2.0-install-dbstore.patch"
+ "${FILESDIR}/ceph-17.2.0-deprecated-boost.patch"
+ "${FILESDIR}/ceph-17.2.0-system-opentelemetry.patch"
+ "${FILESDIR}/ceph-17.2.0-fuse3.patch"
+ "${FILESDIR}/ceph-17.2.0-osd_class_dir.patch"
+ "${FILESDIR}/ceph-17.2.0-gcc12-header.patch"
+ "${FILESDIR}/ceph-17.2.3-flags.patch"
+ "${FILESDIR}/ceph-17.2.4-cyclic-deps.patch"
+ # https://bugs.gentoo.org/866165
+ "${FILESDIR}/ceph-17.2.5-suppress-cmake-warning.patch"
+ "${FILESDIR}/ceph-17.2.5-gcc13-deux.patch"
+ "${FILESDIR}/ceph-17.2.5-boost-1.81.patch"
+ # https://bugs.gentoo.org/901403
+ "${FILESDIR}/ceph-17.2.6-link-boost-context.patch"
+ # https://bugs.gentoo.org/905626
+ "${FILESDIR}/ceph-17.2.6-arrow-flatbuffers-c++14.patch"
+)
+
+check-reqs_export_vars() {
+ CHECKREQS_DISK_BUILD="6G"
+
+ if use system-boost; then
+ CHECKREQS_DISK_USR="350M"
+ else
+ CHECKREQS_DISK_USR="510M"
+ fi
+
+ export CHECKREQS_DISK_BUILD CHECKREQS_DISK_USR
+}
+
+pkg_pretend() {
+ check-reqs_export_vars
+ check-reqs_pkg_pretend
+}
+
+pkg_setup() {
+ python_setup
+ lua_setup
+ check-reqs_export_vars
+ check-reqs_pkg_setup
+}
+
+src_prepare() {
+ cmake_src_prepare
+
+ # Add compatibility hack for fmt-9, this won't work with fmt-10 though.
+ # See bug #895254. Should be fixed upstream properly by https://github.com/ceph/ceph/pull/49768.
+ append-cppflags -DFMT_DEPRECATED_OSTREAM
+
+ if use system-boost; then
+ find "${S}" -name '*.cmake' -or -name 'CMakeLists.txt' -print0 \
+ | xargs --null sed -r \
+ -e 's|Boost::|boost_|g' \
+ -e 's|Boost_|boost_|g' \
+ -e 's|[Bb]oost_boost|boost_system|g' \
+ -i || die
+ fi
+
+ if ! use systemd; then
+ find "${S}"/src/ceph-volume/ceph_volume -name '*.py' -print0 \
+ | xargs --null sed \
+ -e '/^from ceph_volume.systemd import systemctl/ d' \
+ -i || die
+ fi
+
+ sed -r -e "s:DESTINATION .+\\):DESTINATION $(get_bashcompdir)\\):" \
+ -i src/bash_completion/CMakeLists.txt || die
+
+ sed -e "s:objdump -p:$(tc-getOBJDUMP) -p:" -i CMakeLists.txt || die
+
+ # force lua version to use selected version
+ local lua_version
+ lua_version=$(ver_cut 1-2 $(lua_get_version))
+ sed "s:find_package(Lua [0-9][.][0-9] REQUIRED):find_package(Lua ${lua_version} EXACT REQUIRED):" \
+ -i src/CMakeLists.txt
+
+ if use spdk; then
+ # https://bugs.gentoo.org/871942
+ sed -i 's/[#]ifndef HAVE_ARC4RANDOM/#if 0/' src/spdk/lib/iscsi/iscsi.c || die
+ fi
+
+ # remove tests that need root access
+ rm src/test/cli/ceph-authtool/cap*.t || die
+}
+
+ceph_src_configure() {
+ local mycmakeargs=(
+ -DWITH_BABELTRACE:BOOL=$(usex babeltrace)
+ -DWITH_BLUESTORE_PMEM:BOOL=$(usex pmdk)
+ -DWITH_CEPHFS:BOOL=$(usex cephfs)
+ -DWITH_CEPHFS_SHELL:BOOL=$(usex cephfs)
+ -DWITH_DPDK:BOOL=$(usex dpdk)
+ -DWITH_SPDK:BOOL=$(usex spdk)
+ -DWITH_FUSE:BOOL=$(usex fuse)
+ -DWITH_LTTNG:BOOL=$(usex lttng)
+ -DWITH_GSSAPI:BOOL=$(usex kerberos)
+ -DWITH_GRAFANA:BOOL=$(usex grafana)
+ -DWITH_MGR:BOOL=$(usex mgr)
+ -DWITH_MGR_DASHBOARD_FRONTEND:BOOL=OFF
+ -DWITH_OPENLDAP:BOOL=$(usex ldap)
+ -DWITH_PYTHON3:STRING=3
+ -DWITH_RADOSGW:BOOL=$(usex radosgw)
+ -DWITH_RADOSGW_AMQP_ENDPOINT:BOOL=$(usex rabbitmq)
+ -DWITH_RADOSGW_KAFKA_ENDPOINT:BOOL=$(usex kafka)
+ -DWITH_RADOSGW_LUA_PACKAGES:BOOL=$(usex rgw-lua "$(usex radosgw)" "NO")
+ -DWITH_RBD_RWL:BOOL=$(usex rbd-rwl)
+ -DWITH_RBD_SSD_CACHE:BOOL=$(usex rbd-ssd)
+ -DWITH_SYSTEMD:BOOL=$(usex systemd)
+ -DWITH_TESTS:BOOL=$(usex test)
+ -DWITH_LIBURING:BOOL=$(usex uring)
+ -DWITH_SYSTEM_LIBURING:BOOL=$(usex uring)
+ -DWITH_LIBCEPHSQLITE:BOOL=$(usex sqlite)
+ -DWITH_XFS:BOOL=$(usex xfs)
+ -DWITH_ZBD:BOOL=$(usex zbd)
+ -DWITH_ZFS:BOOL=$(usex zfs)
+ -DENABLE_SHARED:BOOL=ON
+ -DALLOCATOR:STRING=$(usex tcmalloc 'tcmalloc' "$(usex jemalloc 'jemalloc' 'libc')")
+ -DWITH_SYSTEM_PMDK:BOOL=$(usex pmdk 'YES' "$(usex rbd-rwl '')")
+ -DWITH_SYSTEM_BOOST:BOOL=$(usex system-boost)
+ -DWITH_SYSTEM_ROCKSDB:BOOL=ON
+ -DWITH_SYSTEM_ZSTD:BOOL=ON
+ -DWITH_RDMA:BOOL=$(usex rdma)
+ -DCMAKE_INSTALL_DOCDIR:PATH="${EPREFIX}/usr/share/doc/${PN}-${PVR}"
+ -DCMAKE_INSTALL_SYSCONFDIR:PATH="${EPREFIX}/etc"
+ -Wno-dev
+ )
+
+ # this breaks when re-configuring for python impl
+ if [[ ${EBUILD_PHASE} == configure ]]; then
+ mycmakeargs+=(
+ -DWITH_JAEGER:BOOL=$(usex jaeger)
+ -DWITH_RADOSGW_SELECT_PARQUET:BOOL=$(usex parquet)
+ )
+ else
+ mycmakeargs+=(
+ -DWITH_RADOSGW_SELECT_PARQUET:BOOL=OFF
+ -DWITH_JAEGER:BOOL=OFF
+ # don't want to warn about unused CLI when reconfiguring for python
+ -DCMAKE_WARN_UNUSED_CLI:BOOL=OFF
+ )
+ fi
+
+ # conditionally used cmake args
+ use test && mycmakearts+=( -DWITH_SYSTEM_GTEST:BOOL=$(usex test) )
+ use systemd && mycmakeargs+=( -DSYSTEMD_SYSTEM_UNIT_DIR:PATH=$(systemd_get_systemunitdir) )
+
+ if use amd64 || use x86; then
+ local flag
+ for flag in "${CPU_FLAGS_X86[@]}"; do
+ case "${flag}" in
+ avx*)
+ local var=${flag%f}
+ mycmakeargs+=(
+ "-DHAVE_NASM_X64_${var^^}:BOOL=$(usex cpu_flags_x86_${flag})"
+ )
+ ;;
+ *) mycmakeargs+=(
+ "-DHAVE_INTEL_${flag^^}:BOOL=$(usex cpu_flags_x86_${flag})"
+ );;
+ esac
+ done
+ fi
+
+ # needed for >=glibc-2.32
+ has_version '>=sys-libs/glibc-2.32' && mycmakeargs+=( -DWITH_REENTRANT_STRSIGNAL:BOOL=ON )
+
+ rm -f "${BUILD_DIR:-${S}}/CMakeCache.txt" \
+ || die "failed to remove cmake cache"
+
+ # hopefully this will not be necessary in the next release
+ use parquet && export ARROW_XSIMD_URL="file:///${DISTDIR}/ceph-xsimd-${PV}.tar.gz"
+
+ cmake_src_configure
+
+ # bug #630232
+ sed -i "s:\"${T//:\\:}/${EPYTHON}/bin/python\":\"${PYTHON}\":" \
+ "${BUILD_DIR:-${S}}"/include/acconfig.h \
+ || die "sed failed"
+}
+
+src_configure() {
+ use custom-cflags || strip-flags
+ ceph_src_configure
+}
+
+src_compile() {
+ cmake_build all
+
+ # we have to do this here to prevent from building everything multiple times
+ python_copy_sources
+ python_foreach_impl python_compile
+}
+
+python_compile() {
+ local CMAKE_USE_DIR="${S}"
+ ceph_src_configure
+
+ cmake_build src/pybind/CMakeFiles/cython_modules
+}
+
+src_install() {
+ python_foreach_impl python_install
+
+ python_setup
+ cmake_src_install
+ python_optimize
+
+ find "${ED}" -name '*.la' -type f -delete || die
+
+ exeinto /usr/$(get_libdir)/ceph
+ newexe "${BUILD_DIR}/bin/init-ceph" init-ceph
+
+ insinto /etc/logrotate.d/
+ newins "${FILESDIR}"/ceph.logrotate-r2 ${PN}
+
+ keepdir /var/lib/${PN}{,/tmp} /var/log/ceph/stat /var/log/ceph/console
+
+ fowners -R ceph:ceph /var/log/ceph
+
+ newinitd "${FILESDIR}/rbdmap.initd-r1" rbdmap
+ newinitd "${FILESDIR}/${PN}.initd-r14" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd-r5" ${PN}
+
+ insinto /etc/sudoers.d
+ doins sudoers.d/*
+
+ insinto /etc/sysctl.d
+ newins "${FILESDIR}"/sysctld 90-${PN}.conf
+
+ use tcmalloc && newenvd "${FILESDIR}"/envd-tcmalloc 99${PN}-tcmalloc
+
+ # units aren't installed by the build system unless systemd is enabled
+ # so no point installing these with the USE flag disabled
+ if use systemd; then
+ systemd_install_serviced "${FILESDIR}/ceph-mds_at.service.conf" "ceph-mds@.service"
+ systemd_install_serviced "${FILESDIR}/ceph-osd_at.service.conf" "ceph-osd@.service"
+ fi
+
+ udev_dorules udev/*.rules
+ newtmpfiles "${FILESDIR}"/ceph-tmpfilesd ${PN}.conf
+
+ readme.gentoo_create_doc
+
+ # bug #630232
+ sed -i -r "s:${T//:/\\:}/${EPYTHON}:/usr:" "${ED}"/usr/bin/ceph{,-crash} \
+ || die "sed failed"
+
+ python_fix_shebang "${ED}"/usr/{,s}bin/
+
+ # python_fix_shebang apparently is not idempotent
+ local shebang_regex='(/usr/lib/python-exec/python[0-9]\.[0-9]/python)[0-9]\.[0-9]'
+ grep -r -E -l --null "${shebang_regex}" "${ED}"/usr/{s,}bin/ \
+ | xargs --null --no-run-if-empty -- sed -i -r "s:${shebang_regex}:\1:" || die
+
+ local -a rados_classes=( "${ED}/usr/$(get_libdir)/rados-classes"/* )
+ dostrip -x "${rados_classes[@]#${ED}}"
+}
+
+python_install() {
+ local CMAKE_USE_DIR="${S}"
+ DESTDIR="${ED}" cmake_build src/pybind/install
+
+ python_optimize
+}
+
+pkg_postinst() {
+ readme.gentoo_print_elog
+ tmpfiles_process ${PN}.conf
+ udev_reload
+}
+
+pkg_postrm() {
+ udev_reload
+}
diff --git a/sys-cluster/ceph/files/ceph-17.2.6-arrow-flatbuffers-c++14.patch b/sys-cluster/ceph/files/ceph-17.2.6-arrow-flatbuffers-c++14.patch
new file mode 100644
index 000000000000..e5ab9943a4f6
--- /dev/null
+++ b/sys-cluster/ceph/files/ceph-17.2.6-arrow-flatbuffers-c++14.patch
@@ -0,0 +1,92 @@
+https://bugs.gentoo.org/905626
+https://github.com/google/flatbuffers/pull/7897
+https://github.com/apache/arrow/commit/22dc537e581b385b53ce579a03786a2db0bd4487
+
+From 22dc537e581b385b53ce579a03786a2db0bd4487 Mon Sep 17 00:00:00 2001
+From: Antoine Pitrou <antoine@python.org>
+Date: Thu, 20 Jan 2022 20:44:40 +0100
+Subject: [PATCH] ARROW-15388: [C++] Avoid including absl from flatbuffers
+
+There may be an incomplete/broken copy of the Abseil library lying around
+(for example because of a race condition while installing it as a bundled library).
+
+Since absl is only used by Flatbuffers to provide a string_view facility,
+use our own vendored string_view instead.
+
+Closes #12204 from pitrou/ARROW-15388-flatbuffers-string-view
+
+Authored-by: Antoine Pitrou <antoine@python.org>
+Signed-off-by: Antoine Pitrou <antoine@python.org>
+---
+ cpp/thirdparty/flatbuffers/README.md | 42 +++++++++++++++++++
+ .../flatbuffers/include/flatbuffers/base.h | 7 ----
+ 2 files changed, 42 insertions(+), 7 deletions(-)
+ create mode 100644 cpp/thirdparty/flatbuffers/README.md
+
+diff --git a/src/arrow/cpp/thirdparty/flatbuffers/README.md b/src/arrow/cpp/thirdparty/flatbuffers/README.md
+new file mode 100644
+index 0000000000000..e955adba4cebb
+--- /dev/null
++++ b/src/arrow/cpp/thirdparty/flatbuffers/README.md
+@@ -0,0 +1,42 @@
++<!---
++ Licensed to the Apache Software Foundation (ASF) under one
++ or more contributor license agreements. See the NOTICE file
++ distributed with this work for additional information
++ regarding copyright ownership. The ASF licenses this file
++ to you under the Apache License, Version 2.0 (the
++ "License"); you may not use this file except in compliance
++ with the License. You may obtain a copy of the License at
++
++ http://www.apache.org/licenses/LICENSE-2.0
++
++ Unless required by applicable law or agreed to in writing,
++ software distributed under the License is distributed on an
++ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
++ KIND, either express or implied. See the License for the
++ specific language governing permissions and limitations
++ under the License.
++-->
++
++This directory contains a vendored version of Flatbuffers
++(unknown changeset), with the following patch for ARROW-15388:
++
++```diff
++diff --git a/cpp/thirdparty/flatbuffers/include/flatbuffers/base.h b/cpp/thirdparty/flatbuffers/include/flatbuffers/base.h
++index 955738067..fccce42f6 100644
++--- a/cpp/thirdparty/flatbuffers/include/flatbuffers/base.h
+++++ b/cpp/thirdparty/flatbuffers/include/flatbuffers/base.h
++@@ -212,13 +212,6 @@ namespace flatbuffers {
++ typedef std::experimental::string_view string_view;
++ }
++ #define FLATBUFFERS_HAS_STRING_VIEW 1
++- // Check for absl::string_view
++- #elif __has_include("absl/strings/string_view.h")
++- #include "absl/strings/string_view.h"
++- namespace flatbuffers {
++- typedef absl::string_view string_view;
++- }
++- #define FLATBUFFERS_HAS_STRING_VIEW 1
++ #endif
++ #endif // __has_include
++ #endif // !FLATBUFFERS_HAS_STRING_VIEW
++```
+diff --git a/src/arrow/cpp/thirdparty/flatbuffers/include/flatbuffers/base.h b/src/arrow/cpp/thirdparty/flatbuffers/include/flatbuffers/base.h
+index 9557380672342..fccce42f68aa6 100644
+--- a/src/arrow/cpp/thirdparty/flatbuffers/include/flatbuffers/base.h
++++ b/src/arrow/cpp/thirdparty/flatbuffers/include/flatbuffers/base.h
+@@ -212,13 +212,6 @@ namespace flatbuffers {
+ typedef std::experimental::string_view string_view;
+ }
+ #define FLATBUFFERS_HAS_STRING_VIEW 1
+- // Check for absl::string_view
+- #elif __has_include("absl/strings/string_view.h")
+- #include "absl/strings/string_view.h"
+- namespace flatbuffers {
+- typedef absl::string_view string_view;
+- }
+- #define FLATBUFFERS_HAS_STRING_VIEW 1
+ #endif
+ #endif // __has_include
+ #endif // !FLATBUFFERS_HAS_STRING_VIEW
+