* Do use readlink if available.

svn path=/nixpkgs/trunk/; revision=5252
This commit is contained in:
Eelco Dolstra 2006-05-02 09:21:59 +00:00
parent 75ee1e1704
commit b8fd332dd8

View file

@ -53,7 +53,8 @@ if test -z "$hash"; then
fi
# Create a Nix expression that does a fetchsvn.
nixExpr=$(dirname $0)/../../top-level/all-packages.nix
scriptDir=$(dirname $(readlink -f $0 2> /dev/null || echo $0))
nixExpr=$scriptDir/../../top-level/all-packages.nix
storeExpr=$( \
echo "(import $nixExpr {}).fetchsvn {url=\"$url\"; rev=\"$rev\"; md5=\"$hash\";}" \
| nix-instantiate -)