mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 481350 - Fail when imacros.c.out is out of date, r=jorendorff/ted
This commit is contained in:
parent
e6dcf3b22b
commit
5000827e05
@ -649,23 +649,26 @@ $(addsuffix .$(OBJ_SUFFIX),jsdtracef jsinterp jsobj): $(CURDIR)/javascript-trace
|
||||
endif
|
||||
|
||||
ifdef GNU_CC
|
||||
ifndef CROSS_COMPILE
|
||||
# If we don't have run-mozilla.sh *and* we're linking against NSPR, we don't
|
||||
# know how to run the JS binary. Oh well
|
||||
|
||||
imacro_asm.js: imacro_asm.js.in jsopcode.tbl
|
||||
$(CC) -c -x c -E -P -I$(srcdir) $< > $@
|
||||
|
||||
GARBAGE += imacros.c.out imacro_asm.js
|
||||
GARBAGE += imacros.c.tmp imacro_asm.js
|
||||
|
||||
ifndef CROSS_COMPILE
|
||||
# Obsolete comment: if you replace update-imacros with libs, this would apply
|
||||
# but then parallel gmake would sometimes try to run $(DIST)/bin/js before it
|
||||
# had been built and installed. Want a fix for this, de-automating for now.
|
||||
ifneq (,$(wildcard $(RUN_TEST_PROGRAM))$(if $(NSPR_LIBS),,1))
|
||||
libs:: imacros.c.tmp imacro_asm.js $(srcdir)/imacros.jsasm
|
||||
$(wildcard $(RUN_TEST_PROGRAM)) $(DIST)/bin/js$(BIN_SUFFIX) imacro_asm.js $(srcdir)/imacros.jsasm > $<
|
||||
@cmp -s $< $(srcdir)/imacros.c.out || \
|
||||
(echo "imacros.c.out is out of date. Run 'make update-imacros' to copy it to your source tree."; diff -U 4 $(srcdir)/imacros.c.out $<; exit 1)
|
||||
@echo "imacros.c.out is up to date"
|
||||
|
||||
# Build imacros.c.out after descending into DIRS and building the js shell.
|
||||
# This may result in an updated imacros.c.out file that requires a re-build
|
||||
# to stabilize.
|
||||
update-imacros:: imacros.c.out
|
||||
@cmp -s imacros.c.out $(srcdir)/$< || cp imacros.c.out $(srcdir)
|
||||
update-imacros: imacros.c.tmp
|
||||
cp $< $(srcdir)/imacros.c.out
|
||||
|
||||
%.c.out: %.jsasm imacro_asm.js
|
||||
$(DIST)/bin/js imacro_asm.js $< > $@
|
||||
.PHONY: update-imacros
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
Loading…
Reference in New Issue
Block a user