In parallel out-of-tree builds it is possible for e.g. ivi-shell/weston.ini to
be written before ivi-shell/ exists. Solve this by creating the target
directory first.
Signed-off-by: Ross Burton <ross.burton@intel.com>
Reviewed-by: Quentin Glidic <sardemff7+git@sardemff7.net>
$< > $@
ivi-shell/weston.ini : $(srcdir)/ivi-shell/weston.ini.in
- $(AM_V_GEN)$(SED) \
+ $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(SED) \
-e 's|@bindir[@]|$(bindir)|g' \
-e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
-e 's|@abs_top_srcdir[@]|$(abs_top_srcdir)|g' \
$< > $@
tests/weston-ivi.ini : $(srcdir)/ivi-shell/weston.ini.in
- $(AM_V_GEN)$(SED) \
+ $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(SED) \
-e 's|@bindir[@]|$(bindir)|g' \
-e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
-e 's|@abs_top_srcdir[@]|$(abs_top_srcdir)|g' \