util/nvramtool: Create nvramtool object directories earlier

The existing rule created a potential race condition between creating
the directory and putting files in there, so use our existing
infrastructure for directory creation instead.

Change-Id: If52a9f558c7d9ce85f71ba53232594699c9d357a
Signed-off-by: Patrick Georgi <pgeorgi@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/37798
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Jett Rink <jettrink@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Patrick Georgi 2019-12-17 16:59:47 +01:00
parent d76947f13b
commit 186c2f9abc
1 changed files with 1 additions and 2 deletions

View File

@ -36,8 +36,7 @@ NVRAMTOOLLDFLAGS += -lregex -lwsock32
nvramtoolobj += win32mmap.o nvramtoolobj += win32mmap.o
endif endif
$(objutil)/nvramtool $(objutil)/nvramtool/accessors $(objutil)/nvramtool/cli: additional-dirs += $(objutil)/nvramtool/accessors $(objutil)/nvramtool/cli
mkdir -p $@
$(objutil)/nvramtool/%.o: $(top)/util/nvramtool/%.c $(objutil)/nvramtool/%.o: $(top)/util/nvramtool/%.c
printf " HOSTCC $(subst $(objutil)/,,$(@))\n" printf " HOSTCC $(subst $(objutil)/,,$(@))\n"