summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor.andersson@artifex.com>2013-05-30 13:45:28 +0200
committerTor Andersson <tor.andersson@artifex.com>2013-05-30 20:17:34 +0200
commit0ae7a6fc4c7b234c35744d583da3ce155a433dc2 (patch)
treee860bdba7308ffa81f0aa99368cae545146443f9
parent8ae573456d60b7ef9ada79196e36b153b73c6874 (diff)
downloadmupdf-0ae7a6fc4c7b234c35744d583da3ce155a433dc2.tar.xz
Delete libraries before updating them.
Makes sure that stale object files are cleared out to prevent build skew if a file is renamed or removed.
-rw-r--r--Makefile3
1 files changed, 3 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 8df5bc87..44ba74a2 100644
--- a/Makefile
+++ b/Makefile
@@ -47,6 +47,7 @@ QUIET_CXX = @ echo ' ' ' ' CXX $@ ;
QUIET_GEN = @ echo ' ' ' ' GEN $@ ;
QUIET_LINK = @ echo ' ' ' ' LINK $@ ;
QUIET_MKDIR = @ echo ' ' ' ' MKDIR $@ ;
+QUIET_RM = @ echo ' ' ' ' RM $@ ;
endif
CC_CMD = $(QUIET_CC) $(CC) $(CFLAGS) -o $@ -c $<
@@ -55,6 +56,7 @@ AR_CMD = $(QUIET_AR) $(AR) cr $@ $^
LINK_CMD = $(QUIET_LINK) $(CC) $(LDFLAGS) -o $@ $^ $(LIBS)
LINK_V8_CMD = $(QUIET_LINK) $(CXX) $(LDFLAGS) -o $@ $^ $(LIBS_V8)
MKDIR_CMD = $(QUIET_MKDIR) mkdir -p $@
+RM_CMD = $(QUIET_RM) rm -f $@
# --- Rules ---
@@ -68,6 +70,7 @@ $(OUT) $(GEN) :
$(MKDIR_CMD)
$(OUT)/%.a :
+ $(RM_CMD)
$(AR_CMD)
$(RANLIB_CMD)