diff --git a/Makefile b/Makefile index ba43b81c..0cfc582f 100644 --- a/Makefile +++ b/Makefile @@ -134,6 +134,14 @@ endif # libraries. ICG_EXE := ${TRICK_HOME}/bin/trick-ICG +################################################################################ +# Formating Variables +################################################################################ + +# Appends a newline to the -w / --print-directories leaving message for make. +# This helps break up directory traversal into blocks. +MAKE_TRAVERSAL_NEWLINE := | sed '/^make.*: Leaving directory/a\ ' + ################################################################################ # RULES ################################################################################ @@ -269,43 +277,54 @@ sim_test: # CLEAN Targets ################################################################################ - clean: clean_sim_serv clean_utils clean_swig clean_dp clean_ICG clean_java @/bin/rm -rf $(TRICK_BIN_DIR) @/bin/rm -rf $(TRICK_LIB_DIR) + @echo -e "\e[31m# #" + @echo -e "\e[33m## ##" + @echo -e "\e[32m### ###" + @echo -e "\e[34m#### ####" + @echo -e "\e[35m##### #####" + @echo -e "\e[39m-----Trick has been successfully cleaned.-----" + @echo -e "\e[35m##### #####" + @echo -e "\e[34m#### ####" + @echo -e "\e[32m### ###" + @echo -e "\e[33m## ##" + @echo -e "\e[31m# #\n" + ifeq ($(USE_ER7_UTILS), 1) clean: clean_er7_utils endif clean_sim_serv: @for i in $(SIM_SERV_DIRS) ; do \ - $(MAKE) -C $$i real_clean ; \ + $(MAKE) -C $$i real_clean $(MAKE_TRAVERSAL_NEWLINE); \ done - @ $(MAKE) -C ${TRICK_HOME}/trick_source/sim_services/mains real_clean + @ $(MAKE) -C ${TRICK_HOME}/trick_source/sim_services/mains real_clean $(MAKE_TRAVERSAL_NEWLINE) clean_er7_utils: make_er7_makefiles @for i in $(ER7_UTILS_DIRS) ; do \ - $(MAKE) -C $$i real_clean ; \ + $(MAKE) -C $$i real_clean $ $(MAKE_TRAVERSAL_NEWLINE); \ rm $$i/Makefile; \ done clean_utils: @for i in $(UTILS_DIRS) ; do \ - $(MAKE) -C $$i real_clean ; \ + $(MAKE) -C $$i real_clean $(MAKE_TRAVERSAL_NEWLINE); \ done clean_swig: @for i in $(SWIG_DIRS) ; do \ - $(MAKE) -C $$i real_clean ; \ + $(MAKE) -C $$i real_clean $(MAKE_TRAVERSAL_NEWLINE); \ done ifeq ($(USE_ER7_UTILS), 1) -clean_swig: make_er7_makefiles +clean_swig: make_er7_makefiles endif clean_ICG : - $(MAKE) -C ${TRICK_HOME}/trick_source/codegen/Interface_Code_Gen clean + @ $(MAKE) -C ${TRICK_HOME}/trick_source/codegen/Interface_Code_Gen clean $(MAKE_TRAVERSAL_NEWLINE) clean_unit_test: @/bin/rm -rf ${TRICK_HOME}/trick_test/*.xml @@ -314,14 +333,13 @@ clean_unit_test: done clean_doxygen: - @ $(MAKE) -C ${TRICK_HOME}/doxygen clean - + @ $(MAKE) -C ${TRICK_HOME}/doxygen clean $(MAKE_TRAVERSAL_NEWLINE) clean_dp: - @ $(MAKE) clean -C ${TRICK_HOME}/trick_source/data_products + @ $(MAKE) clean -C ${TRICK_HOME}/trick_source/data_products $(MAKE_TRAVERSAL_NEWLINE) clean_java: - @ $(MAKE) -C ${TRICK_HOME}/trick_source/java clean + @ $(MAKE) -C ${TRICK_HOME}/trick_source/java clean $(MAKE_TRAVERSAL_NEWLINE) # FIXME: Seems to me that the for loop below should be removed and that the diff --git a/share/trick/makefiles/Makefile.tricklib b/share/trick/makefiles/Makefile.tricklib index f9162d69..603ed2ba 100644 --- a/share/trick/makefiles/Makefile.tricklib +++ b/share/trick/makefiles/Makefile.tricklib @@ -161,6 +161,12 @@ $(Y_OBJS) : $(OBJ_DIR)/%.tab.o : $(SRC_DIR)%.tab.c | $(OBJ_DIR) $(CD_CMD) $(TRICK_CPPC) $(TRICK_CXXFLAGS) $(TRICK_SYSTEM_CXXFLAGS) -c ${