diff options
author | Ian Lynagh <igloo@earth.li> | 2007-07-30 19:08:08 +0000 |
---|---|---|
committer | Ian Lynagh <igloo@earth.li> | 2007-07-30 19:08:08 +0000 |
commit | 068bf75eeee553c7f2cb06b8d84bdff58677c319 (patch) | |
tree | 36a354a6dd17cc6db69cb4ed2d6e7243965a7606 /aclocal.m4 | |
parent | c5805c8232bd3ece535e78c86c72bddec05bb975 (diff) | |
download | haskell-068bf75eeee553c7f2cb06b8d84bdff58677c319.tar.gz |
Use our own (Haskell) pwd to find the tree root
Diffstat (limited to 'aclocal.m4')
-rw-r--r-- | aclocal.m4 | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/aclocal.m4 b/aclocal.m4 index ce8e58511e..3a55ec101c 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -1096,11 +1096,22 @@ AC_REQUIRE([AC_PROG_CC]) AC_DEFUN([FP_FIND_ROOT],[ AC_MSG_CHECKING(for path to top of build tree) -hardtop=`pwd` +dnl This would be +dnl make -C utils/pwd clean && make -C utils/pwd +dnl except we don't want to have to know what make is called. Sigh. +cd utils/pwd +rm -f *.o +rm -f *.hi +rm -f pwd +rm -f pwd.exe +$WithGhc -v0 --make pwd +cd ../.. + +hardtop=`utils/pwd/pwd forwardslash` dnl Remove common automounter nonsense dnl -hardtop=`echo $hardtop | sed 's|^/tmp_mnt.*\(/local/.*\)$|\1|' | sed 's|^/tmp_mnt/|/|' | sed 's|^//\(.\)/|\1:/|' ` +hardtop=`echo $hardtop | sed 's|^/tmp_mnt.*\(/local/.*\)$|\1|' | sed 's|^/tmp_mnt/|/|'` dnl Find 'hardtop_plat', the native format for 'hardtop' dnl (i.e., right kind of \dnl slashes on a Win32 box, but with b-slashes |