Skip to content

Commit

Permalink
Merge pull request #47504 from BrettDong/clean-pch
Browse files Browse the repository at this point in the history
Add a 'clean-pch' target to Makefile that cleans PCH
  • Loading branch information
ZhilkinSerg authored Feb 14, 2021
2 parents b985712 + 9a3b65e commit 05a58cb
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -967,16 +967,13 @@ $(CHKJSON_BIN): $(CHKJSON_SOURCES)
json-check: $(CHKJSON_BIN)
./$(CHKJSON_BIN)

clean: clean-tests clean-object_creator
clean: clean-tests clean-object_creator clean-pch
rm -rf *$(TARGET_NAME) *$(TILES_TARGET_NAME)
rm -rf *$(TILES_TARGET_NAME).exe *$(TARGET_NAME).exe *$(TARGET_NAME).a
rm -rf *obj *objwin
rm -rf *$(BINDIST_DIR) *cataclysmdda-*.tar.gz *cataclysmdda-*.zip
rm -f $(SRC_DIR)/version.h
rm -f $(CHKJSON_BIN)
rm -f pch/*pch.hpp.gch
rm -f pch/*pch.hpp.pch
rm -f pch/*pch.hpp.d

distclean:
rm -rf *$(BINDIST_DIR)
Expand Down Expand Up @@ -1220,7 +1217,12 @@ object_creator: version $(BUILD_PREFIX)cataclysm.a
clean-object_creator:
$(MAKE) -C object_creator clean

.PHONY: tests check ctags etags clean-tests install lint
clean-pch:
rm -f pch/*pch.hpp.gch
rm -f pch/*pch.hpp.pch
rm -f pch/*pch.hpp.d

.PHONY: tests check ctags etags clean-tests clean-object_creator clean-pch install lint

-include $(SOURCES:$(SRC_DIR)/%.cpp=$(DEPDIR)/%.P)
-include ${OBJS:.o=.d}

0 comments on commit 05a58cb

Please sign in to comment.