GNU Parted 1.9.0.

svn path=/nixpkgs/trunk/; revision=16463
This commit is contained in:
Ludovic Courtès 2009-07-26 21:03:52 +00:00
parent d39bbb1693
commit 83116e4b8c
3 changed files with 54 additions and 17 deletions

View File

@ -1,25 +1,47 @@
{stdenv, fetchurl, e2fsprogs, readline}: { stdenv, fetchurl, devicemapper, e2fsprogs, gettext, readline }:
stdenv.mkDerivation { stdenv.mkDerivation rec {
name = "parted-1.8.8"; name = "parted-1.9.0";
src = fetchurl { src = fetchurl {
url = mirror://gnu/parted/parted-1.8.8.tar.bz2; url = "mirror://gnu/parted/${name}.tar.gz";
sha256 = "1sn5qcdi4pvxnxz8ryh5p52qmqd72qbk0d0a65pksxf7khd83kfz"; sha256 = "02amqpzl8lgk247cjsbaz1nsiz9i1pbj0adx0z109h94p90i48sk";
}; };
buildInputs = [e2fsprogs readline]; buildInputs = [ devicemapper e2fsprogs gettext readline ];
preConfigure='' # XXX: For some reason our libreadline.so doesn't have libncurses as
export CFLAGS=-fgnu89-inline # NEEDED and `configure' links with `-Wl,--as-needed' so when
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -fgnu89-inline" # `AC_CHECK_LIB' tries to link with `-lreadline -lncurses' the latter is
''; # removed, leaving `libreadline' with unresolved references.
#
# Remove the `preConfigure' hack below when Readline is fixed.
preConfigure = ''export gl_cv_ignore_unused_libraries=""'';
configureFlags = "--with-readline";
configureFlags = "--without-readline"; doCheck = true;
patches = [ ./t7000-scripting.patch ];
meta = { meta = {
description = "Tool to create, destroy, resize, check and copy partitions"; description = "GNU Parted, a tool to create, destroy, resize, check, and copy partitions";
longDescription = ''
GNU Parted is an industrial-strength package for creating, destroying,
resizing, checking and copying partitions, and the file systems on
them. This is useful for creating space for new operating systems,
reorganising disk usage, copying data on hard disks and disk imaging.
It contains a library, libparted, and a command-line frontend, parted,
which also serves as a sample implementation and script backend.
'';
homepage = http://www.gnu.org/software/parted/; homepage = http://www.gnu.org/software/parted/;
license = "GPLv3"; license = "GPLv3+";
maintainers = [
# Add your name here!
stdenv.lib.maintainers.ludo
];
}; };
} }

View File

@ -0,0 +1,15 @@
This patch fixes the `t7000-scripting' test. See
http://lists.alioth.debian.org/pipermail/parted-devel/2009-June/thread.html#2887
for details.
--- parted-1.9.0/tests/t7000-scripting.sh 2009-07-23 19:52:08.000000000 +0200
+++ parted-1.9.0/tests/t7000-scripting.sh 2009-07-26 14:20:28.000000000 +0200
@@ -28,7 +28,7 @@ EOF
{ emit_superuser_warning
sed s/Error/Warning/ errS
- printf 'Is this still acceptable to you?\nYes/No?'; } >> errI || fail=1
+ printf 'Is this still acceptable to you?\nYes/No? n\n'; } >> errI || fail=1
for mkpart in mkpart mkpartfs; do

View File

@ -1113,7 +1113,7 @@ let
}; };
parted = import ../tools/misc/parted { parted = import ../tools/misc/parted {
inherit fetchurl stdenv e2fsprogs readline; inherit fetchurl stdenv devicemapper e2fsprogs gettext readline;
}; };
patch = gnupatch; patch = gnupatch;