about summary refs log tree commit diff
path: root/pkgs/misc/emulators/cdemu/base.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/misc/emulators/cdemu/base.nix')
-rw-r--r--pkgs/misc/emulators/cdemu/base.nix37
1 files changed, 37 insertions, 0 deletions
diff --git a/pkgs/misc/emulators/cdemu/base.nix b/pkgs/misc/emulators/cdemu/base.nix
new file mode 100644
index 000000000000..b2b641e3f7a6
--- /dev/null
+++ b/pkgs/misc/emulators/cdemu/base.nix
@@ -0,0 +1,37 @@
+{ pkgName, version, pkgSha256 }:
+{ stdenv, fetchurl, cmake, pkgconfig, buildInputs, drvParams ? {} }:
+let name = "${pkgName}-${version}";
+in stdenv.mkDerivation ({
+  inherit name buildInputs;
+  src = fetchurl {
+    url = "http://downloads.sourceforge.net/cdemu/${name}.tar.bz2";
+    sha256 = pkgSha256;
+  };
+  nativeBuildInputs = [ pkgconfig cmake ];
+  setSourceRoot = ''
+    mkdir build
+    cd build
+    sourceRoot="`pwd`"
+  '';
+  configurePhase = ''
+    cmake ../${name} -DCMAKE_INSTALL_PREFIX=$out -DCMAKE_BUILD_TYPE=Release -DCMAKE_SKIP_RPATH=ON
+  '';
+  meta = {
+    description = "CDemu is a software suite designed to emulate an optical drive and disc (including CD-ROMs and DVD-ROMs) on the Linux operating system.";
+    longDescription = ''
+      CDEmu consists of:
+
+      - a kernel module implementing a virtual drive-controller
+      - libmirage which is a software library for interpreting optical disc images
+      - a daemon which emulates the functionality of an optical drive+disc
+      - textmode and GTK clients for controlling the emulator
+      - an image analyzer to view the structure of image files
+
+      Optical media emulated by CDemu can be mounted within Linux. Automounting is also allowed.
+    '';
+    homepage = "http://cdemu.sourceforge.net/";
+    license = stdenv.lib.licenses.gpl2Plus;
+    platforms = stdenv.lib.platforms.linux;
+    maintainers = [ "Rok Mandeljc <mrok AT users DOT sourceforge DOT net>" ];
+  };
+} // drvParams)