#!/usr/bin/env bash
name='btrfs-progs'
release='7'
version='6.14'
url='https://github.com/storaged-project/libblockdev'
description='A library for manipulating block devices'
email='bayramk@gmail.com'
maintainer='bk'
license=('GPLv3')
source=("https://github.com/kdave/btrfs-progs/archive/refs/tags/v${version}.tar.gz")
depends=(e2fsprogs zlib libgcrypt eudev)
makedepends=()
sha256sums=('5a85b791f0f32a4994e864ac4cb7abccce08e56db3010a1855ad0edeebc70b4c')
group=(sys.fs)
uses=()
arch=('x86_64')

cd $name-$version

setup(){
	./autogen.sh
	./configure --prefix=/usr \
            --libdir=/usr/lib64/\
            --with-crypto=libgcrypt \
            --disable-zstd \
            --disable-documentation
}

build(){
    make $jobs
}

package(){
  make DESTDIR="$DESTDIR" install install_python
  # install bash completion (FS#44618)
  install -Dm644 btrfs-completion "$DESTDIR/usr/share/bash-completion/completions/btrfs"
}

