rpmbuild: improvements for building with rbd
Add librbd and librados install and build dependencies when "with-rbd" config option is set. This will be used by the Ceph NVMe-oF gateway. Signed-off-by: Mykola Golub <mykola.golub@clyso.com> Change-Id: I1534e224cdfc166061a166ceef18261eef2d8cd8 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/11135 Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
8a5d487d7e
commit
875ccefcdb
@ -112,6 +112,12 @@ build_macros() {
|
||||
fi
|
||||
fi
|
||||
|
||||
if get_config with-rbd; then
|
||||
macros+=(-D "rbd 1")
|
||||
requirements=${requirements:+$requirements, }"librados2, librbd1"
|
||||
build_requirements=${build_requirements:+$build_requirements, }"librados-devel, librbd-devel"
|
||||
fi
|
||||
|
||||
if get_config libdir has-arg; then
|
||||
macros+=(-D "libdir $(get_config libdir print)")
|
||||
fi
|
||||
|
@ -8,6 +8,7 @@
|
||||
%{!?requirements:%define requirements 0}
|
||||
%{!?build_requirements:%define build_requirements 0}
|
||||
%{!?shared:%define shared 0}
|
||||
%{!?rbd:%define rbd 0}
|
||||
%{!?libdir:%define libdir /usr/local/lib}
|
||||
%{!?vfio_user:%define vfio_user 0}
|
||||
|
||||
@ -76,7 +77,11 @@ cl() {
|
||||
}
|
||||
|
||||
%if %{deps}
|
||||
./scripts/pkgdep.sh --docs --pmem --rdma --uring
|
||||
_PKGDEP_OPTS="--docs --pmem --rdma --uring"
|
||||
%if %{rbd}
|
||||
_PKGDEP_OPTS="$_PKGDEP_OPTS --rbd"
|
||||
%endif
|
||||
./scripts/pkgdep.sh $_PKGDEP_OPTS
|
||||
%endif
|
||||
|
||||
# Rely mainly on CONFIG
|
||||
|
Loading…
Reference in New Issue
Block a user