%.c: %.y # Cancel built-in rules for yacc
%.h: %.y # Cancel built-in rules for yacc
%.cpp %.h : %.y
- @${ECHO} Bisoning $<
+ @${ECHO} "Bisoning `basename $<`"
$(VERB) $(BISON) -v -d -p $(<F:%Parser.y=%) -o $*.tab.c $<
$(VERB) cmp -s $*.tab.c $*.cpp > /dev/null || ${MV} -f $*.tab.c $*.cpp
$(VERB) cmp -s $*.tab.h $*.h > /dev/null || ${MV} -f $*.tab.h $*.h
# Create dependencies for the *.cpp files...
$(BUILD_OBJ_DIR)/Depend/%.d: %.cpp $(BUILD_OBJ_DIR)/Depend/.dir
- $(VERB) $(Depend) $< | $(SED) 's|\.o|\.lo|' | $(SED) 's|$*\.lo *|$(BUILD_OBJ_DIR)/Release/& $(BUILD_OBJ_DIR)/Profile/& $(BUILD_OBJ_DIR)/Debug/& $(BUILD_OBJ_DIR)/Depend/$(@F)|g' > $@
+ $(VERB) $(Depend) $< | $(SED) 's|\.o:|\.lo:|' | $(SED) 's|$*\.lo *|$(BUILD_OBJ_DIR)/Release/& $(BUILD_OBJ_DIR)/Profile/& $(BUILD_OBJ_DIR)/Debug/& $(BUILD_OBJ_DIR)/Depend/$(@F)|g' > $@
# Create dependencies for the *.c files...
$(BUILD_OBJ_DIR)/Depend/%.d: %.c $(BUILD_OBJ_DIR)/Depend/.dir
- $(VERB) $(DependC) -o $@ $< | $(SED) 's|\.o|\.lo|' | $(SED) 's|$*\.lo *|$(BUILD_OBJ_DIR)/Release/& $(BUILD_OBJ_DIR)/Profile/& $(BUILD_OBJ_DIR)/Debug/& $(BUILD_OBJ_DIR)/Depend/$(@F)|g' > $@
+ $(VERB) $(DependC) -o $@ $< | $(SED) 's|\.o:|\.lo:|' | $(SED) 's|$*\.lo *|$(BUILD_OBJ_DIR)/Release/& $(BUILD_OBJ_DIR)/Profile/& $(BUILD_OBJ_DIR)/Debug/& $(BUILD_OBJ_DIR)/Depend/$(@F)|g' > $@
#
# Autoconf Dependencies.
@${ECHO} "****************************************************************"
$(VERB) exit 1
+# If the Makefile in the source tree has been updated, copy it over into the
+# build tree.
+Makefile :: $(BUILD_SRC_DIR)/Makefile
+ @${ECHO} "===== Updating Makefile from source dir: `dirname $<` ====="
+ cp -f $< $@
+
#
# Include dependencies generated from C/C++ source files, but not if we
# are cleaning (this example taken from the GNU Make Manual).