Fix SOURCEDIR, BUILDDIR and similar when `cd` prints to stdout
Several variables containing directories in `aglsetup.sh` and other
scripts use the common one-liner "cd $DIR && pwd -P" to resolve
symlinks. Unfortunately, in some cases, `cd` writes the new directory to
stdout, e.g. when using multiple search paths. This commit changes the
above to "cd $DIR > /dev/null && pwd -P" to make it more robust.
Change-Id: I150ecc9940d88738cf17add68290c35486a81a3b
Signed-off-by: Henrique Ferreiro <hferreiro@igalia.com>