Re: [commit: testsuite] master: Fix library way detection; fixes the ImpSafeOnly* tests when BINDIST=YES (b32d38a)

On Fri, May 10, 2013 at 3:40 PM, Ian Lynagh
Fix library way detection; fixes the ImpSafeOnly* tests when BINDIST=YES
We were checking paths with if [ -f '"/path/to/Prelude"' ] i.e. the " quotes were being quoted by the ' quotes. Now we just use " quotes (which come from the ghc-pkg output).
This does not work (again) on the FreeBSD builder clients. Any suggestions where else to fix this problem for them then?

On Sun, May 12, 2013 at 11:27:10AM +0200, Páli Gábor János wrote:
On Fri, May 10, 2013 at 3:40 PM, Ian Lynagh
wrote: Fix library way detection; fixes the ImpSafeOnly* tests when BINDIST=YES
We were checking paths with if [ -f '"/path/to/Prelude"' ] i.e. the " quotes were being quoted by the ' quotes. Now we just use " quotes (which come from the ghc-pkg output).
This does not work (again) on the FreeBSD builder clients. Any suggestions where else to fix this problem for them then?
I'm confused. What does make show VALUE=BASE_LIBDIR say in testsuite/tests? What command is being run to cause the error? Does this work on FreeBSD?: [ -f "foo bar"baz ] && echo yes Thanks Ian

On Sun, May 12, 2013 at 1:32 PM, Ian Lynagh
I'm confused.
Same here :-)
What does make show VALUE=BASE_LIBDIR say in testsuite/tests?
BASE_LIBDIR="/usr/home/user/ghc-validate/libraries/base/dist-install/build /usr/local/lib" Ah, it seems there is another directory added? I was completely under the impression that the problem is that the binary distribution is installed to the directory with spaces in its name.
What command is being run to cause the error?
I guess this is the HAVE_* lines, the [ -f file ] part that you have changed in the commit. See http://darcs.haskell.org/ghcBuilder/builders/pgj/1033/18.html for the details. There you should find a lot of error messages like this one: [: /tmp/builder/tempbuild/build/bindisttest/install dir/lib/ghc-7.7.20130512/base-4.7.0.0: unexpected operator
Does this work on FreeBSD?: [ -f "foo bar"baz ] && echo yes
No output. But: $ [ -f "foo bar" baz ] && echo yes [: foo bar: unexpected operator

On Sun, May 12, 2013 at 02:39:14PM +0200, Páli Gábor János wrote:
On Sun, May 12, 2013 at 1:32 PM, Ian Lynagh
wrote: What does make show VALUE=BASE_LIBDIR say in testsuite/tests?
BASE_LIBDIR="/usr/home/user/ghc-validate/libraries/base/dist-install/build /usr/local/lib"
Ah, it seems there is another directory added? I was completely under the impression that the problem is that the binary distribution is installed to the directory with spaces in its name.
Oh, sorry, it's actually make show VALUE=BASE_LIBDIR BINDIST=YES that we want.
What command is being run to cause the error?
I guess this is the HAVE_* lines, the [ -f file ] part that you have changed in the commit.
Right, but what does the actual shell command look like once all the make variable expansion has happened? Thanks Ian

On Sun, May 12, 2013 at 3:02 PM, Ian Lynagh
Oh, sorry, it's actually make show VALUE=BASE_LIBDIR BINDIST=YES that we want.
BASE_LIBDIR=""/usr/home/user/ghc-working/bindisttest/install dir/lib/ghc-7.7.20130510/base-4.7.0.0" /usr/local/lib"
what does the actual shell command look like once all the make variable expansion has happened?
if [ -f /usr/home/user/ghc-working/libraries/base/dist-install/build /usr/local/lib/Prelude.hi ]; then echo YES; else echo NO; fi

On Sun, May 12, 2013 at 03:50:17PM +0200, Páli Gábor János wrote:
On Sun, May 12, 2013 at 3:02 PM, Ian Lynagh
wrote: Oh, sorry, it's actually make show VALUE=BASE_LIBDIR BINDIST=YES that we want.
BASE_LIBDIR=""/usr/home/user/ghc-working/bindisttest/install dir/lib/ghc-7.7.20130510/base-4.7.0.0" /usr/local/lib"
I've made it use ghc-prim rather than base, so we shouldn't get this extra directory. Hopefully that will fix it. Thanks Ian

On Sun, May 12, 2013 at 6:02 PM, Ian Lynagh
I've made it use ghc-prim rather than base, so we shouldn't get this extra directory. Hopefully that will fix it.
Cool, thanks! I can locally confirm that it indeed does the trick, hope the nightly builders will think the same. I think the extra directory for base is related to the fact that the FreeBSD version keeps the third-party additions under /usr/local.
participants (2)
-
Ian Lynagh
-
Páli Gábor János