diff --git a/srcpkgs/freefall b/srcpkgs/freefall new file mode 120000 index 0000000000..7d7f1b46a5 --- /dev/null +++ b/srcpkgs/freefall @@ -0,0 +1 @@ +./linux-tools \ No newline at end of file diff --git a/srcpkgs/linux-tools/files/freefall/run b/srcpkgs/linux-tools/files/freefall/run new file mode 100644 index 0000000000..51a9f293b4 --- /dev/null +++ b/srcpkgs/linux-tools/files/freefall/run @@ -0,0 +1,3 @@ +#!/bin/sh +[ -r conf ] && . ./conf +exec freefall ${OPTS:=/dev/sda} diff --git a/srcpkgs/linux-tools/template b/srcpkgs/linux-tools/template index 2fed7434ef..c17ebb2d68 100644 --- a/srcpkgs/linux-tools/template +++ b/srcpkgs/linux-tools/template @@ -15,7 +15,7 @@ homepage="http://www.kernel.org" distfiles="http://ftp.kernel.org/pub/linux/kernel/v4.x/linux-${version}.tar.xz" checksum=0f2f7d44979bc8f71c4fc5d3308c03499c26a824dd311fdf6eef4dee0d7d5991 -subpackages="cpupower libcpupower libcpupower-devel libusbip libusbip-devel usbip perf" +subpackages="cpupower libcpupower libcpupower-devel libusbip libusbip-devel usbip perf freefall" if [ "$XBPS_TARGET_MACHINE" = "i686" -o "$XBPS_TARGET_MACHINE" = "x86_64" ]; then makedepends+=" libnuma-devel" @@ -46,6 +46,9 @@ do_build() { make ${makejobs} fi + cd ${wrksrc}/Documentation/laptops + $CC ${CFLAGS} ${LDFLAGS} -o freefall freefall.c + cd ${wrksrc}/tools/usb/usbip # fix missing man page sed -i 's/usbip_bind_driver.8//' Makefile.am @@ -63,6 +66,9 @@ do_install() { docdir='/usr/share/doc/cpupower' \ install install-man + # freefall + vbin "${wrksrc}/Documentation/laptops/freefall" + # perf cd ${wrksrc}/tools/perf make WERROR=0 DESTDIR=${DESTDIR}/usr \ @@ -164,3 +170,10 @@ usbip_package() { fi } } +freefall_package() { + short_desc="Disk protection for HP/DELL machines" + pkg_install() { + vmove usr/bin/freefall + vsv freefall + } +}