ceph: 17.2.5 -> 18.2.0
The following issues were encountered during the upgrade: * "Could NOT find thrift (missing: thrift_LIBRARIES thrift_INCLUDE_DIR)" Fixed by disabling Jaeger support, see added comment. * ``` /build/ceph-18.2.0/src/extblkdev/ExtBlkDevInterface.h:38:10: fatal error: sys/capability.h: No such file or directory 38 | #include <sys/capability.h> ``` Fixed by `libcap` dependency. Ceph's Debian dependencies include both `libcap` and `libcap-ng`:c8c946c970/debian/control (L38-L39)
* ``` Manually-specified variables were not used by the project: MGR_PYTHON_VERSION ``` Dropped 4 years ago for Ceph 15:5fc657b40d
So I removed the flag. * Warning: ``` -- Could NOT find nasm ``` Looking at the code (macros such as `HAVE_NASM_X64`), nasm existence actually results in some optimised crypto SIMD instructions being compiled, so we probably want this for performance. Adding `nasm` to `nativeBuildInputs` first brought error: ``` /nix/store/p6dlr3skfhxpyphipg2bqnj52999banh-bash-5.2-p15/bin/bash: line 1: /build/ceph-18.2.0/src/nasm-wrapper: cannot execute: required file not found make[2]: *** [src/crypto/isa-l/CMakeFiles/ceph_crypto_isal.dir/build.make:117: src/crypto/isa-l/CMakeFiles/ceph_crypto_isal.dir/isa-l_crypto/aes/cbc_multibinary.asm.o] Error 127 ``` Solution: `patchShebangs src/nasm-wrapper`, even better `patchShebangs src/`. * ``` Manually-specified variables were not used by the project: WITH_SYSTEM_CIMG WITH_SYSTEM_JSONCPP ``` These never were Ceph CMake options, so I removed them. * `libcap-ng` is Linux-only, and only used for the `mount.ceph` command:c8c946c970/src/CMakeLists.txt (L829-L830)
Thus use it for Linux only. * The Parquet build error is now gone, so we can enable support for it.
This commit is contained in:
parent
5a8e924381
commit
f8262c2cc6
|
@ -11,6 +11,7 @@
|
|||
, fmt
|
||||
, git
|
||||
, makeWrapper
|
||||
, nasm
|
||||
, pkg-config
|
||||
, which
|
||||
|
||||
|
@ -23,14 +24,13 @@
|
|||
, boost179
|
||||
, bzip2
|
||||
, cryptsetup
|
||||
, cimg
|
||||
, cunit
|
||||
, doxygen
|
||||
, gperf
|
||||
, graphviz
|
||||
, gtest
|
||||
, icu
|
||||
, jsoncpp
|
||||
, libcap
|
||||
, libcap_ng
|
||||
, libnl
|
||||
, libxml2
|
||||
|
@ -225,10 +225,10 @@ let
|
|||
]);
|
||||
inherit (ceph-python-env.python) sitePackages;
|
||||
|
||||
version = "17.2.5";
|
||||
version = "18.2.0";
|
||||
src = fetchurl {
|
||||
url = "https://download.ceph.com/tarballs/ceph-${version}.tar.gz";
|
||||
hash = "sha256-NiJpwUeROvh0siSaRoRrDm+C0s61CvRiIrbd7JmRspo=";
|
||||
hash = "sha256:0k9nl6xi5brva51rr14m7ig27mmmd7vrpchcmqc40q3c2khn6ns9";
|
||||
};
|
||||
in rec {
|
||||
ceph = stdenv.mkDerivation {
|
||||
|
@ -240,6 +240,7 @@ in rec {
|
|||
fmt
|
||||
git
|
||||
makeWrapper
|
||||
nasm
|
||||
pkg-config
|
||||
python
|
||||
python.pkgs.python # for the toPythonPath function
|
||||
|
@ -259,14 +260,12 @@ in rec {
|
|||
boost
|
||||
bzip2
|
||||
ceph-python-env
|
||||
cimg
|
||||
cryptsetup
|
||||
cunit
|
||||
gperf
|
||||
gtest
|
||||
jsoncpp
|
||||
icu
|
||||
libcap_ng
|
||||
libcap
|
||||
libnl
|
||||
libxml2
|
||||
lttng-ust
|
||||
|
@ -287,6 +286,7 @@ in rec {
|
|||
zstd
|
||||
] ++ lib.optionals stdenv.isLinux [
|
||||
keyutils
|
||||
libcap_ng
|
||||
liburing
|
||||
libuuid
|
||||
linuxHeaders
|
||||
|
@ -314,22 +314,38 @@ in rec {
|
|||
# install target needs to be in PYTHONPATH for "*.pth support" check to succeed
|
||||
# set PYTHONPATH, so the build system doesn't silently skip installing ceph-volume and others
|
||||
export PYTHONPATH=${ceph-python-env}/${sitePackages}:$lib/${sitePackages}:$out/${sitePackages}
|
||||
patchShebangs src/script src/spdk src/test src/tools
|
||||
patchShebangs src/
|
||||
'';
|
||||
|
||||
cmakeFlags = [
|
||||
"-DCMAKE_INSTALL_DATADIR=${placeholder "lib"}/lib"
|
||||
|
||||
"-DMGR_PYTHON_VERSION=${ceph-python-env.python.pythonVersion}"
|
||||
"-DWITH_CEPHFS_SHELL:BOOL=ON"
|
||||
"-DWITH_SYSTEMD:BOOL=OFF"
|
||||
# `WITH_JAEGER` requires `thrift` as a depenedncy (fine), but the build fails with:
|
||||
# CMake Error at src/opentelemetry-cpp-stamp/opentelemetry-cpp-build-Release.cmake:49 (message):
|
||||
# Command failed: 2
|
||||
#
|
||||
# 'make' 'opentelemetry_trace' 'opentelemetry_exporter_jaeger_trace'
|
||||
#
|
||||
# See also
|
||||
#
|
||||
# /build/ceph-18.2.0/build/src/opentelemetry-cpp/src/opentelemetry-cpp-stamp/opentelemetry-cpp-build-*.log
|
||||
# and that file contains:
|
||||
# /build/ceph-18.2.0/src/jaegertracing/opentelemetry-cpp/exporters/jaeger/src/TUDPTransport.cc: In member function 'virtual void opentelemetry::v1::exporter::jaeger::TUDPTransport::close()':
|
||||
# /build/ceph-18.2.0/src/jaegertracing/opentelemetry-cpp/exporters/jaeger/src/TUDPTransport.cc:71:7: error: '::close' has not been declared; did you mean 'pclose'?
|
||||
# 71 | ::THRIFT_CLOSESOCKET(socket_);
|
||||
# | ^~~~~~~~~~~~~~~~~~
|
||||
# Looks like `close()` is somehow not included.
|
||||
# But the relevant code is already removed in `open-telemetry` 1.10: https://github.com/open-telemetry/opentelemetry-cpp/pull/2031
|
||||
# So it's proably not worth trying to fix that for this Ceph version,
|
||||
# and instead just disable Ceph's Jaeger support.
|
||||
"-DWITH_JAEGER:BOOL=OFF"
|
||||
"-DWITH_TESTS:BOOL=OFF"
|
||||
|
||||
# Use our own libraries, where possible
|
||||
"-DWITH_SYSTEM_ARROW:BOOL=ON"
|
||||
"-DWITH_SYSTEM_ARROW:BOOL=ON" # Only used if other options enable Arrow support.
|
||||
"-DWITH_SYSTEM_BOOST:BOOL=ON"
|
||||
"-DWITH_SYSTEM_CIMG:BOOL=ON"
|
||||
"-DWITH_SYSTEM_JSONCPP:BOOL=ON"
|
||||
"-DWITH_SYSTEM_GTEST:BOOL=ON"
|
||||
"-DWITH_SYSTEM_ROCKSDB:BOOL=ON"
|
||||
"-DWITH_SYSTEM_UTF8PROC:BOOL=ON"
|
||||
|
@ -337,8 +353,6 @@ in rec {
|
|||
|
||||
# TODO breaks with sandbox, tries to download stuff with npm
|
||||
"-DWITH_MGR_DASHBOARD_FRONTEND:BOOL=OFF"
|
||||
# no matching function for call to 'parquet::PageReader::Open(std::shared_ptr<arrow::io::InputStream>&, int64_t, arrow::Compression::type, parquet::MemoryPool*, parquet::CryptoContext*)'
|
||||
"-DWITH_RADOSGW_SELECT_PARQUET:BOOL=OFF"
|
||||
# WITH_XFS has been set default ON from Ceph 16, keeping it optional in nixpkgs for now
|
||||
''-DWITH_XFS=${if optLibxfs != null then "ON" else "OFF"}''
|
||||
] ++ lib.optional stdenv.isLinux "-DWITH_SYSTEM_LIBURING=ON";
|
||||
|
|
Loading…
Reference in a new issue