diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-12-30 08:16:57 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-12-30 08:16:57 +0000 |
commit | a21eae5570ee23ff259ccee6adc402fa27578a83 (patch) | |
tree | 0507ed3791ad67e98a33cc87b0a485409d6b3e77 /sys-cluster/ceph | |
parent | b7cf34e541f10778605d8740e2690d8459908ac5 (diff) |
gentoo auto-resync : 30:12:2022 - 08:16:57
Diffstat (limited to 'sys-cluster/ceph')
-rw-r--r-- | sys-cluster/ceph/Manifest | 2 | ||||
-rw-r--r-- | sys-cluster/ceph/ceph-17.2.5-r2.ebuild | 477 | ||||
-rw-r--r-- | sys-cluster/ceph/files/ceph-17.2.5-boost-1.81.patch | 49 |
3 files changed, 528 insertions, 0 deletions
diff --git a/sys-cluster/ceph/Manifest b/sys-cluster/ceph/Manifest index 1f699e78b696..4d6c102b5456 100644 --- a/sys-cluster/ceph/Manifest +++ b/sys-cluster/ceph/Manifest @@ -38,6 +38,7 @@ AUX ceph-17.2.1-python310.patch 456 BLAKE2B 161527aee7f0c9a11e3823771f5452da98b9 AUX ceph-17.2.3-flags.patch 782 BLAKE2B 08cd4fefdce90bc42b9c4e3caff805b1d8c9d011a96d3d2562b2a5cecf25b1b20c65a0cb8e90c0972e6708088feeecd3f829d3fd614b41289bf7f0d2d6d357fe SHA512 65bbdeed0f835a5444bd468dce5e78bb43284f1cb96c3ecdbc63b267213b251c9ad18291f47cb4f604e6817e0bf4aab025b8b67c5c0877cd58f4981d4f65ccec AUX ceph-17.2.3-gcc12.patch 924 BLAKE2B 119fccc4caa45e7b62c73d6cc66b9ba0b23598607c18fc621ce86e2ba11bbfd15e432e4c0e528fb8af2cfeedf3e535bfcc8008a39c5c7e3789b96372f2970e53 SHA512 121d8992dab710b5b1721e7fd04e30cb4e2e6b2cd2f6ed30934c6f65b3d9676bc5a1e8dd52c739cff704f900a651ea8729bb3234db033ef23434acd8fb5436fd AUX ceph-17.2.4-cyclic-deps.patch 562 BLAKE2B 4562e7b6afdb23e2d0c65c5db61aef6ce7d313716ef1e40c5b12a6afcb91ae8a38ead8432fe6ee93eeee12444c5b971d9c2ccb866c20806b8f3a57c9d8668b3c SHA512 5028bda954938a8718be6bc4729e816a178a2f47c3a2eeffdcb6b357d054fe236eba54fb0067dfbf6f6a78b5f6d805fe427f0d2e5b0349a08b2404604083132c +AUX ceph-17.2.5-boost-1.81.patch 1456 BLAKE2B 0dbff43d17f099242e1bf0d44f6c46c6175a4c9221fdd904a152cab8a1105cb94960b7519471d86a359c35a356a7c793de2a2ac7d3cb7880dcb044ad93ac44e4 SHA512 2dcb4d7e42ab71c97c601a7171075077966c6d3bfea1a0cc7676bcc03bb3bf5a4fca774bca571c908a6450098b48951ac5fc12f6121e015b6ac56deb5d514048 AUX ceph-17.2.5-gcc13.patch 2917 BLAKE2B 9c41c0490932fc1f28bb647f7911189cf440517673c98b09c50a86467cd4478d11067a14ea57b10113e67e7772525cbee525e2855261322ff9e8cbd47a3268c5 SHA512 a0c720e624cef883c0360d043a4c3d49a4dfca2f0e4b3f73da9318615a3a5ff506baa133a140403b9a90fc87bddb6fbe58691f629f1cb689a21b732855343b44 AUX ceph-17.2.5-suppress-cmake-warning.patch 370 BLAKE2B 225ee73ddc24e3b398243603292949da09417c4c928daf0328729d8a69a475e6e5cdd2c9911c4c2ff6f3a6fea8b785a210e4beab5dc7bd910e390e84aa8e4b61 SHA512 e71ead89e494ac5639c08764b4d7bc3a96f87bac4ea8f9adb3e29c568f5d970551bc568c55adfd1b21be575db39a6f494de3e9d091d4ae8c04d2d5421be24f4f AUX ceph-mds_at.service 282 BLAKE2B 3a51e5d5e0490c021282a37961824d650891c2d84c077c6479a9ee733f8a16fbe65cf204aa74e30ddd24dc01f32740037a6bd137a40464d57e1afeba5a49f893 SHA512 3a37e187f925e1a5fb672ac90937f544f3b98ed5a30b6a6b931a600f9d6a245373085ed61b40e0c64b30dbfac51dd99cbeaeb7538b5f23953bc0dde1df94742d @@ -66,4 +67,5 @@ EBUILD ceph-16.2.9-r3.ebuild 12577 BLAKE2B 32c1e451a0002cefdfcc5244fe89554bb4716 EBUILD ceph-17.2.3-r4.ebuild 12657 BLAKE2B 6af8a2b00f7c0559007c9d68673852621717d1b5608f12c4a2c6342cac21197992788066489b575e8411f0f971d68a505dde54b0d40c49d6d3853269fdfddcd3 SHA512 ca8c3e3db6bd0f5a312d0c855717b68b58f080c24ffc82d4597c6b0753bcb27180927fda330fba24f5d88e6d3030886c260a7f4301990e818ead0a4eae07cf27 EBUILD ceph-17.2.4-r1.ebuild 12634 BLAKE2B fa7be818a54b12658f08c8019eaf2302d4ddc5bb2c998c2913599e27945e063ee91a75479cc0ff844f41cf7562b62c07b94a2510b6a5f37d4eb4c292a247e82c SHA512 0766547f3d83ae64e0a6a364de0efb817f3a572661348b4a06d2844aa6f8e098223f6d6107023e6b22b5ad9f84c36b2fef9c77fe78f2b641bf88d6f60c17c852 EBUILD ceph-17.2.5-r1.ebuild 12911 BLAKE2B 71a804495076674fbf896ae183ae5f9f78b7bda78d1ff89d840cf7f1e0283e7c8a121a8f76dcd5a52d5506526a0f6c2d4097a62b593a71a6a1e1703aad73bb80 SHA512 5254fa57beb812408c49dc340f2074cbd7a3bdf876bc24d17c3d7bbc61cf69055cd7335f3880d66d0270686be1c95d41c53a023f4209e5bcc5f2f1d30a7e2793 +EBUILD ceph-17.2.5-r2.ebuild 12955 BLAKE2B b27f597ed8fe7b36039a0ca1b60fa010d09eaceb9b8922c30518f595c02dc5cb62a5f62fad15de6466b6fe6ff47ee1b700935da143fee9ba8e302b09569a87af SHA512 9c1b9e9b07e2024b7ec1ac060603d84695e8d0e2e2c9911f7cef2b2594595e17e8ed5f229c72c3c4568d45c5d022b63fa3b3bcd27b2840a774d51f68db889b62 MISC metadata.xml 2504 BLAKE2B df35722094ef7fbc1ecd16d3784e8589958a8d4e2f915e84f41e6ce5191256697a73eb9d3d658089afaaa82a5b23bdf7097870a15e43029d2598bb1792a4b571 SHA512 b0c03c35876eccf78360914237fdef8925963b21f78fd8516e8506150cce36a901562e33e6fab102dd5a4e727f9a4422eb136e5b64d46b9538fb4450b3467b2b diff --git a/sys-cluster/ceph/ceph-17.2.5-r2.ebuild b/sys-cluster/ceph/ceph-17.2.5-r2.ebuild new file mode 100644 index 000000000000..1401c2d28548 --- /dev/null +++ b/sys-cluster/ceph/ceph-17.2.5-r2.ebuild @@ -0,0 +1,477 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{8..10} ) +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 + +SRC_URI=" + https://download.ceph.com/tarballs/${P}.tar.gz + parquet? ( https://github.com/xtensor-stack/xsimd/archive/aeec9c872c8b475dedd7781336710f2dd2666cb2.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[@]})" + +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-6.2.1:= + <dev-libs/libfmt-9:= + 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.patch" + "${FILESDIR}/ceph-17.2.5-boost-1.81.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 + + 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/${PN}/stat + + fowners -R ceph:ceph /var/log/ceph + + newinitd "${FILESDIR}/rbdmap.initd-r1" rbdmap + newinitd "${FILESDIR}/${PN}.initd-r12" ${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.5-boost-1.81.patch b/sys-cluster/ceph/files/ceph-17.2.5-boost-1.81.patch new file mode 100644 index 000000000000..2dd06edb312f --- /dev/null +++ b/sys-cluster/ceph/files/ceph-17.2.5-boost-1.81.patch @@ -0,0 +1,49 @@ +https://bugs.gentoo.org/887481 +--- a/src/rgw/rgw_asio_client.cc ++++ b/src/rgw/rgw_asio_client.cc +@@ -39,11 +39,11 @@ + const auto& value = header->value(); + + if (field == beast::http::field::content_length) { +- env.set("CONTENT_LENGTH", value.to_string()); ++ env.set("CONTENT_LENGTH", value); + continue; + } + if (field == beast::http::field::content_type) { +- env.set("CONTENT_TYPE", value.to_string()); ++ env.set("CONTENT_TYPE", value); + continue; + } + +@@ -62,26 +62,26 @@ + } + *dest = '\0'; + +- env.set(buf, value.to_string()); ++ env.set(buf, value); + } + + int major = request.version() / 10; + int minor = request.version() % 10; + env.set("HTTP_VERSION", std::to_string(major) + '.' + std::to_string(minor)); + +- env.set("REQUEST_METHOD", request.method_string().to_string()); ++ env.set("REQUEST_METHOD", request.method_string()); + + // split uri from query + auto uri = request.target(); + auto pos = uri.find('?'); + if (pos != uri.npos) { + auto query = uri.substr(pos + 1); +- env.set("QUERY_STRING", query.to_string()); ++ env.set("QUERY_STRING", query); + uri = uri.substr(0, pos); + } +- env.set("SCRIPT_URI", uri.to_string()); ++ env.set("SCRIPT_URI", uri); + +- env.set("REQUEST_URI", request.target().to_string()); ++ env.set("REQUEST_URI", request.target()); + + char port_buf[16]; + snprintf(port_buf, sizeof(port_buf), "%d", local_endpoint.port()); |