summaryrefslogtreecommitdiff
path: root/Makefile.src.in
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-08-18 17:49:28 +0000
committerrubidium <rubidium@openttd.org>2009-08-18 17:49:28 +0000
commit82105604c3d76fda3df94c5f6b556da00a5fb557 (patch)
tree8097e3589ac2f37e522557b9a545ee6a4a7ac6a3 /Makefile.src.in
parentf595668650b342c5d7150fcbb1986b572a7f37e7 (diff)
downloadopenttd-82105604c3d76fda3df94c5f6b556da00a5fb557.tar.xz
(svn r17212) -Change: move minilzo to its 'own' 3rdparty directory as it belongs there
Diffstat (limited to 'Makefile.src.in')
-rw-r--r--Makefile.src.in8
1 files changed, 8 insertions, 0 deletions
diff --git a/Makefile.src.in b/Makefile.src.in
index c5c590dd1..eacb19936 100644
--- a/Makefile.src.in
+++ b/Makefile.src.in
@@ -126,6 +126,10 @@ endif
# Find the deps via GCC. Rarely wrong, but a bit slow
+$(OBJS_C:%.o=%.d): %.d: $(SRC_DIR)/%.c $(FILE_DEP)
+ $(E) '$(STAGE) DEP $(<:$(SRC_DIR)/%.c=%.c)'
+ $(Q)$(CC_HOST) $(CFLAGS) -MM $< | sed 's@^$(@F:%.d=%.o):@$@ $(@:%.d=%.o):@' > $@
+
$(OBJS_CPP:%.o=%.d): %.d: $(SRC_DIR)/%.cpp $(FILE_DEP)
$(E) '$(STAGE) DEP $(<:$(SRC_DIR)/%.cpp=%.cpp)'
$(Q)$(CXX_HOST) $(CFLAGS) -MM $< | sed 's@^$(@F:%.d=%.o):@$@ $(@:%.d=%.o):@' > $@
@@ -214,6 +218,10 @@ endif
# Compile all the files according to the targets
+$(OBJS_C): %.o: $(SRC_DIR)/%.c $(DEP_MASK) $(FILE_DEP)
+ $(E) '$(STAGE) Compiling $(<:$(SRC_DIR)/%.c=%.c)'
+ $(Q)$(CC_HOST) $(CFLAGS) -c -o $@ $<
+
$(OBJS_CPP): %.o: $(SRC_DIR)/%.cpp $(DEP_MASK) $(FILE_DEP)
$(E) '$(STAGE) Compiling $(<:$(SRC_DIR)/%.cpp=%.cpp)'
$(Q)$(CXX_HOST) $(CFLAGS) -c -o $@ $<