diff --git a/srcpkgs/whdd/patches/gnu-source.patch b/srcpkgs/whdd/patches/gnu-source.patch new file mode 100644 index 00000000000000..08ad39750c1111 --- /dev/null +++ b/srcpkgs/whdd/patches/gnu-source.patch @@ -0,0 +1,11 @@ +--- CMakeLists.txt ++++ CMakeLists.txt +@@ -5,7 +5,7 @@ + option(STATIC "Build static binaries" OFF) + option(CLI "Build whdd-cli" OFF) + +-set(CMAKE_C_FLAGS "-std=gnu99 -pthread -Wall -Wextra -Wno-missing-field-initializers ${CFLAGS}") ++set(CMAKE_C_FLAGS "-D_GNU_SOURCE -std=gnu99 -pthread -Wall -Wextra -Wno-missing-field-initializers ${CFLAGS}") + set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS}") + set(CMAKE_C_FLAGS_DEBUG "-O0 -g -ggdb ${CMAKE_C_FLAGS}") + diff --git a/srcpkgs/whdd/template b/srcpkgs/whdd/template new file mode 100644 index 00000000000000..970395527a44e6 --- /dev/null +++ b/srcpkgs/whdd/template @@ -0,0 +1,17 @@ +# Template file for 'whdd' +pkgname=whdd +version=3.0.1 +revision=1 +build_style=cmake +configure_args="-DCLI=ON" +makedepends="dialog-devel ncurses-devel" +short_desc="HDD diagnostics and data recovery tool for Linux" +maintainer="Artur Sinila " +license="GPL-3.0-only" +homepage="https://github.com/whdd/whdd" +distfiles="https://github.com/whdd/whdd/archive/${version}.tar.gz" +checksum=58c975695fca5ae8ed67589d7db945d99a027019ecab39aee4e3a608d29a1801 + +post_install() { + mv "${DESTDIR}/usr/sbin" "${DESTDIR}/usr/bin" +} diff --git a/srcpkgs/whdd/update b/srcpkgs/whdd/update new file mode 100644 index 00000000000000..149f9520c4ec82 --- /dev/null +++ b/srcpkgs/whdd/update @@ -0,0 +1,2 @@ +site="https://github.com/whdd/whdd/tags" +pattern="archive/\K[\d.]+(?=\.tar\.gz)"