Author: ludo
Date: Tue Oct 4 20:53:47 2011
New Revision: 29646
URL: https://ssl.nixos.org/websvn/nix/?rev=29646&sc=1
Log:
configure: Allow `nix-store' to be run within a build chroot.
Modified:
hydra/trunk/configure.ac
Modified: hydra/trunk/configure.ac
==============================================================================
--- hydra/trunk/configure.ac Tue Oct 4 20:23:49 2011 (r29645)
+++ hydra/trunk/configure.ac Tue Oct 4 20:53:47 2011 (r29646)
@@ -44,6 +44,14 @@
NEED_PROG([NIX_STORE_PROGRAM], [nix-store])
AC_MSG_CHECKING([whether $NIX_STORE_PROGRAM is recent enough])
+if test -n "$NIX_STORE" -a test -n "$TMPDIR"
+then
+ # This may be executed from within a build chroot, so pacify
+ # `nix-store' instead of letting it choke while trying to mkdir
+ # /nix/var.
+ NIX_STATE_DIR="$TMPDIR"
+ export NIX_STATE_DIR
+fi
if "$NIX_STORE_PROGRAM" --timeout 123 -q > /dev/null 2>&1
then
AC_MSG_RESULT([yes])
_______________________________________________
nix-commits mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-commits