summaryrefslogtreecommitdiff
path: root/py
diff options
context:
space:
mode:
authorJeff Epler <jepler@gmail.com>2019-12-16 15:33:55 -0600
committerJeff Epler <jepler@gmail.com>2019-12-16 15:33:55 -0600
commit201f4648c40c13bdbf91f8cc078c1fbecc09256d (patch)
treee584d92234416af386cd6f6ade2eb63add8cdd70 /py
parent8384e4676b5f7e4c06fd8f1db53382b6f3e6d175 (diff)
py.mk: Fix race condition building .mo files
By having an order-only dependency on the directory itself, the directory is sure to be created before the rule to create a .mo file is. This fixes a low-freqency error on github actions such as > msgfmt: error while opening "build/genhdr/en_US.mo" for writing: No such file or directory
Diffstat (limited to 'py')
-rw-r--r--py/py.mk2
1 files changed, 1 insertions, 1 deletions
diff --git a/py/py.mk b/py/py.mk
index 0c68e9af1..9031c009f 100644
--- a/py/py.mk
+++ b/py/py.mk
@@ -317,7 +317,7 @@ SRC_QSTR += $(HEADER_BUILD)/moduledefs.h
# overall config, so they need to be caught
MPCONFIGPORT_MK = $(wildcard mpconfigport.mk)
-$(HEADER_BUILD)/$(TRANSLATION).mo: $(TOP)/locale/$(TRANSLATION).po
+$(HEADER_BUILD)/$(TRANSLATION).mo: $(TOP)/locale/$(TRANSLATION).po | $(HEADER_BUILD)
$(Q)msgfmt -o $@ $^
$(HEADER_BUILD)/qstrdefs.preprocessed.h: $(PY_QSTR_DEFS) $(QSTR_DEFS) $(QSTR_DEFS_COLLECTED) mpconfigport.h $(MPCONFIGPORT_MK) $(PY_SRC)/mpconfig.h | $(HEADER_BUILD)