git.iko.soy/typeable/nixpkgs
on master help sign in
ldcpp: reimplement using mkDerivation

Also add libnotify support

commitd8e0dfdc5b09739b1887e56fd32cc543ec01ef3c authorJoachim Fasting <joachifm@fastmail.fm> dateSun 19 Apr 2015, 15:55 (12 years ago) parent290c217
1 file changed+22−31
pkgs/applications/networking/p2p/ldcpp/default.nix+22−31
pkgs/applications/networking/p2p/ldcpp/default.nix+22−31
@@ -1,37 +1,28 @@
1−{ builderDefs, scons, pkgconfig, gtk, bzip2, libglade, openssl, libX11, boost, zlib }:
1+{ stdenv, fetchurl, scons, pkgconfig, gtk, bzip2, libglade, openssl
2+, libX11, boost, zlib, libnotify }:
23
3−with builderDefs;
4− let localDefs = builderDefs.passthru.function ((rec {
5− src = /* put a fetchurl here */
6− fetchurl {
7− url = http://launchpad.net/linuxdcpp/1.1/1.1.0/+download/linuxdcpp-1.1.0.tar.bz2;
8− sha256 = "66012740e9347a2e994c8af5609c40ebf3f86f767258e071a03ef39a2314298a";
9− };
10−
11− buildInputs = [scons pkgconfig gtk bzip2 libglade
12− openssl libX11 boost];
13− configureFlags = [];
14− doScons = fullDepEntry (''
15− mkdir -p $out
16− export NIX_LDFLAGS="$NIX_LDFLAGS -lX11";
17−
18− for i in gettext xgettext msgfmt msgcat; do
19− echo > $i
20− chmod a+x $i
21− done
22− export PATH=$PATH:$PWD
23−
24− scons PREFIX=$out
25− scons PREFIX=$out install
26− '') ["minInit" "doUnpack" "addInputs" "defEnsureDir"];
27− }));
28− in with localDefs;
294stdenv.mkDerivation rec {
305 name = "ldcpp-1.1.0";
31− builder = writeScript (name + "-builder")
32− (textClosure localDefs
33− [doScons doForceShare doPropagate]);
6+ src = fetchurl {
7+ url = http://launchpad.net/linuxdcpp/1.1/1.1.0/+download/linuxdcpp-1.1.0.tar.bz2;
8+ sha256 = "12i92hirmwryl1qy0n3jfrpziwzb82f61xca9jcjwyilx502f0b6";
9+ };
10+ buildInputs = [ scons pkgconfig gtk bzip2 libglade openssl libX11 boost libnotify ];
11+
12+ installPhase = ''
13+ export NIX_LDFLAGS="$NIX_LDFLAGS -lX11";
14+
15+ touch gettext xgettext msgfmt msgcat
16+ chmod +x gettext xgettext msgfmt msgcat
17+ export PATH=$PATH:$PWD
18+
19+ mkdir -p $out
20+ scons PREFIX=$out
21+ scons PREFIX=$out install
22+ '';
23+
3424 meta = {
35− description = "Linux DC++ - Direct Connect client";
25+ description = "Direct Connect client";
26+ license = stdenv.lib.licenses.gpl2;
3627 };
3728}