--- /dev/null
+Name: erofs-utils
+Version: 1.8.2
+Release: 0
+Summary: Utilities for the Extendable Read-Only Filesystem (EROFS)
+License: GPL-2.0
+Group: System/Kernel
+URL: https://git.kernel.org
+Source0: %{name}-%{version}.tar.gz
+Source1001: %{name}.manifest
+BuildRequires: autoconf
+BuildRequires: automake
+BuildRequires: lz4-devel
+BuildRequires: libtool
+BuildRequires: libuuid-devel
+BuildRequires: libzstd-devel
+BuildRequires: m4
+BuildRequires: pkg-config
+BuildRequires: xz
+BuildRequires: pkgconfig(liblzma)
+BuildRequires: pkgconfig(zlib)
+BuildRequires: pkgconfig(blkid)
+
+%description
+mkfs.erofs is a user-space tool to create erofs filesystem images. It
+can create two main types of erofs images, compressed and
+uncompressed:
+
+* For compressed images, it is able to integrate several compression
+ algorithms, LZ4 is supported according to the current erofs kernel
+ implementation.
+* For uncompressed images, it can decide whether the last page of a
+ file should be inlined or not properly.
+
+%prep
+%autosetup -p1
+cp %{SOURCE1001} .
+
+%build
+export CFLGAS="${CFLAGS} -fPIE"
+export LDFLAGS="${LDFLAGS} -fPIE"
+autoreconf -fiv
+%configure --bindir="%_sbindir" --enable-lzma
+%make_build
+
+%install
+%make_install
+rm -rf %{buildroot}/usr/share/man/man1/*
+
+%files
+%manifest %{name}.manifest
+%license COPYING
+%_sbindir/*erofs