%global commit d4c2910981ff99b983734426dfa99632fb81ac6b %global date 20230209 %global shortcommit %(c=%{commit}; echo ${c:0:7}) Summary: Configure MMC storage devices from userspace Name: mmc-utils Version: 0.1 Release: 2.%{date}git%{shortcommit}%{?dist} URL: https://docs.kernel.org/driver-api/mmc/mmc-tools.html Source0: https://git.kernel.org/pub/scm/utils/mmc/mmc-utils.git/snapshot/mmc-utils-d4c2910981ff99b983734426dfa99632fb81ac6b.tar.gz Patch0: https://sources.debian.org/data/main/m/mmc-utils/0%2Bgit20220624.d7b343fd-1/debian/patches/0001-Fix-typo.patch Patch1: https://sources.debian.org/data/main/m/mmc-utils/0%2Bgit20220624.d7b343fd-1/debian/patches/0002-man-mmc.1-Fix-warning-macro-not-defined.patch License: GPL-2.0-only BuildRequires: gcc BuildRequires: make %description The mmc-utils tools can do the following: * Print and parse extcsd data. * Determine the eMMC writeprotect status. * Set the eMMC writeprotect status. * Set the eMMC data sector size to 4KB by disabling emulation. * Create general purpose partition. * Enable the enhanced user area. * Enable write reliability per partition. * Print the response to STATUS_SEND (CMD13). * Enable the boot partition. * Set Boot Bus Conditions. * Enable the eMMC BKOPS feature. * Permanently enable the eMMC H/W Reset feature. * Permanently disable the eMMC H/W Reset feature. * Send Sanitize command. * Program authentication key for the device. * Counter value for the rpmb device will be read to stdout. * Read from rpmb device to output. * Write to rpmb device from data file. * Enable the eMMC cache feature. * Disable the eMMC cache feature. * Print and parse CID data. * Print and parse CSD data. * Print and parse SCR data. %prep %autosetup -n %{name}-%{commit} -p1 %build export CFLAGS="%{build_cflags} -Wno-error=stringop-overflow" %make_build %install %make_install bindir=%{_bindir} install -D -pm0644 -t %{buildroot}%{_mandir}/man1 man/mmc.1 %files %doc README %{_bindir}/mmc %{_mandir}/man1/mmc.1* %changelog * Tue Apr 04 2023 Dominik Mierzejewski 0.1-2.20230209gitd4c2910 - fixed build on rawhide * Mon Apr 03 2023 Dominik Mierzejewski 0.1-1.20230209gitd4c2910 - initial build