Author: eelco
Date: Fri Aug 6 22:33:14 2010
New Revision: 23018
URL: https://svn.nixos.org/websvn/nix/?rev=23018&sc=1
Log:
* Added UNetbootin, a program for creating bootable USB sticks from
ISO images.
Added:
nixpkgs/trunk/pkgs/tools/cd-dvd/unetbootin/
nixpkgs/trunk/pkgs/tools/cd-dvd/unetbootin/default.nix
Modified:
nixpkgs/trunk/pkgs/top-level/all-packages.nix
Added: nixpkgs/trunk/pkgs/tools/cd-dvd/unetbootin/default.nix
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ nixpkgs/trunk/pkgs/tools/cd-dvd/unetbootin/default.nix Fri Aug 6
22:33:14 2010 (r23018)
@@ -0,0 +1,62 @@
+{ stdenv, fetchurl, makeWrapper, qt4, utillinux, coreutils, which, p7zip,
mtools, syslinux }:
+
+let version = "485"; in
+
+stdenv.mkDerivation rec {
+ name = "unetbootin-${version}";
+
+ src = fetchurl {
+ url =
"mirror://sourceforge/unetbootin/UNetbootin/${version}/unetbootin-source-${version}.tar.gz";
+ sha256 = "1nyzy1wrql0l6zkmrd1l3qqvbdkv0534axdz6vy3cyksp157jxc8";
+ };
+
+ sourceRoot = ".";
+
+ buildInputs = [ makeWrapper qt4 ];
+
+ # Lots of nice hard-coded paths...
+ postUnpack =
+ ''
+ substituteInPlace unetbootin.cpp \
+ --replace /sbin/fdisk ${utillinux}/sbin/fdisk \
+ --replace /sbin/sfdisk ${utillinux}/sbin/sfdisk \
+ --replace /sbin/blkid ${utillinux}/sbin/blkid \
+ --replace /bin/df ${coreutils}/bin/df \
+ --replace /usr/bin/syslinux ${syslinux}/bin/syslinux \
+ --replace /usr/bin/extlinux ${syslinux}/sbin/extlinux \
+ --replace /usr/share/syslinux ${syslinux}/share/syslinux
+ substituteInPlace main.cpp \
+ --replace /usr/share/unetbootin $out/share/unetbootin
+ substituteInPlace unetbootin.desktop \
+ --replace /usr/bin $out/bin
+ '';
+
+ buildPhase =
+ ''
+ lupdate unetbootin.pro
+ lrelease unetbootin.pro
+ qmake
+ make
+ '';
+
+ installPhase =
+ ''
+ ensureDir $out/bin
+ cp unetbootin $out/bin
+
+ ensureDir $out/share/unetbootin
+ cp unetbootin_*.qm $out/share/unetbootin
+
+ ensureDir $out/share/applications
+ cp unetbootin.desktop $out/share/applications
+
+ wrapProgram $out/bin/unetbootin \
+ --prefix PATH : ${which}/bin:${p7zip}/bin:${mtools}/bin
+ '';
+
+ meta = {
+ homepage = http://unetbootin.sourceforge.net/;
+ description = "A tool to create bootable live USB drives from ISO images";
+ license = "GPLv2+";
+ };
+}
Modified: nixpkgs/trunk/pkgs/top-level/all-packages.nix
==============================================================================
--- nixpkgs/trunk/pkgs/top-level/all-packages.nix Fri Aug 6 22:27:28
2010 (r23017)
+++ nixpkgs/trunk/pkgs/top-level/all-packages.nix Fri Aug 6 22:33:14
2010 (r23018)
@@ -1183,6 +1183,8 @@
inherit (gnome) gtk;
};
+ unetbootin = callPackage ../tools/cd-dvd/unetbootin { };
+
upx = callPackage ../tools/compression/upx { };
vbetool = builderDefsPackage ../tools/system/vbetool {
_______________________________________________
nix-commits mailing list
[email protected]
http://mail.cs.uu.nl/mailman/listinfo/nix-commits