Skip to contentSkip to conversation

Makefile.obexd: add missing mkdir in builtin.h generation

PATCH Applied Ross Burton 2 participants 2 messages Oct 8, 2019 – Oct 9, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Makefile.obexd: add missing mkdir in builtin.h generation

In parallel out-of-tree builds it's possible that obexd/src/builtin.h is generated before the target directory has been implicitly created. Solve this by creating the directory before writing into it.

---
 Makefile.obexd | 1 +
 1 file changed, 1 insertion(+)
Makefile.obexd +1 -0
index d36874770..de59d297b 100644
@@ -104,6 +104,7 @@ BUILT_SOURCES += obexd/src/builtin.h
 obexd/src/plugin.$(OBJEXT): obexd/src/builtin.h
 
 obexd/src/builtin.h: obexd/src/genbuiltin $(obexd_builtin_sources)
+	$(AM_V_at)$(MKDIR_P) $(dir $@)
 	$(AM_V_GEN)$(srcdir)/obexd/src/genbuiltin $(obexd_builtin_modules) > $@
 
 CLEANFILES += obexd/src/builtin.h $(builtin_files) obexd/src/obex.service
Signature · 1 line
2.20.1
maintainer Applied
#1 lore raw

Hi Ross,

Quoted 21 lines · Ross Burton

In parallel out-of-tree builds it's possible that obexd/src/builtin.h is generated before the target directory has been implicitly created. Solve this by creating the directory before writing into it.

---
 Makefile.obexd | 1 +
 1 file changed, 1 insertion(+)
Makefile.obexd +1 -1
index d36874770..de59d297b 100644
@@ -104,6 +104,7 @@ BUILT_SOURCES += obexd/src/builtin.h
 obexd/src/plugin.$(OBJEXT): obexd/src/builtin.h
 
 obexd/src/builtin.h: obexd/src/genbuiltin $(obexd_builtin_sources)
+       $(AM_V_at)$(MKDIR_P) $(dir $@)
        $(AM_V_GEN)$(srcdir)/obexd/src/genbuiltin $(obexd_builtin_modules) > $@
 
 CLEANFILES += obexd/src/builtin.h $(builtin_files) obexd/src/obex.service
--
Quoted 1 line

2.20.1

Applied, thanks.

Signature · 1 line
Luiz Augusto von Dentz