#3778: "test -e" in testsuite doesn't work with Solaris /bin/sh
---------------------------+------------------------------------------------
    Reporter:  duncan      |        Owner:                         
        Type:  bug         |       Status:  new                    
    Priority:  normal      |    Milestone:  6.12 branch            
   Component:  Test Suite  |      Version:  6.12.1                 
    Keywords:              |   Difficulty:  Easy (less than 1 hour)
          Os:  Solaris     |     Testcase:                         
Architecture:  sparc       |      Failure:  Other                  
---------------------------+------------------------------------------------
 The `testsuite/mk/boilerplate.mk` contains stuff like:
 {{{
 $(eval $(call canonicaliseExecutable,TEST_HC))
 ifeq "$(shell test -e '$(TEST_HC)' && echo exists)" ""
 $(error Cannot find ghc: $(TEST_HC))
 endif
 }}}

 On Solaris, the `/bin/sh` test builtin does not support the `-e` flag. It
 does support both `-f` and `-x`, meaning regular and executable file
 respectively. I think we probably mean `-x` in this case anyway. With that
 fix the testsuite seems to run ok.

 Looks like we already use `test -x` elsewhere in
 `testsuite/mk/boilerplate.mk` so we can assume that it does work with the
 shell of other platforms.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/3778>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to