nixpkgs/pkgs/applications/version-management/tortoisehg/default.nix
Dan Connolly a4ce0e233b tortoisehg: 3.6 -> 3.7.1, fixes package
fixes #13507

On June 8 (e8655ee) tortoisehg changed the way
it computes the `/usr/share` directory in a way that
invalidated the assumptions behind the use
of substituteInPlace in postUnpack.
2016-04-11 10:35:31 +02:00

35 lines
1.1 KiB
Nix

{lib, fetchurl, mercurial, pythonPackages}:
pythonPackages.buildPythonApplication rec {
name = "tortoisehg-${version}";
version = "3.7.1";
namePrefix = "";
src = fetchurl {
url = "https://bitbucket.org/tortoisehg/targz/downloads/${name}.tar.gz";
sha256 = "1ycf8knwk1rs99s5caq611sk4c4nzwyzq8g35hw5kwj15b6dl4k6";
};
pythonPath = with pythonPackages; [ pyqt4 mercurial qscintilla iniparse ];
propagatedBuildInputs = with pythonPackages; [ qscintilla iniparse ];
doCheck = false;
postUnpack = ''
substituteInPlace $sourceRoot/setup.py \
--replace "sharedir = os.path.join(installcmd.install_data[rootlen:], 'share')" "sharedir = '$out/share/'"
'';
postInstall = ''
ln -s $out/bin/thg $out/bin/tortoisehg #convenient alias
'';
meta = {
description = "Qt based graphical tool for working with Mercurial";
homepage = http://tortoisehg.bitbucket.org/;
license = lib.licenses.gpl2;
platforms = lib.platforms.linux;
maintainers = [ "abcz2.uprola@gmail.com" ];
};
}