[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
using same automake conditional twice doesn't work?
From: |
Ed Hartnett |
Subject: |
using same automake conditional twice doesn't work? |
Date: |
Tue, 07 Jun 2005 09:48:03 -0600 |
User-agent: |
Gnus/5.1006 (Gnus v5.10.6) Emacs/21.4 (gnu/linux) |
Howdy all!
The following automake file attempts to add two subdirs, "fortran" and
"nf_test", if the BUILD_F77 automake conditional is true. But this
fails:
SUBDIRS = man
if BUILD_F77
SUBDIRS += fortran
endif
SUBDIRS += libsrc nc_test ncgen ncdump nctest
# If we're building the f77 API, test it too.
if BUILD_F77
SUBDIRS += nf_test
endif
The problem is that nf_test is not added to the end of the list, it is
added as the third item. So instead of trying to build in this order:
man fortran libsrc nc_test ncgen ncdump nctest nf_test
The resulting makefiles build in this order, which fails:
man fortran nf_test libsrc nc_test ncgen ncdump nctest
Is this a know Automake feature, or am I doing something wrong?
What I do to get around this is define an extra automake conditional,
TEST_F77, at the same time I define BUILD_F77. By using first
BUILD_F77, then TEST_F77, automake does things in the correct order.
Any comments or observations would be helpful.
Thanks!
Ed
--
Ed Hartnett -- address@hidden
- using same automake conditional twice doesn't work?,
Ed Hartnett <=