[net-fs/nfs-ganesha] complete the work on it for now, python untested

This commit is contained in:
Robert Förster 2024-08-23 16:31:24 +02:00
parent ea5de217c0
commit adbb4ea444
3 changed files with 60 additions and 50 deletions

View File

@ -1,16 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<!-- maintainer-needed -->
<use>
<flag name="gssapi">Enable GSSAPI support</flag>
<flag name="tools">Install Admin scripts</flag>
<flag name="gui">Install GUI Admin scripts</flag>
<flag name="nfs3">Enable NLM/NFSv3 support</flag>
<flag name="rdma">Enable rdma storage backend support</flag>
<flag name="vsock">Enable AF_VSOCK listener</flag>
</use>
<upstream>
<remote-id type="github">nfs-ganesha/nfs-ganesha</remote-id>
</upstream>
<!-- maintainer-needed -->
<use>
<flag name="btrfs">Enable Btrfs support</flag>
<flag name="gssapi">Enable GSSAPI support</flag>
<flag name="tools">Install Admin scripts</flag>
<flag name="gui">Install GUI Admin scripts</flag>
<flag name="nfsv3">Enable NLM/NFSv3 support</flag>
<flag name="rdma">Enable rdma storage backend support</flag>
<flag name="vsock">Enable AF_VSOCK listener</flag>
</use>
<upstream>
<remote-id type="github">nfs-ganesha/nfs-ganesha</remote-id>
</upstream>
</pkgmetadata>

View File

@ -3,10 +3,12 @@
EAPI=8
DISTUTILS_OPTIONAL=1
DISTUTILS_SINGLE_IMPL=1
DISTUTILS_USE_PEP517=standalone
PYTHON_COMPAT=( python3_12 )
inherit cmake python-single-r1
#inherit cmake
inherit cmake distutils-r1
DESCRIPTION="A NFSv3,v4,v4.1 fileserver that runs in user mode on most UNIX/Linux systems"
HOMEPAGE="https://github.com/nfs-ganesha/nfs-ganesha"
@ -22,16 +24,19 @@ fi
LICENSE="LGPL-3"
SLOT="0"
KEYWORDS="~amd64"
IUSE="btrfs caps dbus debug gssapi gui +nfs3 tools vsock"
IUSE="btrfs caps dbus debug gssapi gui +nfsv3 tools vsock"
FS_SUPPORT=" ceph glusterfs gpfs mem null proxy-v3 proxy-v4 rgw vfs xfs"
IUSE+=" ${FS_SUPPORT// / ganesha_fs_}"
REQUIRED_USE="gui? ( tools )
btrfs? ( ganesha_fs_vfs )"
REQUIRED_USE="${PYTHON_REQUIRED_USE}
gui? ( tools )
btrfs? ( ganesha_fs_vfs )
"
# add monitoring support at some point
RDEPEND="
${PYTHON_DEPS}
dev-libs/jemalloc:=
dev-libs/userspace-rcu:=
>=net-libs/ntirpc-5.8[gssapi]
@ -43,21 +48,33 @@ RDEPEND="
dbus? ( sys-apps/dbus )
ganesha_fs_ceph? ( sys-cluster/ceph )
ganesha_fs_glusterfs? ( sys-cluster/glusterfs )
ganesha_fs_rgw? ( sys-cluster/ceph[radosgw] )
ganesha_fs_xfs? ( sys-fs/xfsprogs )
gui? (
$(python_gen_cond_dep '
dev-python/PyQt5[gui,dbus,${PYTHON_USEDEP}]
')
)
tools? (
$(python_gen_cond_dep '
dev-python/dbus-python[${PYTHON_USEDEP}]
dev-python/pygobject[${PYTHON_USEDEP}]
dev-python/pyparsing[${PYTHON_USEDEP}]
')
)
"
DEPEND="${RDEPEND}
BDEPEND="
${DISTUTILS_DEPS}
${PYTHON_DEPS}
sys-devel/bison
sys-devel/flex
virtual/pkgconfig
$(python_gen_cond_dep '
dev-python/sphinx[${PYTHON_USEDEP}]
')
"
pkg_setup() {
if use tools || use gui; then
python-single-r1_pkg_setup
fi
}
src_prepare() {
sed \
-e "/config_samples/s:doc\/ganesha:doc\/${PF}:g" \
@ -86,18 +103,20 @@ src_configure() {
-DUSE_EFENCE=$(usex debug)
-DDEBUG_SAL=$(usex debug)
-DENABLE_LOCKTRACE=$(usex debug)
-DUSE_NFS3=$(usex nfs3)
-DUSE_NFSACL3=$(usex nfs3)
-DUSE_NLM=$(usex nfs3)
-DUSE_NFS3=$(usex nfsv3)
-DUSE_NFSACL3=$(usex nfsv3)
-DUSE_NLM=$(usex nfsv3)
-DUSE_VSOCK=$(usex vsock)
-DUSE_LEGACY_PYTHON_INSTALL=OFF
-DUSE_ADMIN_TOOLS=$(usex tools)
-DUSE_GUI_ADMIN_TOOLS=$(usex gui)
-DUSE_MAN_PAGE=ON
-DUSE_FSAL_CEPH=$(usex ganesha_fs_ceph)
-DUSE_RADOS_RECOV=$(usex ganesha_fs_ceph)
-DRADOS_URLS=$(usex ganesha_fs_ceph)
-DCEPHFS_POSIX_ACL=$(usex ganesha_fs_ceph)
-DUSE_FSAL_RGW=$(usex ganesha_fs_rgw)
-DUSE_RADOS_RECOV=$(usex ganesha_fs_rgw)
-DRADOS_URLS=$(usex ganesha_fs_rgw)
-DUSE_FSAL_GLUSTER=$(usex ganesha_fs_glusterfs)
-DUSE_FSAL_GPFS=$(usex ganesha_fs_gpfs)
@ -105,42 +124,32 @@ src_configure() {
-DUSE_FSAL_NULL=$(usex ganesha_fs_null)
-DUSE_FSAL_PROXY_V3=$(usex ganesha_fs_proxy-v3)
-DUSE_FSAL_PROXY_V4=$(usex ganesha_fs_proxy-v4)
-DUSE_FSAL_RGW=$(usex ganesha_fs_rgw)
-DUSE_FSAL_VFS=$(usex ganesha_fs_vfs)
-DUSE_FSAL_XFS=$(usex ganesha_fs_xfs)
-DUSE_NFSIDMAP=OFF
-DUSE_FSAL_KVSFS=OFF
-DUSE_FSAL_LIZARDFS=OFF
-DUSE_FSAL_LUSTRE=OFF
-DUSE_FSAL_SAUNAFS=OFF
)
if use gui || use tools; then
mycmakeargs+=(
-DPython_INCLUDE_DIR="$(python_get_includedir)"
-DPython_LIBRARY="$(python_get_library_path)"
-DPython_EXECUTABLE="${PYTHON}"
-DPython3_INCLUDE_DIR="$(python_get_includedir)"
-DPython3_LIBRARY="$(python_get_library_path)"
-DPython3_EXECUTABLE="${PYTHON}"
)
fi
cmake_src_configure
}
#testing
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(USE_TOOL_MULTILOCK "build multilock tool" OFF)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(USE_CB_SIMULATOR "enable callback simulator thread" OFF)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(ENABLE_ERROR_INJECTION "enable error injection" OFF)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:# These are -D_FOO options, why ??? should be flags??
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(_NO_TCP_REGISTER "disable registration of tcp services on portmapper" OFF)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(_NO_PORTMAPPER "disable registration on portmapper" OFF)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(_NO_XATTRD "disable ghost xattr directory and files support" ON)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(_VALGRIND_MEMCHECK "Initialize buffers passed to GPFS ioctl that valgrind doesn't understand" OFF)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(USE_CUNIT "Use Cunit test framework" OFF)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(BLKIN_PREFIX "Blkin installation prefix" "/opt/blkin")
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(USE_GTEST "Use Google Test test framework" OFF)
#/var/tmp/portage/net-fs/nfs-ganesha-2.4.3/work/nfs-ganesha-2.4.3/src/CMakeLists.txt:option(GTEST_PREFIX "Google Test installation prefix"
src_install() {
cmake_src_install
if use tools || use gui; then
python_fix_shebang "${ED}"
python_optimize
fi
newinitd "${FILESDIR}"/${PN}.init ${PN}
newconfd "${FILESDIR}"/${PN}.confd ${PN}

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors.
# Copyright 1999-2024 Gentoo Authors.
# Distributed under the terms of the GNU General Public License v2
# This file contains descriptions of GANESHA_FS USE_EXPAND flags.
@ -6,7 +6,7 @@
ceph - Enables CEPH support
glusterfs - Enables GlusterFS support
gpfs - Enables support for GPFS
lustre - Enables support for LustreFS
mem - Enables support for MEM
null - Enables support for NULL
panfs - Enables support for PanFS
proxy-v3 - Enables support for PROXY_V3