summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick McLean <chutzpah@gentoo.org>2017-08-31 18:45:53 -0700
committerPatrick McLean <chutzpah@gentoo.org>2017-08-31 18:45:53 -0700
commit36e2a6eb3dcb8f4d62830c2eeccae3c5c680291d (patch)
treeb92e4f0e0a55415f32945a4f72f3ad9c5553134a /sys-cluster
parentapp-emulation/qemu: version bump to 2.10.0, bug #629350 (diff)
downloadgentoo-36e2a6eb3dcb8f4d62830c2eeccae3c5c680291d.tar.gz
gentoo-36e2a6eb3dcb8f4d62830c2eeccae3c5c680291d.tar.bz2
gentoo-36e2a6eb3dcb8f4d62830c2eeccae3c5c680291d.zip
sys-cluster/ceph: Version bump to 12.2.0
Package-Manager: Portage-2.3.8, Repoman-2.3.3
Diffstat (limited to 'sys-cluster')
-rw-r--r--sys-cluster/ceph/Manifest1
-rw-r--r--sys-cluster/ceph/ceph-12.2.0.ebuild272
-rw-r--r--sys-cluster/ceph/files/ceph-12.2.0-fix_two_stray_get_health_callers.patch46
-rw-r--r--sys-cluster/ceph/files/ceph-12.2.0-use-provided-cpu-flag-values.patch37
-rw-r--r--sys-cluster/ceph/metadata.xml1
5 files changed, 357 insertions, 0 deletions
diff --git a/sys-cluster/ceph/Manifest b/sys-cluster/ceph/Manifest
index 5f0cc0c66766..ba05389cad13 100644
--- a/sys-cluster/ceph/Manifest
+++ b/sys-cluster/ceph/Manifest
@@ -3,4 +3,5 @@ DIST ceph-10.2.3.tar.gz 11596171 SHA256 dca933aa14db67b404d836ef510bd418091978ed
DIST ceph-10.2.7.tar.gz 14518491 SHA256 2cdfeaa9a08e94c2d35f540b450bbf64b2a694bd537679834185e98fc59d8ba2 SHA512 7e0686e9efa4ddd9d548f4145b448f8232f1ca29b08428daa5cd60a74ce26f1176a1f2ebbf2ac1761d9e6c1d364a5ffa194d2b3a18a8111f59b7c27f7a1d7734 WHIRLPOOL b6b6902230401b5f4c6f27801f315678bdc7b99aab4e50b54d941fc3a425b4f0fa9390484f2e12d6b4f962253fb8772fb706dad35d490b4542b06db166fab59b
DIST ceph-10.2.8.tar.gz 14548472 SHA256 f284743b007cbb61fc9849dc2249942886116c2cb2abcd346d2304d52b16eaaa SHA512 1f3bf81bf6745033e034c3c4e4f05db5c39b2e8435da20fc130971559e8fde0d640bf00bfaafb374d24c45f873e7d768ae9d7d8cd3388347f5804c4bfc303f09 WHIRLPOOL a8bf29ff913c08d423beb0fefa792c06a653d8ac00bd698b7f77bbaf4657f0530ad5a43043dabb24308ed5a4e569fec53130a78d78d8eddf16026a942de8cc40
DIST ceph-10.2.9.tar.gz 14550219 SHA256 3d93f4fc4a66b1d9f9ce43f65868dc18287cea32fbb2c7421faca6aed2b52a80 SHA512 1d59146614aa87ca551b05b795a684071a3cfb4ce6013e978ba650403c6732b2aa13f3c3cc191e6a1ea34b4631c82e97700593c24e200c41ec2f2b43b3ef5547 WHIRLPOOL 42215d33c4f617087e1b0ef81cd41b42330c3605acf625b0668d44eba9e982239683b466a1cc1a6f926fc1d439dfd6be4ce220f783da7d2214d36a2a6cc9181f
+DIST ceph-12.2.0.tar.gz 148372459 SHA256 0f601a9e28e9ce6837119b3ef0d89e1e44e0432f1f5d55567a947efefdd4d4ce SHA512 e084109c48f5666e35df5ee49262dee36ba5e7620fda30002dec538a87de11bdd21157436b5656557cd909a0943071046f3a17dd679aa1129b88b8b925f73113 WHIRLPOOL 60016eb5a20159bfc74b16c4135055cf8bf68bd868ef897b2455107a1014d4663efd55e6f5977e7d2e29010660a59d6134e3af32922d15dccbae07145c9023ea
DIST ceph-9.2.1.tar.gz 9933444 SHA256 1918dfc3df80df5986c5b7ff6bc6c78064eef0f6c5e8269dba30e08c703a7c2f SHA512 1e84c1e2d64f4156a523658ed11552b045f75986922b7b7dbaf4719e73a0a6aadc71eb2b94ae363526f729534a592921a437468a41a3cea88c1b84e09de8505a WHIRLPOOL 3a0eb6712e5b0235707e86129e1d66f1184f50cd4980c30f6d8cc0e7dfd96d30b91177ed16dd7abf2ad4983c6a543eb91915f74f661f7d3e3c810b5b1d656aca
diff --git a/sys-cluster/ceph/ceph-12.2.0.ebuild b/sys-cluster/ceph/ceph-12.2.0.ebuild
new file mode 100644
index 000000000000..86ffb9c4feff
--- /dev/null
+++ b/sys-cluster/ceph/ceph-12.2.0.ebuild
@@ -0,0 +1,272 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+PYTHON_COMPAT=( python{2_7,3_{4,5,6}} )
+DISTUTILS_OPTIONAL=1
+
+inherit check-reqs cmake-utils distutils-r1 python-r1 udev user systemd \
+ readme.gentoo-r1 flag-o-matic
+
+if [[ ${PV} == *9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/ceph/ceph.git"
+ SRC_URI=""
+else
+ SRC_URI="https://download.ceph.com/tarballs/${P}.tar.gz"
+ KEYWORDS="~amd64 ~arm64 ~x86"
+fi
+
+DESCRIPTION="Ceph distributed filesystem"
+HOMEPAGE="https://ceph.com/"
+
+LICENSE="LGPL-2.1 CC-BY-SA-1.0 GPL-2 BSD Boost-1.0 MIT"
+SLOT="0"
+
+CPU_FLAGS_X86=(sse{,2,3,4_1,4_2} ssse3)
+
+IUSE="babeltrace cephfs fuse jemalloc ldap lttng +mgr nss +radosgw +ssl"
+IUSE+=" static-libs systemd +tcmalloc test xfs zfs"
+IUSE+=" $(printf "cpu_flags_x86_%s\n" ${CPU_FLAGS_X86[@]})"
+
+# unbundling code commented out pending bugs 584056 and 584058
+#>=dev-libs/jerasure-2.0.0-r1
+#>=dev-libs/gf-complete-2.0.0
+COMMON_DEPEND="
+ app-arch/bzip2:=[static-libs?]
+ app-arch/lz4:=[static-libs?]
+ app-arch/snappy:=[static-libs?]
+ app-arch/zstd:=[static-libs?]
+ app-misc/jq:=[static-libs?]
+ dev-libs/boost:=[threads,context,static-libs?]
+ dev-libs/crypto++:=[static-libs?]
+ dev-libs/leveldb:=[snappy,static-libs?]
+ dev-libs/libaio:=[static-libs?]
+ dev-libs/libxml2:=[static-libs?]
+ sys-apps/keyutils:=[static-libs?]
+ sys-apps/util-linux:=[static-libs?]
+ sys-libs/zlib:=[static-libs?]
+ babeltrace? ( dev-util/babeltrace )
+ ldap? ( net-nds/openldap:=[static-libs?] )
+ lttng? ( dev-util/lttng-ust:= )
+ nss? ( dev-libs/nss:= )
+ fuse? ( sys-fs/fuse:0=[static-libs?] )
+ ssl? ( dev-libs/openssl:=[static-libs?] )
+ xfs? ( sys-fs/xfsprogs:=[static-libs?] )
+ zfs? ( sys-fs/zfs:=[static-libs?] )
+ radosgw? (
+ dev-libs/expat:=[static-libs?]
+ dev-libs/openssl:=[static-libs?]
+ net-misc/curl:=[static-libs?]
+ )
+ jemalloc? ( dev-libs/jemalloc:=[static-libs?] )
+ !jemalloc? ( >=dev-util/google-perftools-2.4:=[static-libs?] )
+ ${PYTHON_DEPS}
+ "
+DEPEND="${COMMON_DEPEND}
+ app-arch/cpio
+ dev-lang/yasm
+ dev-python/cython[${PYTHON_USEDEP}]
+ dev-python/sphinx
+ dev-util/gperf
+ dev-util/valgrind
+ sys-apps/which
+ sys-devel/bc
+ virtual/pkgconfig
+ test? (
+ dev-python/tox[${PYTHON_USEDEP}]
+ dev-python/virtualenv[${PYTHON_USEDEP}]
+ sys-apps/grep[pcre]
+ sys-fs/btrfs-progs
+ )"
+RDEPEND="${COMMON_DEPEND}
+ net-misc/socat
+ sys-apps/gptfdisk
+ sys-block/parted
+ sys-fs/cryptsetup
+ !<sys-apps/openrc-0.26.3
+ dev-python/cherrypy[${PYTHON_USEDEP}]
+ dev-python/flask[${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}]
+ "
+REQUIRED_USE="
+ $(python_gen_useflags 'python2*')
+ ${PYTHON_REQUIRED_USE}
+ ?? ( ssl nss )
+ ?? ( jemalloc tcmalloc )
+ "
+
+# radosgw seems to be required to actually build
+REQUIRED_USE+=" radosgw"
+
+RESTRICT="test? ( userpriv )"
+
+# distribution tarball does not include everything needed for tests
+RESTRICT+=" test"
+
+STRIP_MASK="/usr/lib*/rados-classes/*"
+
+UNBUNDLE_LIBS=(
+ src/erasure-code/jerasure/jerasure
+ src/erasure-code/jerasure/gf-complete
+)
+
+PATCHES=(
+ "${FILESDIR}/${PN}-12.2.0-use-provided-cpu-flag-values.patch"
+
+ # pull in some bugfixes from upstream
+ "${FILESDIR}/${PN}-12.2.0-fix_two_stray_get_health_callers.patch"
+)
+
+check-reqs_export_vars() {
+ if use amd64; then
+ CHECKREQS_DISK_BUILD="12G"
+ CHECKREQS_DISK_USR="460M"
+ else
+ CHECKREQS_DISK_BUILD="1400M"
+ CHECKREQS_DISK_USR="450M"
+ fi
+
+ export CHECKREQS_DISK_BUILD CHECKREQS_DISK_USR
+}
+
+user_setup() {
+ enewgroup ceph ${CEPH_GID:--1}
+ enewuser ceph "${CEPH_UID:--1}" -1 /var/lib/ceph ceph
+}
+
+pkg_pretend() {
+ check-reqs_export_vars
+ check-reqs_pkg_pretend
+}
+
+pkg_setup() {
+ python_setup 'python2*'
+ check-reqs_export_vars
+ check-reqs_pkg_setup
+ user_setup
+}
+
+src_prepare() {
+ default
+
+ # remove tests that need root access
+ rm src/test/cli/ceph-authtool/cap*.t
+
+ #rm -rf "${UNBUNDLE_LIBS[@]}"
+}
+
+ceph_src_configure() {
+ local flag
+ local mycmakeargs=(
+ -DWITH_BABELTRACE=$(usex babeltrace)
+ -DWITH_CEPHFS=$(usex cephfs)
+ -DWITH_FUSE=$(usex fuse)
+ -DWITH_LTTNG=$(usex lttng)
+ -DWITH_MGR=$(usex mgr)
+ -DWITH_NSS=$(usex nss)
+ -DWITH_OPENLDAP=$(usex ldap)
+ -DWITH_RADOSGW=$(usex radosgw)
+ -DWITH_SSL=$(usex ssl)
+ -DWITH_SYSTEMD=$(usex systemd)
+ -DWITH_TESTS=$(usex test)
+ -DWITH_XFS=$(usex xfs)
+ -DWITH_ZFS=$(usex zfs)
+ -DENABLE_SHARED=$(usex static-libs '' 'yes' 'no')
+ -DALLOCATOR=$(usex tcmalloc 'tcmalloc' '' "$(usex jemalloc 'jemalloc' '' 'libc' '')" '')
+ -DWITH_SYSTEM_BOOST=yes
+ -DWITH_RDMA=no
+ )
+ if use amd64 || use x86; then
+ for flag in ${CPU_FLAGS_X86[@]}; do
+ mycmakeargs+=("$(usex cpu_flags_x86_${flag} "-DHAVE_INTEL_${flag^^}=1")")
+ done
+ fi
+
+ rm -f "${BUILD_DIR:-${S}}/CMakeCache.txt"
+ cmake-utils_src_configure
+}
+
+src_configure() {
+ ceph_src_configure
+}
+
+python_compile() {
+ local CMAKE_USE_DIR="${S}"
+
+ ceph_src_configure
+ pushd "${BUILD_DIR}/src/pybind" >/dev/null || die
+ emake VERBOSE=1 all
+
+ # python modules are only compiled with "make install" so we need to do this to
+ # prevent doing a bunch of compilation in src_install
+ DESTDIR="${T}" emake VERBOSE=1 install
+ popd >/dev/null || die
+}
+
+src_compile() {
+ cmake-utils_src_make all
+
+ # we have to do this here to prevent from building everything multiple times
+ BUILD_DIR="${CMAKE_BUILD_DIR}" python_copy_sources
+ python_foreach_impl python_compile
+}
+
+src_test() {
+ make check || die "make check failed"
+}
+
+python_install() {
+ local CMAKE_USE_DIR="${S}"
+ pushd "${BUILD_DIR}/src/pybind" >/dev/null || die
+ DESTDIR="${D}" emake install
+ popd >/dev/null || die
+}
+
+src_install() {
+ cmake-utils_src_install
+ python_foreach_impl python_install
+
+ prune_libtool_files --all
+
+ exeinto /usr/$(get_libdir)/ceph
+ newexe "${CMAKE_BUILD_DIR}/bin/init-ceph" ceph_init.sh
+
+ insinto /etc/logrotate.d/
+ newins "${FILESDIR}"/ceph.logrotate ${PN}
+
+ keepdir /var/lib/${PN}{,/tmp} /var/log/${PN}/stat
+
+ fowners -R ceph:ceph /var/lib/ceph /var/log/ceph
+
+ newinitd "${FILESDIR}/rbdmap.initd" rbdmap
+ newinitd "${FILESDIR}/${PN}.initd-r5" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd-r3" ${PN}
+
+ insinto /etc/sysctl.d
+ newins "${FILESDIR}"/sysctld 90-${PN}.conf
+
+ use tcmalloc && newenvd "${FILESDIR}"/envd-tcmalloc 99${PN}-tcmalloc
+
+ systemd_install_serviced "${FILESDIR}/ceph-mds_at.service.conf" "ceph-mds@.service"
+ systemd_install_serviced "${FILESDIR}/ceph-osd_at.service.conf" "ceph-osd@.service"
+
+ udev_dorules udev/*.rules
+
+ readme.gentoo_create_doc
+
+ python_setup 'python2*'
+ python_fix_shebang "${ED}"/usr/{,s}bin/
+
+ # python_fix_shebang apparently is not idempotent
+ sed -i -r 's:(/usr/lib/python-exec/python[0-9]\.[0-9]/python)[0-9]\.[0-9]:\1:' \
+ "${ED}"/usr/{sbin/ceph-disk,bin/ceph-detect-init} || die "sed failed"
+}
+
+pkg_postinst() {
+ readme.gentoo_print_elog
+}
diff --git a/sys-cluster/ceph/files/ceph-12.2.0-fix_two_stray_get_health_callers.patch b/sys-cluster/ceph/files/ceph-12.2.0-fix_two_stray_get_health_callers.patch
new file mode 100644
index 000000000000..ec6f53ef4612
--- /dev/null
+++ b/sys-cluster/ceph/files/ceph-12.2.0-fix_two_stray_get_health_callers.patch
@@ -0,0 +1,46 @@
+commit b713cc831da238844a6e42e80e93cb31ee060aad
+Author: Sage Weil <sage@redhat.com>
+Date: Fri Aug 25 18:30:12 2017 -0400
+
+ mon: fix two stray legacy get_health() callers
+
+ These need to call the new method when appropriate.
+
+ Signed-off-by: Sage Weil <sage@redhat.com>
+ (cherry picked from commit 69038a18070d0cd47dc857020cce115514beaa3d)
+
+diff --git a/src/mon/Monitor.cc b/src/mon/Monitor.cc
+index d98a40967b..b330d78f8c 100644
+--- a/src/mon/Monitor.cc
++++ b/src/mon/Monitor.cc
+@@ -3363,8 +3363,12 @@ void Monitor::handle_command(MonOpRequestRef op)
+ tagstr = tagstr.substr(0, tagstr.find_last_of(' '));
+ f->dump_string("tag", tagstr);
+
+- list<string> hs;
+- get_health(hs, NULL, f.get());
++ if (osdmon()->osdmap.require_osd_release >= CEPH_RELEASE_LUMINOUS) {
++ get_health_status(true, f.get(), nullptr);
++ } else {
++ list<string> health_str;
++ get_health(health_str, nullptr, f.get());
++ }
+
+ monmon()->dump_info(f.get());
+ osdmon()->dump_info(f.get());
+@@ -4399,8 +4403,13 @@ void Monitor::handle_ping(MonOpRequestRef op)
+ boost::scoped_ptr<Formatter> f(new JSONFormatter(true));
+ f->open_object_section("pong");
+
+- list<string> health_str;
+- get_health(health_str, NULL, f.get());
++ if (osdmon()->osdmap.require_osd_release >= CEPH_RELEASE_LUMINOUS) {
++ get_health_status(false, f.get(), nullptr);
++ } else {
++ list<string> health_str;
++ get_health(health_str, nullptr, f.get());
++ }
++
+ {
+ stringstream ss;
+ get_mon_status(f.get(), ss);
diff --git a/sys-cluster/ceph/files/ceph-12.2.0-use-provided-cpu-flag-values.patch b/sys-cluster/ceph/files/ceph-12.2.0-use-provided-cpu-flag-values.patch
new file mode 100644
index 000000000000..55c82b0a272b
--- /dev/null
+++ b/sys-cluster/ceph/files/ceph-12.2.0-use-provided-cpu-flag-values.patch
@@ -0,0 +1,37 @@
+diff --git a/cmake/modules/SIMDExt.cmake b/cmake/modules/SIMDExt.cmake
+index 5330835aa1..a4dd881e34 100644
+--- a/cmake/modules/SIMDExt.cmake
++++ b/cmake/modules/SIMDExt.cmake
+@@ -76,32 +76,25 @@ elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "arm|ARM")
+ elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "i386|i686|amd64|x86_64|AMD64")
+ set(HAVE_INTEL 1)
+ if(CMAKE_SYSTEM_PROCESSOR MATCHES "i686|amd64|x86_64|AMD64")
+- CHECK_C_COMPILER_FLAG(-msse HAVE_INTEL_SSE)
+ if(HAVE_INTEL_SSE)
+ set(SIMD_COMPILE_FLAGS "${SIMD_COMPILE_FLAGS} -msse")
+ endif()
+ if(CMAKE_SYSTEM_PROCESSOR MATCHES "amd64|x86_64|AMD64")
+- CHECK_C_COMPILER_FLAG(-msse2 HAVE_INTEL_SSE2)
+ if(HAVE_INTEL_SSE2)
+ set(SIMD_COMPILE_FLAGS "${SIMD_COMPILE_FLAGS} -msse2")
+ endif()
+- CHECK_C_COMPILER_FLAG(-msse3 HAVE_INTEL_SSE3)
+ if(HAVE_INTEL_SSE3)
+ set(SIMD_COMPILE_FLAGS "${SIMD_COMPILE_FLAGS} -msse3")
+ endif()
+- CHECK_C_COMPILER_FLAG(-mssse3 HAVE_INTEL_SSSE3)
+ if(HAVE_INTEL_SSSE3)
+ set(SIMD_COMPILE_FLAGS "${SIMD_COMPILE_FLAGS} -mssse3")
+ endif()
+- CHECK_C_COMPILER_FLAG(-mpclmul HAVE_INTEL_PCLMUL)
+ if(HAVE_INTEL_PCLMUL)
+ set(SIMD_COMPILE_FLAGS "${SIMD_COMPILE_FLAGS} -mpclmul")
+ endif()
+- CHECK_C_COMPILER_FLAG(-msse4.1 HAVE_INTEL_SSE4_1)
+ if(HAVE_INTEL_SSE4_1)
+ set(SIMD_COMPILE_FLAGS "${SIMD_COMPILE_FLAGS} -msse4.1")
+ endif()
+- CHECK_C_COMPILER_FLAG(-msse4.2 HAVE_INTEL_SSE4_2)
+ if(HAVE_INTEL_SSE4_2)
+ set(SIMD_COMPILE_FLAGS "${SIMD_COMPILE_FLAGS} -msse4.2")
+ endif()
diff --git a/sys-cluster/ceph/metadata.xml b/sys-cluster/ceph/metadata.xml
index 958ea7ee16d9..be0d84faee0b 100644
--- a/sys-cluster/ceph/metadata.xml
+++ b/sys-cluster/ceph/metadata.xml
@@ -26,6 +26,7 @@ Ceph is a distributed network file system designed to provide excellent performa
<flag name="libaio">Use libaio as asynchronous input/output library</flag>
<flag name="lttng">Add support for LTTng</flag>
<flag name="babeltrace">Add support for LTTng babeltrace</flag>
+ <flag name="mgr">Build the ceph-mgr daemon</flag>
<flag name="nss">Use <pkg>dev-libs/nss</pkg> for cryptography</flag>
<flag name="radosgw">Add radosgw support</flag>
<flag name="jemalloc">Use <pkg>dev-libs/jemalloc</pkg> for allocations</flag>