3
0
Fork 0
forked from mirrors/nixpkgs

rdiff-backup: unbreak 'rdiff-backup-statistics'

By adding needed module to python sys.path. Fixes this:

  $ rdiff-backup-statistics backup-dir
  Traceback (most recent call last):
    File "/home/bfo/.nix-profile/bin/rdiff-backup-statistics", line 24, in
  <module>
      from rdiff_backup import connection, regress, rpath, Globals,
  restore, \
  ImportError: No module named rdiff_backup
This commit is contained in:
Bjørn Forsman 2014-11-23 21:58:46 +01:00
parent 98344757b9
commit bad831d6fe

View file

@ -13,6 +13,8 @@ stdenv.mkDerivation {
python ./setup.py install --prefix=$out
sed -i $out/bin/rdiff-backup -e \
"/import sys/ asys.path += [ \"$out/lib/python2.7/site-packages/\" ]"
sed -i $out/bin/rdiff-backup-statistics -e \
"/import .*sys/ asys.path += [ \"$out/lib/python2.7/site-packages/\" ]"
'';
buildInputs = [ python librsync gnused ];