[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Need more EXTRA_PROGRAMS variables
From: |
Behdad Esfahbod |
Subject: |
Re: Need more EXTRA_PROGRAMS variables |
Date: |
Mon, 18 Jun 2007 18:13:17 -0400 |
On Sun, 2007-06-17 at 14:18 +0200, Ralf Wildenhues wrote:
> Hello Behdad,
>
> * Behdad Esfahbod wrote on Sun, Jun 17, 2007 at 01:02:27AM CEST:
> >
> > For the first time I'm stuck with an automake problem and think it's an
> > unfair limitation of automake rather than my skills being short.
> >
> > The problem is, the make check target that automake generates builds and
> > runs $(TESTS), but on systems with non-empty EXEEXT this doesn't work.
> >
> > The only way I see to fixing this is to add $(EXEEXT) at the end of all
> > 300 test names in my $(TESTS), which is far from elegant.
>
> Are you using Automake 1.10? Quoting from its NEWS file:
> | - $(EXEEXT) is automatically appended to filenames of TESTS
> | that have been declared as programs in the same Makefile.
> | This is mostly useful when some check_PROGRAMS are listed in TESTS.
>
> Note that CVS (both HEAD and branch-1-10) has a bugfix to do the same
> with XFAIL_TESTS, so that XFAILing is detected reliably.
Ah ok, silly me again. I'm using 1.9.6 still. Will upgrade and check.
Though I need to change some of my rules to handle the $(EXEEXT) at the
end of the test name now.
> Other than that, you may not have known about check_PROGRAMS?
I know about check_PROGRAMS, but that will force a rebuild of all the
tests unnecessarily. That is because we have a few extra targets, like
recheck, that only runs tests that failed last time (detecting from
their log files of course). Or to run one test, we manually do:
make check TESTS=one-test
And if I added $(TESTS) to check_PROGRAMS (like I did first), the line
above would cause relinking all 300 tests after the shared library is
that these test is changed.
Of course that relinking problem is a headache anyway.
> If there are still issues, please show an example where things go wrong,
> including on which system you are experiencing this (esp. if you are
> using a cross setup with a simulator, say).
Adrian (CCed) was experiencing the problem. I guess on Cygwin. I
previously got similar reports from our OS/2 maintainer. I'll upgrade
to automake 1.10, get a release out, and come back to you if the problem
persists on those platforms.
On Sun, 2007-06-17 at 14:31 +0200, Ralf Wildenhues wrote:
> Never mind, I think I misunderstood you first.
> Still I think the mechanism is general enough to support what you need:
>
> ALL_TESTS = a b c
> MORE_PROGS = d e f
> EXTRA_PROGRAMS = $(ALL_TESTS) $(MORE_PROGS)
> TESTS = $(ALL_TESTS)
>
> This causes the entries of TESTS to all have EXEEXT added, which I think
> is what you want, no?
Yes. From what you describe, my problem doesn't exist in 1.10.
> If you can live with $(EXTRA_PROGRAMS) also
> containing the tests, that is. If not, then I'd like to know why not.
I can. But as a separate issue, I think allowing things like
EXTRA_something_PROGRAMS makes sense. One thing I love about automake
is its flexibility, and hardcoding some feature (automatically adding
EXEEXT in this case) to some special variable names but not providing
ways for the user to do the same is not consistent IMHO.
> Thanks,
> Ralf
Thanks, and Cheers,
--
behdad
http://behdad.org/
"Those who would give up Essential Liberty to purchase a little
Temporary Safety, deserve neither Liberty nor Safety."
-- Benjamin Franklin, 1759