When I perform a parallel (MAKE="gmake -j4") build for derived
sources, the derived sources are not always produced before the non
derived sources are built. This is a problem as Foo_real.cpp includes
Foo_derived.h.
Perhaps this is a make problem? I'm using gnu make 3.76.1 and automake
1.4.
How can I get a result similar to the old BUILT_SOURCES, where the
commands to produce the derived source files for a target are run
_before_ the non derived source files of that target are built?
I assume others using yacc or CORBA have similar problems.
Is the solution to always make dependancies before a parallel build
commences? AFAICT automake does not provide a top level "make dep"
target to produce dependacies before building. In fact this probably
is not desirable anyway as it requires developers to remember and wait
for the extra step.
e.g.
libFoo_la_SOURCES = \
Foo_c.hh Foo_c.cpp \
Foo_s.hh Foo_s.cpp \
Foo_impl.h Foo_impl.cpp
I would like to ensure that Foo_[sc].hh and Foo_[sc].cpp are present
before Foo_impl.cpp is built for the first time.
At the moment parallel builds work if I first build non-parallel (to
get the .deps), make clean (which leaves the .deps in place) and then
make "MAKE -j4". I am very loath to check dependancies files into CVS.
TIA
Alex.