summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorMichael Raskin <7c6f434c@mail.ru>2011-12-13 04:30:49 +0000
committerMichael Raskin <7c6f434c@mail.ru>2011-12-13 04:30:49 +0000
commitf9227dc45942c329b29b02a2c4e27711e4be01ed (patch)
tree4b9401215ddc7a7f1f77b09ab1990b2efb9db2f8 /pkgs
parent135fe9059f987b70f6bb7022114afd2e905ae074 (diff)
downloadnixpkgs-f9227dc45942c329b29b02a2c4e27711e4be01ed.tar
nixpkgs-f9227dc45942c329b29b02a2c4e27711e4be01ed.tar.gz
nixpkgs-f9227dc45942c329b29b02a2c4e27711e4be01ed.tar.bz2
nixpkgs-f9227dc45942c329b29b02a2c4e27711e4be01ed.tar.lz
nixpkgs-f9227dc45942c329b29b02a2c4e27711e4be01ed.tar.xz
nixpkgs-f9227dc45942c329b29b02a2c4e27711e4be01ed.tar.zst
nixpkgs-f9227dc45942c329b29b02a2c4e27711e4be01ed.zip
Update BtrFS utilities to latest Git
svn path=/nixpkgs/trunk/; revision=30864
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/tools/filesystems/btrfsprogs/default.nix20
-rw-r--r--pkgs/tools/filesystems/btrfsprogs/glibc212.patch12
2 files changed, 14 insertions, 18 deletions
diff --git a/pkgs/tools/filesystems/btrfsprogs/default.nix b/pkgs/tools/filesystems/btrfsprogs/default.nix
index 22d7a1164c8..76d185f82d9 100644
--- a/pkgs/tools/filesystems/btrfsprogs/default.nix
+++ b/pkgs/tools/filesystems/btrfsprogs/default.nix
@@ -1,27 +1,35 @@
 a :
 let
   fetchurl = a.fetchurl;
+  fetchgit = a.fetchgit;
 
   version = a.lib.attrByPath ["version"] "0.19" a;
   buildInputs = with a; [
-    zlib libuuid acl
+    zlib libuuid acl attr
   ];
 in
 
 assert a.libuuid != null;
 
 rec {
-  src = fetchurl {
-    url = "http://www.kernel.org/pub/linux/kernel/people/mason/btrfs/btrfs-progs-${version}.tar.bz2";
-    sha256 = "1z3hmfgv7h489gnh55abm0gzyf2cgjkybhfc2rnm0cvsx01xv8zq";
+  srcDrv = fetchgit {
+    url="git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-progs.git" ;
+    rev="fdb6c0402337d9607c7a39155088eaf033742752" ;
+    sha256="de7f9e04401bd747a831c48d312106e188adb32f32b6d64078ae6d2aab45b1f8" ;
   };
 
+  src = srcDrv + "/";
+
   inherit buildInputs;
   configureFlags = [];
   makeFlags = ["prefix=$out CFLAGS=-Os"];
 
-  patches = [ ./glibc212.patch ];
-  phaseNames = ["doPatch" "doEnsureBtrfsImage" "doMakeInstall"];
+  patches = [];
+  phaseNames = ["fixMakefile" "doEnsureBtrfsImage" "doMakeInstall"];
+
+  fixMakefile = a.fullDepEntry ''
+    sed -e 's@^progs = @progs=@g' -i Makefile
+  '' ["minInit" "doUnpack"];
 
   doEnsureBtrfsImage = a.fullDepEntry (''
     if ! grep 'progs = ' Makefile | grep btrfs-image; then
diff --git a/pkgs/tools/filesystems/btrfsprogs/glibc212.patch b/pkgs/tools/filesystems/btrfsprogs/glibc212.patch
deleted file mode 100644
index 8bc1873f540..00000000000
--- a/pkgs/tools/filesystems/btrfsprogs/glibc212.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff --git a/btrfsck.c b/btrfsck.c
-index 73f1836..c1f47a1 100644
---- a/btrfsck.c
-+++ b/btrfsck.c
-@@ -21,6 +21,7 @@
- #include <stdio.h>
- #include <stdlib.h>
- #include <fcntl.h>
-+#include <sys/stat.h>
- #include "kerncompat.h"
- #include "ctree.h"
- #include "disk-io.h"