diff --git a/community/ceph/10-musl-fixes.patch b/community/ceph16/10-musl-fixes.patch similarity index 100% rename from community/ceph/10-musl-fixes.patch rename to community/ceph16/10-musl-fixes.patch diff --git a/community/ceph/11-dump_time_header_impl.patch b/community/ceph16/11-dump_time_header_impl.patch similarity index 100% rename from community/ceph/11-dump_time_header_impl.patch rename to community/ceph16/11-dump_time_header_impl.patch diff --git a/community/ceph/11-parse_rfc1123_alt.patch b/community/ceph16/11-parse_rfc1123_alt.patch similarity index 100% rename from community/ceph/11-parse_rfc1123_alt.patch rename to community/ceph16/11-parse_rfc1123_alt.patch diff --git a/community/ceph/11-s3_expiration_header.patch b/community/ceph16/11-s3_expiration_header.patch similarity index 100% rename from community/ceph/11-s3_expiration_header.patch rename to community/ceph16/11-s3_expiration_header.patch diff --git a/community/ceph/12-package.json-resolutions.patch b/community/ceph16/12-package.json-resolutions.patch similarity index 100% rename from community/ceph/12-package.json-resolutions.patch rename to community/ceph16/12-package.json-resolutions.patch diff --git a/community/ceph/20-pci.patch b/community/ceph16/20-pci.patch similarity index 100% rename from community/ceph/20-pci.patch rename to community/ceph16/20-pci.patch diff --git a/community/ceph/30-32bit_fix.patch.noauto b/community/ceph16/30-32bit_fix.patch.noauto similarity index 100% rename from community/ceph/30-32bit_fix.patch.noauto rename to community/ceph16/30-32bit_fix.patch.noauto diff --git a/community/ceph/30-cypress.patch.noauto b/community/ceph16/30-cypress.patch.noauto similarity index 100% rename from community/ceph/30-cypress.patch.noauto rename to community/ceph16/30-cypress.patch.noauto diff --git a/community/ceph/30-ubuntu-32bit-fixes.patch.noauto b/community/ceph16/30-ubuntu-32bit-fixes.patch.noauto similarity index 100% rename from community/ceph/30-ubuntu-32bit-fixes.patch.noauto rename to community/ceph16/30-ubuntu-32bit-fixes.patch.noauto diff --git a/community/ceph/31-32bit_fix_tests.patch.noauto b/community/ceph16/31-32bit_fix_tests.patch.noauto similarity index 100% rename from community/ceph/31-32bit_fix_tests.patch.noauto rename to community/ceph16/31-32bit_fix_tests.patch.noauto diff --git a/community/ceph/32-upstream32bit.patch b/community/ceph16/32-upstream32bit.patch similarity index 100% rename from community/ceph/32-upstream32bit.patch rename to community/ceph16/32-upstream32bit.patch diff --git a/community/ceph/32-upstream32bitcleanup.patch b/community/ceph16/32-upstream32bitcleanup.patch similarity index 100% rename from community/ceph/32-upstream32bitcleanup.patch rename to community/ceph16/32-upstream32bitcleanup.patch diff --git a/community/ceph/35-fix_ErasureCodeShec.patch b/community/ceph16/35-fix_ErasureCodeShec.patch similarity index 100% rename from community/ceph/35-fix_ErasureCodeShec.patch rename to community/ceph16/35-fix_ErasureCodeShec.patch diff --git a/community/ceph/37-fix_tests.patch b/community/ceph16/37-fix_tests.patch similarity index 100% rename from community/ceph/37-fix_tests.patch rename to community/ceph16/37-fix_tests.patch diff --git a/community/ceph/40-nasm.patch b/community/ceph16/40-nasm.patch similarity index 100% rename from community/ceph/40-nasm.patch rename to community/ceph16/40-nasm.patch diff --git a/community/ceph/42-no-virtualenvs.patch b/community/ceph16/42-no-virtualenvs.patch similarity index 100% rename from community/ceph/42-no-virtualenvs.patch rename to community/ceph16/42-no-virtualenvs.patch diff --git a/community/ceph/43-LogClock.h.patch b/community/ceph16/43-LogClock.h.patch similarity index 100% rename from community/ceph/43-LogClock.h.patch rename to community/ceph16/43-LogClock.h.patch diff --git a/community/ceph/44-aarch64-erasure.patch b/community/ceph16/44-aarch64-erasure.patch similarity index 100% rename from community/ceph/44-aarch64-erasure.patch rename to community/ceph16/44-aarch64-erasure.patch diff --git a/community/ceph/44-cmake-buildtype.patch b/community/ceph16/44-cmake-buildtype.patch similarity index 100% rename from community/ceph/44-cmake-buildtype.patch rename to community/ceph16/44-cmake-buildtype.patch diff --git a/community/ceph/44-gcc-warnings.patch b/community/ceph16/44-gcc-warnings.patch similarity index 100% rename from community/ceph/44-gcc-warnings.patch rename to community/ceph16/44-gcc-warnings.patch diff --git a/community/ceph/44-missing-include.patch b/community/ceph16/44-missing-include.patch similarity index 100% rename from community/ceph/44-missing-include.patch rename to community/ceph16/44-missing-include.patch diff --git a/community/ceph/44-staticcast.patch b/community/ceph16/44-staticcast.patch similarity index 100% rename from community/ceph/44-staticcast.patch rename to community/ceph16/44-staticcast.patch diff --git a/community/ceph/45-python.patch b/community/ceph16/45-python.patch similarity index 100% rename from community/ceph/45-python.patch rename to community/ceph16/45-python.patch diff --git a/community/ceph/46-fmt9.patch b/community/ceph16/46-fmt9.patch similarity index 100% rename from community/ceph/46-fmt9.patch rename to community/ceph16/46-fmt9.patch diff --git a/community/ceph/APKBUILD b/community/ceph16/APKBUILD similarity index 86% rename from community/ceph/APKBUILD rename to community/ceph16/APKBUILD index 11782624c16..2e7267469d1 100644 --- a/community/ceph/APKBUILD +++ b/community/ceph16/APKBUILD @@ -2,9 +2,11 @@ # Contributor: Iggy Jackson # Contributor: Duncan Bellamy # Maintainer: Duncan Bellamy -pkgname=ceph +_pkgname=ceph pkgver=16.2.10 -pkgrel=7 +pkgrel=8 +_majorver=${pkgver%%.*} +pkgname=$_pkgname$_majorver pkgdesc="Ceph is a distributed object store and file system" pkgusers="ceph" pkggroups="ceph" @@ -13,6 +15,7 @@ arch="all" # https://github.com/ceph/ceph/blob/master/COPYING license="LGPL-2.1-only AND LGPL-2.0-or-later AND GPL-2.0-only AND GPL-3.0-only AND CC-BY-SA-1.0 AND BSL-1.0 AND GPL-2.0-or-later WITH Autoconf-exception-2.0 AND BSD-3-Clause AND MIT AND custom" depends="ceph-osd ceph-mds ceph-mon" +builddir="$srcdir/ceph-$pkgver" _lua=5.3 _base_deps=" cryptsetup @@ -24,7 +27,7 @@ _base_deps=" " _osd_daemon_deps="fuse snappy lz4-libs" _osd_tools_deps="lz4-libs" -_ceph_volume_deps="ceph-common lvm2 py3-ceph-common" +_ceph_volume_deps="$pkgname-common=$pkgver-r$pkgrel lvm2 py3-$pkgname-common=$pkgver-r$pkgrel" _ceph_test_deps=" xmlstarlet py3-coverage @@ -136,6 +139,8 @@ source="https://download.ceph.com/tarballs/ceph_$pkgver.orig.tar.gz $pkgname-gcc12-memory.patch::https://github.com/ceph/ceph/commit/7c381ba985bd1398ef7d145cc00fae9d0db510e3.patch 46-fmt9.patch " +# to prevent things from installing wrong ceph libs, since they have the same SOMAJOR +sonameprefix="ceph$_majorver:so:" subpackages=" $pkgname-doc @@ -157,19 +162,27 @@ subpackages=" $pkgname-dev $pkgname-user::noarch $pkgname-utils - rbd-fuse:rbd_fuse - rbd-mirror:rbd_mirror - rbd-nbd:rbd_nbd - librbd - libcephfs - librados - py3-rados:_py3_rados - libradosstriper - py3-rbd:_py3_rbd - py3-cephfs:_py3_cephfs - py3-ceph-common:_py3_ceph_common + rbd-fuse$_majorver:rbd_fuse + rbd-mirror$_majorver:rbd_mirror + rbd-nbd$_majorver:rbd_nbd + librbd$_majorver:librbd + libcephfs$_majorver:libcephfs + librados$_majorver:librados + py3-rados$_majorver:_py3_rados + libradosstriper$_majorver:libradosstriper + py3-rbd$_majorver:_py3_rbd + py3-cephfs$_majorver:_py3_cephfs + py3-$pkgname-common:_py3_ceph_common " +# Whether this package is the default (latest) ceph version. +_default_ceph="yes" + +if [ "$_default_ceph" = yes ]; then + provides="ceph=$pkgver-r$pkgrel" + replaces="ceph" +fi + # secfixes: # 16.2.10-r0: # - CVE-2022-0670 @@ -281,8 +294,8 @@ package() { # remove the upstream init file and put in openrc ones rm -f "$pkgdir"/etc/init.d/ceph - install -D -m 755 "$srcdir"/"$pkgname".initd "$pkgdir"/etc/init.d/ceph - install -D -m 644 "$srcdir"/"$pkgname".confd "$pkgdir"/etc/conf.d/ceph + install -D -m 755 "$srcdir"/"$_pkgname".initd "$pkgdir"/etc/init.d/ceph + install -D -m 644 "$srcdir"/"$_pkgname".confd "$pkgdir"/etc/conf.d/ceph # move mount.* binaries to /sbin mkdir -p "$pkgdir"/sbin @@ -319,6 +332,8 @@ user() { pkgdesc="Minimal package to create a user for other ceph packages." depends="" install="$pkgname-user.pre-install" + _default_replace_majorversion + mkdir -p "$subpkgdir" } @@ -327,10 +342,11 @@ base() { depends="$_base_deps $pkgname-user=$pkgver-r$pkgrel $pkgname-common=$pkgver-r$pkgrel - librbd=$pkgver-r$pkgrel - librados=$pkgver-r$pkgrel - libcephfs=$pkgver-r$pkgrel + librbd$_majorver=$pkgver-r$pkgrel + librados$_majorver=$pkgver-r$pkgrel + libcephfs$_majorver=$pkgver-r$pkgrel " + _default_replace_majorversion amove usr/bin/ceph-crash \ usr/bin/crushtool \ @@ -355,7 +371,8 @@ base() { common() { pkgdesc="Common utilities to mount and interact with a ceph storage cluster." - depends="eudev py3-rados py3-rbd py3-cephfs py3-prettytable" + depends="eudev py3-rados$_majorver=$pkgver-r$pkgrel py3-rbd$_majorver=$pkgver-r$pkgrel py3-cephfs$_majorver=$pkgver-r$pkgrel py3-prettytable" + _default_replace_majorversion amove usr/bin/ceph \ usr/bin/ceph-authtool \ @@ -379,7 +396,8 @@ common() { mds() { pkgdesc="Metadata server daemon for the Ceph distributed file system." - depends="ceph-base" + depends="$pkgname-base=$pkgver-r$pkgrel" + _default_replace_majorversion amove usr/bin/ceph-mds install -m 750 -o $_ceph_uid -g $_ceph_gid -d \ @@ -388,9 +406,10 @@ mds() { mon() { pkgdesc="Cluster monitor daemon virtual package for the Ceph distributed file system." - depends="$pkgname-base + depends="$pkgname-base=$pkgver-r$pkgrel $pkgname-mon-daemon=$pkgver-r$pkgrel $pkgname-mon-tools=$pkgver-r$pkgrel" + _default_replace_majorversion mkdir -p "$subpkgdir" } @@ -398,6 +417,7 @@ mon() { mon_daemon() { pkgdesc="Cluster monitor daemon for the Ceph distributed file system." depends="$pkgname-user=$pkgver-r$pkgrel" + _default_replace_majorversion amove usr/bin/ceph-mon install -m 750 -o $_ceph_uid -g $_ceph_gid -d \ @@ -407,6 +427,7 @@ mon_daemon() { mon_tools() { pkgdesc="Cluster monitor tools for the Ceph distributed file system." depends= + _default_replace_majorversion amove usr/bin/ceph-monstore-tool install -m 750 -o $_ceph_uid -g $_ceph_gid -d \ @@ -416,6 +437,7 @@ mon_tools() { ceph_fuse() { pkgdesc="FUSE based client for Ceph distributed network file system." depends= + _default_replace_majorversion amove usr/bin/ceph-fuse sbin/mount.fuse.ceph } @@ -423,13 +445,15 @@ ceph_fuse() { rbd_fuse() { pkgdesc="FUSE based client to map Ceph rbd images to files." depends= + _default_replace_majorversion amove usr/bin/rbd-fuse } rbd_mirror() { pkgdesc="Daemon for mirroring RBD images between Ceph clusters." - depends="ceph-common=$pkgver-r$pkgrel" + depends="$pkgname-common=$pkgver-r$pkgrel" + _default_replace_majorversion amove usr/bin/rbd-mirror } @@ -437,13 +461,15 @@ rbd_mirror() { rbd_nbd() { pkgdesc="NBD based client to map Ceph rbd images to local device." depends= + _default_replace_majorversion amove usr/bin/rbd-nbd } radosgw() { pkgdesc="Rados REST gateway which implements Amazon's S3 and OpenStack's Swift APIs." - depends="ceph-common oath-toolkit-liboath" + depends="$pkgname-common=$pkgver-r$pkgrel oath-toolkit-liboath" + _default_replace_majorversion amove usr/bin/radosgw* mkdir -p "$subpkgdir"/var/lib/ceph/radosgw @@ -454,6 +480,7 @@ osd() { depends="$pkgname-osd-daemon=$pkgver-r$pkgrel $pkgname-osd-tools=$pkgver-r$pkgrel $pkgname-volume=$pkgver-r$pkgrel" + _default_replace_majorversion mkdir -p "$subpkgdir" } @@ -461,6 +488,7 @@ osd() { osd_daemon() { pkgdesc="Object storage daemon for the Ceph distributed file system." depends="$_osd_daemon_deps $pkgname-user=$pkgver-r$pkgrel" + _default_replace_majorversion amove usr/bin/ceph-osd \ usr/libexec/ceph/ceph-osd-prestart.sh \ @@ -473,6 +501,7 @@ osd_daemon() { osd_tools() { pkgdesc="Object storage daemon tools for the Ceph distributed file system." depends="$pkgname-base=$pkgver-r$pkgrel $_osd_tools_deps" + _default_replace_majorversion amove usr/bin/ceph-clsinfo usr/bin/ceph-*-tool install -m 750 -o $_ceph_uid -g $_ceph_gid -d \ @@ -482,6 +511,7 @@ osd_tools() { ceph_volume() { pkgdesc="ceph-volume tool for the Ceph distributed file system." depends="$_ceph_volume_deps" + _default_replace_majorversion amove usr/sbin/ceph-volume \ "$(_py3_sitelib)"/ceph_volume "$(_py3_sitelib)"/ceph_volume-* @@ -490,13 +520,15 @@ ceph_volume() { librados() { pkgdesc="RADOS distributed object store client library" depends= + _default_replace_majorversion amove usr/lib/librados.so.* usr/lib/ceph/libceph-common.so.* } _py3_rados() { pkgdesc="Python libraries for the RADOS object store" - depends=py3-ceph-common + depends="py3-$pkgname-common=$pkgver-r$pkgrel" + _default_replace_majorversion amove "$(_py3_sitelib)"/rados* } @@ -504,6 +536,7 @@ _py3_rados() { libradosstriper() { pkgdesc="RADOS striping library" depends= + _default_replace_majorversion amove usr/lib/libradosstriper.so.* } @@ -511,13 +544,15 @@ libradosstriper() { librbd() { pkgdesc="RADOS block device client library" depends= + _default_replace_majorversion amove usr/lib/librbd.so.* } _py3_rbd() { pkgdesc="Python libraries for the RADOS block device" - depends="py3-rados" + depends="py3-rados$_majorver=$pkgver-r$pkgrel" + _default_replace_majorversion amove "$(_py3_sitelib)"/rbd* } @@ -525,13 +560,15 @@ _py3_rbd() { libcephfs() { pkgdesc="Ceph distributed file system client library" depends= + _default_replace_majorversion amove usr/lib/libcephfs.so.* } _py3_cephfs() { pkgdesc="Python libraries for Ceph distributed file system" - depends="py3-rados" + depends="py3-rados$_majorver=$pkgver-r$pkgrel" + _default_replace_majorversion amove "$(_py3_sitelib)"/cephfs* "$(_py3_sitelib)"/ceph_volume_client.py } @@ -539,13 +576,15 @@ _py3_cephfs() { _py3_ceph_common() { pkgdesc="Python dependencies for Ceph distributed file system" depends="py3-setuptools py3-yaml" + _default_replace_majorversion amove "$(_py3_sitelib)"/ceph-*.egg-info "$(_py3_sitelib)"/ceph } utils() { pkgdesc="Ceph utils and recovery tools" - depends="ceph-common=$pkgver-r$pkgrel" + depends="$pkgname-common=$pkgver-r$pkgrel" + _default_replace_majorversion amove usr/bin/ceph-diff-sorted \ usr/bin/ceph-post-file \ @@ -560,6 +599,7 @@ utils() { bash_completion() { pkgdesc="Bash completions for Ceph" depends= + _default_replace_majorversion install_if="ceph=$pkgver-r$pkgrel bash-completion" amove etc/bash_completion.d/* @@ -567,7 +607,8 @@ bash_completion() { mgr() { pkgdesc="Ceph Manager Daemon" - depends="ceph-base=$pkgver-r$pkgrel" + depends="$pkgname-base=$pkgver-r$pkgrel" + _default_replace_majorversion amove usr/bin/ceph-mgr usr/share/ceph/mgr @@ -575,6 +616,13 @@ mgr() { "$subpkgdir"/var/lib/ceph/mgr } +_default_replace_majorversion() { + if [ "$_default_ceph" = yes ]; then + replaces="${subpkgname/"$_majorver"/}" + provides="$replaces=$pkgver-r$pkgrel" + fi +} + sha512sums=" ae164c24462c3e08763d202acc3e2fe86ffc09f312b5059bae07863e804fc47bd158fc130aa2923246ffcfe26ae6d6d9317326aec96373226e6f9030d7123c8b ceph_16.2.10.orig.tar.gz 110bdbcb40216c7ed155a8d23020784741b4992d895f4f04a146d275506e4e68053854d3b063b41e9c9b3e3e4f95b6b90602f92c185c853c0d8f47ad0c6b7121 ceph.confd @@ -602,6 +650,6 @@ bf3ec9b8b7e830ecec566cb2b979a147a0da3fa925b1777e5480f9e728705e8f6245a1b0694d67f5 f89c913a53e2806c59508d26f5dc72abb428c7e4e3b7c1aeb6eaf92744ea9a13cac2f00a2ac90f91ad7682f66d876a5fffedd10feeceecd71a944793581da443 44-staticcast.patch b95ec157f9c77177afd3deb8e3485bb5f10e1b634a15617d14e09b08d6680d32201ecb249ea5ea98127a312e1fdb22fdbe9f0216690291a2849419aa7ab81610 44-missing-include.patch fd0cbe188a1be404c1d6f221367b94d764e78cf61e7ba4e8a8977ebabd467356a3a46e079df3e5dfa3fd301dd7991bd0f2eabca2e9cd28e5edcae24fb9b8456c 45-python.patch -f1b54767d8d3c12ca9fe9eafd0590efa8560a52b5c18f1121f8fd8b7e69d70578bdeae9a1803612a8a8d0032f039f8786b5152a889ba359850e3d3d30a6af8c7 ceph-gcc12-memory.patch +f1b54767d8d3c12ca9fe9eafd0590efa8560a52b5c18f1121f8fd8b7e69d70578bdeae9a1803612a8a8d0032f039f8786b5152a889ba359850e3d3d30a6af8c7 ceph16-gcc12-memory.patch 387812a1a596956e2016f3bf39a59b1b976ba139adc98ace84b0c4b124b4947321d8f6482b30c60402a2546f177418247441639fc02e230e01e16fff851cd61a 46-fmt9.patch " diff --git a/community/ceph/ceph.confd b/community/ceph16/ceph.confd similarity index 100% rename from community/ceph/ceph.confd rename to community/ceph16/ceph.confd diff --git a/community/ceph/ceph.initd b/community/ceph16/ceph.initd similarity index 100% rename from community/ceph/ceph.initd rename to community/ceph16/ceph.initd diff --git a/community/ceph/ceph-user.pre-install b/community/ceph16/ceph16-user.pre-install similarity index 100% rename from community/ceph/ceph-user.pre-install rename to community/ceph16/ceph16-user.pre-install