# Maintainer: Natanael Copa pkgname=f2fs-tools pkgver=1.6.1 pkgrel=0 pkgdesc="Tools for Flash-Friendly File System (F2FS)" url="http://git.kernel.org/cgit/linux/kernel/git/jaegeuk/f2fs-tools.git" arch="all" license="GPL-2.0-or-later" depends="" depends_dev="" makedepends="$depends_dev automake autoconf libtool util-linux-dev linux-headers bsd-compat-headers" install="" subpackages="$pkgname-doc $pkgname-dev $pkgname-libs" #source="http://git.kernel.org/cgit/linux/kernel/git/jaegeuk/f2fs-tools.git/snapshot/f2fs-tools-$pkgver.tar.gz" source="http://dev.alpinelinux.org/archive/f2fs-tools/f2fs-tools-$pkgver.tar.gz " disturl="dev.alpinelinux.org:/archive/$pkgname/" giturl="git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git" builddir="$srcdir/$pkgname-$pkgver" snapshot() { local _format="tar.gz" mkdir -p "$srcdir" && cd "$srcdir" # clone git repo and archive local _tag=v$pkgver msg "Creating git snapshot: $pkgname-$pkgver" git clone --branch $_tag --depth=1 \ --bare $giturl ${pkgname}.git git --git-dir ${pkgname}.git archive \ --format=$_format \ -o $pkgname-$pkgver.$_format \ --prefix=$pkgname-$pkgver/ $_tag # upload to defined distfiles url scp $pkgname-$pkgver.$_format $disturl } prepare() { default_prepare cd "$builddir" ./autogen.sh } build() { cd "$builddir" ./configure \ --build=$CBUILD \ --host=$CHOST \ --prefix=/usr make } package() { cd "$builddir" make install DESTDIR="$pkgdir" mkdir -p "$pkgdir"/usr/include install -m 644 include/f2fs_fs.h mkfs/f2fs_format_utils.h \ "$pkgdir"/usr/include/ } md5sums="722f620fb04fa1abfef050a5468d23f6 f2fs-tools-1.6.1.tar.gz" sha256sums="6e2f46df79d2f8da12ba943d9fd0e82f159fffff9e1566c09db8668956378638 f2fs-tools-1.6.1.tar.gz" sha512sums="95ba7ed50e7ca9f0218b08c7f26ecdb60e8bde37502239804ae207e65b2241636ed33956a33e5c3dfdcc151457323b7d3bdcfd6650a321a54fef46b97334fae0 f2fs-tools-1.6.1.tar.gz"