blob: 6aa674c7903e97faabd2ba90ec285e08383c31eb [file] [log] [blame]
Patrick Williams92b42cb2022-09-03 06:53:57 -05001SUMMARY = "OpenZFS on Linux and FreeBSD"
2DESCRIPTION = "OpenZFS on Linux and FreeBSD"
3LICENSE = "CDDL-1.0"
4LIC_FILES_CHKSUM = "file://LICENSE;md5=7087caaf1dc8a2856585619f4a787faa"
5HOMEPAGE ="https://github.com/openzfs/zfs"
6
7SRC_URI = "https://github.com/openzfs/zfs/releases/download/${BPN}-${PV}/${BPN}-${PV}.tar.gz \
8 file://0001-Define-strndupa-if-it-does-not-exist.patch \
9"
10SRC_URI[sha256sum] = "1913041e5c44ff07ca384346ad8145aeedf77e77cd1cea9ec5d533246691e10c"
11
12# Using both 'module' and 'autotools' classes seems a bit odd, they both
13# define a do_compile function.
14# That's why we opt for module-base, also this prevents module splitting.
15inherit module-base pkgconfig autotools
16
17DEPENDS = "virtual/kernel zlib util-linux libtirpc openssl curl"
18
19PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd sysvinit', d)}"
20
21PACKAGECONFIG[pam] = "--enable-pam --with-pamconfigsdir=${datadir}/pam-configs --with-pammoduledir=${libdir}/security, --disable-pam"
22PACKAGECONFIG[systemd] = "--enable-systemd,--disable-systemd,"
23PACKAGECONFIG[sysvinit] = "--enable-sysvinit,--disable-sysvinit,"
24
25EXTRA_OECONF:append = " \
26 --disable-pyzfs \
27 --with-linux=${STAGING_KERNEL_DIR} --with-linux-obj=${STAGING_KERNEL_BUILDDIR} \
28 --with-mounthelperdir=${base_sbin} \
29 --with-udevdir=${base_libdir}/udev \
30 --without-dracutdir \
31 "
32
33EXTRA_OEMAKE:append = " \
34 INSTALL_MOD_PATH=${D}${root_prefix} \
35 "
36
37do_install:append() {
38 # /usr/share/zfs contains the zfs-tests folder which we do not need:
39 rm -rf ${D}${datadir}/zfs
40
41 rm -rf ${D}${datadir}/initramfs-tools
42}
43
44FILES:${PN} += "\
45 ${base_sbindir}/* \
46 ${base_libdir}/* \
47 ${sysconfdir}/* \
48 ${sbindir}/* \
49 ${bindir}/* \
50 ${libexecdir}/${BPN}/* \
51 ${libdir}/* \
52 "
53
54FILES:${PN}-dev += "\
55 ${prefix}/src/zfs-${PV}/* \
56 ${prefix}/src/spl-${PV}/* \
57 "
58# Not yet ported to rv32
59COMPATIBLE_HOST:riscv32 = "null"
60# conflicting definition of ABS macro from asm/asm.h from kernel
61COMPATIBLE_HOST:mips = "null"