1 { lib, stdenv, buildPackages, fetchurl, autoconf, automake, gettext, libtool, pkg-config
2 , icu, libuuid, readline, inih, liburcu
5 stdenv.mkDerivation rec {
10 url = "mirror://kernel/linux/utils/fs/xfs/xfsprogs/${pname}-${version}.tar.xz";
11 hash = "sha256-S2xsmMA2o39tkMgst/6UBdO1hW2TRWYgMtAf9LFAWSw=";
14 outputs = [ "bin" "dev" "out" "doc" ];
16 depsBuildBuild = [ buildPackages.stdenv.cc ];
18 autoconf automake libtool gettext pkg-config
19 libuuid # codegen tool uses libuuid
21 buildInputs = [ readline icu inih liburcu ];
22 propagatedBuildInputs = [ libuuid ]; # Dev headers include <uuid/uuid.h>
24 enableParallelBuilding = true;
26 # @sbindir@ is replaced with /run/current-system/sw/bin to fix dependency cycles
28 for file in scrub/{xfs_scrub_all.cron.in,xfs_scrub@.service.in,xfs_scrub_all.service.in}; do
29 substituteInPlace "$file" \
30 --replace '@sbindir@' '/run/current-system/sw/bin'
33 patchShebangs ./install-sh
38 "--with-systemd-unit-dir=${placeholder "out"}/lib/systemd/system"
41 installFlags = [ "install-dev" ];
43 # FIXME: forbidden rpath
45 find . -type d -name .libs | xargs rm -rf
49 homepage = "https://xfs.org/";
50 description = "SGI XFS utilities";
51 license = with licenses; [ gpl2Only lgpl21 gpl3Plus ]; # see https://git.kernel.org/pub/scm/fs/xfs/xfsprogs-dev.git/tree/debian/copyright
52 platforms = platforms.linux;
53 maintainers = with maintainers; [ dezgeg ajs124 ];