This is the mail archive of the automake@gnu.org mailing list for the automake project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: $srcdir


Hi,

Harlan Stenn <Harlan dot Stenn at pfcs dot com> writes:

>> But if I echo either $top_srcdir or $top_builddir, in the file
>> tests/foo.test, they are both null, so I can't seem to find a way of
>> referring to any files. 
>
> AC_OUTPUT your test scripts using foo.in -> foo rules, and include lines
> like:
>
>  top_srdir= at top_srcdir@
>
> in them.
>
> Either that, or AC_OUTPUT a vbls.conf.in -> vbls.conf file which does this
> and "source" this file in from your scripts.

That's too heavy-handed for tests.  The idiom for tests is to use

  TESTS_ENVIRONMENT = srcdir=$(srcdir) top_srcdir=$(top_srcdir)

This is assuming the test scripts are listed in check_TESTS.

- Hari
-- 
Raja R Harinath ------------------------------ harinath at cs dot umn dot edu



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]