Skip to content

Commit 94764a6

Browse files
author
William Breathitt Gray
committed
makefile: Fix bootstrap recipe race condition
Since fbrt0.o and libfb.a are statically linked to the bootstrap fbc, rtlib should be listed as a dependency of BOOTSTRAP_FBC. This patch fixes the race condition described in issue #131.
1 parent f008be8 commit 94764a6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1063,7 +1063,7 @@ bootstrap-dist:
10631063
#
10641064
BOOTSTRAP_FBC := bootstrap/fbc$(EXEEXT)
10651065
.PHONY: bootstrap
1066-
bootstrap: rtlib gfxlib2 $(BOOTSTRAP_FBC)
1066+
bootstrap: gfxlib2 $(BOOTSTRAP_FBC)
10671067
mkdir -p bin
10681068
cp $(BOOTSTRAP_FBC) $(FBC_EXE)
10691069

@@ -1089,7 +1089,7 @@ endif
10891089
ifneq ($(filter darwin freebsd linux netbsd openbsd solaris,$(TARGET_OS)),)
10901090
BOOTSTRAP_LIBS := -lncurses -lm -pthread
10911091
endif
1092-
$(BOOTSTRAP_FBC): $(BOOTSTRAP_OBJ)
1092+
$(BOOTSTRAP_FBC): rtlib $(BOOTSTRAP_OBJ)
10931093
$(QUIET_LINK)$(CC) -o $@ $(libdir)/fbrt0.o bootstrap/$(FBTARGET)/*.o $(libdir)/libfb.a $(BOOTSTRAP_LIBS)
10941094

10951095
.PHONY: clean-bootstrap

0 commit comments

Comments
 (0)