%if 0%{?rhel} < 9
%bcond_with system_pmdk
%else
+%ifarch s390x aarch64
+%bcond_with system_pmdk
+%else
%bcond_without system_pmdk
%endif
+%endif
%bcond_without selinux
%if 0%{?rhel} >= 8
%bcond_with cephfs_java
%global _remote_tarball_prefix https://download.ceph.com/tarballs/
%endif
%if 0%{?suse_version}
+%ifarch s390x
+%bcond_with system_pmdk
+%else
%bcond_without system_pmdk
+%endif
%bcond_with amqp_endpoint
%bcond_with cephfs_java
%bcond_with kafka_endpoint
%{!?python3_pkgversion: %global python3_pkgversion 3}
%{!?python3_version_nodots: %global python3_version_nodots 3}
%{!?python3_version: %global python3_version 3}
+%{!?gts_prefix: %global gts_prefix gcc-toolset-11}
%if ! 0%{?suse_version}
# use multi-threaded xz compression: xz level 7 using ncpus threads
%endif
%endif
-%if 0%{with seastar}
-# disable -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1, as gcc-toolset-{9,10}-annobin
+# disable -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1, as gcc-toolset-{10,11}-annobin
# do not provide gcc-annobin.so anymore, despite that they provide annobin.so. but
# redhat-rpm-config still passes -fplugin=gcc-annobin to the compiler.
%undefine _annotated_build
+%if 0%{?rhel} == 8 && 0%{?enable_devtoolset11:1}
+%enable_devtoolset11
%endif
#################################################################################
# main package definition
#################################################################################
Name: ceph
-Version: 17.2.1
+Version: 17.2.6
Release: 0%{?dist}
%if 0%{?fedora} || 0%{?rhel}
Epoch: 2
Group: System/Filesystems
%endif
URL: http://ceph.com/
-Source0: %{?_remote_tarball_prefix}ceph-17.2.1.tar.bz2
+Source0: %{?_remote_tarball_prefix}ceph-17.2.6.tar.bz2
%if 0%{?suse_version}
# _insert_obs_source_lines_here
ExclusiveArch: x86_64 aarch64 ppc64le s390x
BuildRequires: gperf
BuildRequires: cmake > 3.5
BuildRequires: fuse-devel
-%if 0%{with seastar} && 0%{?rhel}
-BuildRequires: gcc-toolset-9-gcc-c++ >= 9.2.1-2.3
-%else
-BuildRequires: gcc-c++
+%if 0%{?fedora} || 0%{?suse_version} > 1500 || 0%{?rhel} == 9
+BuildRequires: gcc-c++ >= 11
+%endif
+%if 0%{?suse_version} == 1500
+BuildRequires: gcc11-c++
+%endif
+%if 0%{?rhel} == 8
+BuildRequires: %{gts_prefix}-gcc-c++
+BuildRequires: %{gts_prefix}-build
+%ifarch aarch64
+BuildRequires: %{gts_prefix}-libatomic-devel
+%endif
+%endif
+%if 0%{?fedora} || 0%{?rhel} == 9
+BuildRequires: libatomic
%endif
%if 0%{with tcmalloc}
# libprofiler did not build on ppc64le until 2.7.90
BuildRequires: python%{python3_pkgversion}-coverage
BuildRequires: python%{python3_pkgversion}-pyOpenSSL
BuildRequires: socat
+BuildRequires: python%{python3_pkgversion}-asyncssh
+BuildRequires: python%{python3_pkgversion}-natsort
%endif
%if 0%{with zbd}
BuildRequires: libzbd-devel
%if 0%{?fedora}
BuildRequires: libubsan
BuildRequires: libasan
-BuildRequires: libatomic
%endif
-%if 0%{?rhel}
-BuildRequires: gcc-toolset-9-annobin
-BuildRequires: gcc-toolset-9-libubsan-devel
-BuildRequires: gcc-toolset-9-libasan-devel
-BuildRequires: gcc-toolset-9-libatomic-devel
+%if 0%{?rhel} == 8
+BuildRequires: %{gts_prefix}-annobin
+BuildRequires: %{gts_prefix}-annobin-plugin-gcc
+BuildRequires: %{gts_prefix}-libubsan-devel
+BuildRequires: %{gts_prefix}-libasan-devel
%endif
%endif
#################################################################################
BuildRequires: liblz4-devel >= 1.7
# for prometheus-alerts
BuildRequires: golang-github-prometheus-prometheus
+BuildRequires: jsonnet
%endif
%if 0%{?fedora} || 0%{?rhel}
Requires: systemd
%endif
%if 0%{?suse_version}
BuildRequires: golang-github-prometheus-prometheus
+BuildRequires: jsonnet
BuildRequires: libxmlsec1-1
BuildRequires: libxmlsec1-nss1
BuildRequires: libxmlsec1-openssl1
Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release}
Requires: ceph-grafana-dashboards = %{_epoch_prefix}%{version}-%{release}
Requires: ceph-prometheus-alerts = %{_epoch_prefix}%{version}-%{release}
+Requires: python%{python3_pkgversion}-setuptools
%if 0%{?fedora} || 0%{?rhel}
Requires: python%{python3_pkgversion}-cherrypy
Requires: python%{python3_pkgversion}-jwt
Requires: python%{python3_pkgversion}-pyOpenSSL
Requires: python%{python3_pkgversion}-requests
Requires: python%{python3_pkgversion}-dateutil
+Requires: python%{python3_pkgversion}-setuptools
%if 0%{?fedora} || 0%{?rhel} >= 8
Requires: python%{python3_pkgversion}-cherrypy
Requires: python%{python3_pkgversion}-pyyaml
%description -n cephfs-mirror
Daemon for mirroring CephFS snapshots between Ceph clusters.
+%package -n ceph-exporter
+Summary: Daemon for exposing perf counters as Prometheus metrics
+%if 0%{?suse_version}
+Group: System/Filesystems
+%endif
+Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
+%description -n ceph-exporter
+Daemon for exposing perf counters as Prometheus metrics
+
%package -n rbd-fuse
Summary: Ceph fuse-based client
%if 0%{?suse_version}
# common
#################################################################################
%prep
-%autosetup -p1 -n ceph-17.2.1
+%autosetup -p1 -n ceph-17.2.6
%build
# Disable lto on systems that do not support symver attribute
%define _lto_cflags %{nil}
%endif
-%if 0%{with seastar} && 0%{?rhel}
-. /opt/rh/gcc-toolset-9/enable
-%endif
-
%if 0%{with cephfs_java}
# Find jni.h
for i in /usr/{lib64,lib}/jvm/java/include{,/linux}; do
mkdir -p %{_vpath_builddir}
pushd %{_vpath_builddir}
cmake .. \
+%if 0%{?suse_version} == 1500
+ -DCMAKE_C_COMPILER=gcc-11 \
+ -DCMAKE_CXX_COMPILER=g++-11 \
+%endif
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DCMAKE_INSTALL_LIBDIR:PATH=%{_libdir} \
-DCMAKE_INSTALL_LIBEXECDIR:PATH=%{_libexecdir} \
-DWITH_MANPAGE:BOOL=ON \
-DWITH_PYTHON3:STRING=%{python3_version} \
-DWITH_MGR_DASHBOARD_FRONTEND:BOOL=OFF \
+%if 0%{?suse_version}
+ -DWITH_RADOSGW_SELECT_PARQUET:BOOL=OFF \
+%endif
%if 0%{without ceph_test_package}
-DWITH_TESTS:BOOL=OFF \
%endif
%endif
%if 0%{with system_utf8proc}
-DWITH_SYSTEM_UTF8PROC:BOOL=ON \
+%endif
+%if 0%{with seastar}
+ -DWITH_SEASTAR:BOOL=ON \
+ -DWITH_JAEGER:BOOL=OFF \
%endif
-DWITH_GRAFANA:BOOL=ON
%install
+
pushd %{_vpath_builddir}
%make_install
# we have dropped sysvinit bits
chmod 0600 %{buildroot}%{_sharedstatedir}/cephadm/.ssh/authorized_keys
# firewall templates and /sbin/mount.ceph symlink
-%if 0%{?suse_version} && !0%{?usrmerged}
+%if 0%{?suse_version} && 0%{?suse_version} < 1550
mkdir -p %{buildroot}/sbin
ln -sf %{_sbindir}/mount.ceph %{buildroot}/sbin/mount.ceph
%endif
%if ! 0%{?suse_version}
%postun -n cephadm
-userdel -r cephadm || true
-exit 0
+[ $1 -ne 0 ] || userdel cephadm || :
%endif
%files -n cephadm
%{_bindir}/rbd-replay-many
%{_bindir}/rbdmap
%{_sbindir}/mount.ceph
-%if 0%{?suse_version} && !0%{?usrmerged}
+%if 0%{?suse_version} && 0%{?suse_version} < 1550
/sbin/mount.ceph
%endif
%if %{with lttng}
fi
fi
+%files -n ceph-exporter
+%{_bindir}/ceph-exporter
+
%files -n rbd-fuse
%{_bindir}/rbd-fuse
%{_mandir}/man8/rbd-fuse.8*