Ralf Wildenhues wrote: > * Dave Korn wrote on Sun, Aug 16, 2009 at 06:26:11PM CEST:
>>>> +AT_CHECK([$LIBTOOL --mode=install $lt_INSTALL main$EXEEXT >>>> $curdir/bin/main$EXEEXT], [], [ignore], [ignore]) >>>> +AT_CHECK([$LIBTOOL --mode=execute $curdir/bin/main$EXEEXT], [], [stdout]) >>> This one should work without "$LIBTOOL --mode=execute" prepended, no? >> I have no idea. I just copied the only other things in the testsuite that >> I >> could identify as execution tests. What does it actually *do*? > > Run an installed program. Installed programs ought to run without > $LIBTOOL prepended. Did you mean "Run an *un*installed program" in the first part of that? I'll assume so. >>> Out of curiosity, which of the systems of interest creates a >>> libfoo.so.0 file? >> Linux. > > But you're not interested in testing GNU/Linux with $bindirneeded. > Neither any of the other unices, which might not have a libfoo.so.0, > but instead a libfoo.a (shared library! sic! on AIX) or a libfoo.0.so > or libfoo.so.0.0 or whatnot. So make life easy here, and drop all the > .so thingy tests, you don't want them here. Thanks. But I do want to make sure the file went to the right place, or at the very least, that it did *not* go to the -bindir. Hmm. I can't easily use a pattern match either as it might match more than one file and confuse the test -f syntax. Guess I'll have to `ls *foo*0*` them and test -z the output, that should work. >>> What if that is a symlink rather than a plain file >>> ("test -f" only tests for plain files)? >> It is. The test still passes. Hmmmm..... better take a closer look at >> that. (And use the full so.0.0.0 name in the test). > > Yeah, that's due to $bindirneeded. But that just makes it test -f for the same name in a different directory, so it still ought to fail. It turns out that, at least for bash on my Fedora 10 VM, test -f works for symlinks: > [da...@ubique .libs]$ if test -f libfoo.so.0 ; then echo yes ; else echo no ; > fi > yes > [da...@ubique .libs]$ if test -f libfoo.so.0.0.0 ; then echo yes ; else echo > no ; fi > yes > [da...@ubique .libs]$ ls -la libfoo.so.0* > lrwxrwxrwx 1 davek davek 15 2009-08-16 20:55 libfoo.so.0 -> libfoo.so.0.0.0 > -rwxrwxr-x 1 davek davek 5425 2009-08-16 20:55 libfoo.so.0.0.0 > [da...@ubique .libs]$ echo $BASH_VERSION > 3.2.39(1)-release > [da...@ubique .libs]$ Weird. Anyway, I won't rely on it. cheers, DaveK