gpsd: fix build in chroot

Fixes this when building with nix.useChroot = true in configuration.nix:

  sh: ./test_maidenhead.py: /usr/bin/env: bad interpreter: No such file or directory
  scons: *** [maidenhead-locator-regress] Error 126
  scons: building terminated because of errors.
This commit is contained in:
Bjørn Forsman 2014-03-15 23:59:44 +01:00
parent 7ca8bd6d4f
commit 2ce7902059

View File

@ -36,6 +36,7 @@ stdenv.mkDerivation rec {
# 'chrpath' is used to be able to run the tests from the source tree, but # 'chrpath' is used to be able to run the tests from the source tree, but
# we use $LD_LIBRARY_PATH instead. # we use $LD_LIBRARY_PATH instead.
buildPhase = '' buildPhase = ''
patchShebangs .
mkdir -p "$out" mkdir -p "$out"
sed -e "s|python_lib_dir = .*|python_lib_dir = \"$out/lib/${pythonFull.python.libPrefix}/site-packages\"|" -i SConstruct sed -e "s|python_lib_dir = .*|python_lib_dir = \"$out/lib/${pythonFull.python.libPrefix}/site-packages\"|" -i SConstruct
scons prefix="$out" leapfetch=no gpsd_user=${gpsdUser} gpsd_group=${gpsdGroup} \ scons prefix="$out" leapfetch=no gpsd_user=${gpsdUser} gpsd_group=${gpsdGroup} \