diff options
author | Nikolay Amiantov <ab@fmap.me> | 2016-04-24 18:49:22 +0300 |
---|---|---|
committer | Nikolay Amiantov <ab@fmap.me> | 2016-04-24 18:49:33 +0300 |
commit | 73182fd328b40fedd2f81ab452a8a0ec01d0885c (patch) | |
tree | 687fc9789902d13883141ab1f757b86370d038f6 /pkgs/applications/networking/mumble | |
parent | d1d4bd9a9dc5ee605ed5d06f815da4842b4c1ebe (diff) |
mumble_overlay: move from mumble and more fixes
Diffstat (limited to 'pkgs/applications/networking/mumble')
-rw-r--r-- | pkgs/applications/networking/mumble/default.nix | 4 | ||||
-rw-r--r-- | pkgs/applications/networking/mumble/overlay.nix | 24 |
2 files changed, 24 insertions, 4 deletions
diff --git a/pkgs/applications/networking/mumble/default.nix b/pkgs/applications/networking/mumble/default.nix index c46ef561c370a..53fa7146257f3 100644 --- a/pkgs/applications/networking/mumble/default.nix +++ b/pkgs/applications/networking/mumble/default.nix @@ -83,10 +83,6 @@ let NIX_CFLAGS_COMPILE = optional speechdSupport "-I${speechd}/include/speech-dispatcher"; installPhase = '' - install -m755 scripts/mumble-overlay $out/bin - sed -i "s,/usr/lib,$out/lib,g" $out/bin/mumble-overlay - ( cd $out/lib; ln -s libmumble.so.1.* libmumble.so.1 ) - mkdir -p $out/share/applications cp scripts/mumble.desktop $out/share/applications diff --git a/pkgs/applications/networking/mumble/overlay.nix b/pkgs/applications/networking/mumble/overlay.nix new file mode 100644 index 0000000000000..23f78ff29b387 --- /dev/null +++ b/pkgs/applications/networking/mumble/overlay.nix @@ -0,0 +1,24 @@ +{ stdenv, lib, which, file, mumble, mumble_i686 +}: + +let + binPath = lib.makeBinPath [ which file ]; +in stdenv.mkDerivation { + name = "mumble-overlay-${mumble.version}"; + + inherit (mumble) src; + + phases = [ "unpackPhase" "installPhase" "fixupPhase" ]; + + installPhase = '' + mkdir -p $out/lib + ln -s ${mumble}/lib/libmumble.so.1.* $out/lib/libmumble.so.1 + ${lib.optionalString (mumble_i686 != null) '' + mkdir -p $out/lib32 + ln -s ${mumble_i686}/lib/libmumble.so.1.* $out/lib32/libmumble.so.1 + ''} + install -Dm755 scripts/mumble-overlay $out/bin/mumble-overlay + sed -i "s,/usr/lib,$out/lib,g" $out/bin/mumble-overlay + sed -i '2iPATH="${binPath}:$PATH"' $out/bin/mumble-overlay + ''; +} |