1*055d4590SKeyi Gui# Copyright (C) 2007 The Android Open Source Project 2*055d4590SKeyi Gui# 3*055d4590SKeyi Gui# Licensed under the Apache License, Version 2.0 (the "License"); 4*055d4590SKeyi Gui# you may not use this file except in compliance with the License. 5*055d4590SKeyi Gui# You may obtain a copy of the License at 6*055d4590SKeyi Gui# 7*055d4590SKeyi Gui# http://www.apache.org/licenses/LICENSE-2.0 8*055d4590SKeyi Gui# 9*055d4590SKeyi Gui# Unless required by applicable law or agreed to in writing, software 10*055d4590SKeyi Gui# distributed under the License is distributed on an "AS IS" BASIS, 11*055d4590SKeyi Gui# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12*055d4590SKeyi Gui# See the License for the specific language governing permissions and 13*055d4590SKeyi Gui# limitations under the License. 14*055d4590SKeyi Gui# 15*055d4590SKeyi Gui 16*055d4590SKeyi Gui# If you don't need to do a full clean build but would like to touch 17*055d4590SKeyi Gui# a file or delete some intermediate files, add a clean step to the end 18*055d4590SKeyi Gui# of the list. These steps will only be run once, if they haven't been 19*055d4590SKeyi Gui# run before. 20*055d4590SKeyi Gui# 21*055d4590SKeyi Gui# E.g.: 22*055d4590SKeyi Gui# $(call add-clean-step, touch -c external/sqlite/sqlite3.h) 23*055d4590SKeyi Gui# $(call add-clean-step, rm -rf $(OUT)/obj/STATIC_LIBRARIES/libz_intermediates) 24*055d4590SKeyi Gui# 25*055d4590SKeyi Gui# Always use "touch -c" and "rm -f" or "rm -rf" to gracefully deal with 26*055d4590SKeyi Gui# files that are missing or have been moved. 27*055d4590SKeyi Gui# 28*055d4590SKeyi Gui# Use $(PRODUCT_OUT) to get to the "out/target/product/blah/" directory. 29*055d4590SKeyi Gui# Use $(OUT) to refer to the "out" directory. 30*055d4590SKeyi Gui# 31*055d4590SKeyi Gui# If you need to re-do something that's already mentioned, just copy 32*055d4590SKeyi Gui# the command and add it to the bottom of the list. E.g., if a change 33*055d4590SKeyi Gui# that you made last week required touching a file and a change you 34*055d4590SKeyi Gui# made today requires touching the same file, just copy the old 35*055d4590SKeyi Gui# touch step and add it to the end of the list. 36*055d4590SKeyi Gui# 37*055d4590SKeyi Gui# ************************************************ 38*055d4590SKeyi Gui# NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST 39*055d4590SKeyi Gui# ************************************************ 40*055d4590SKeyi Gui 41*055d4590SKeyi Gui# For example: 42*055d4590SKeyi Gui#$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/APPS/AndroidTests_intermediates) 43*055d4590SKeyi Gui#$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/core_intermediates) 44*055d4590SKeyi Gui#$(call add-clean-step, find $(OUT_DIR) -type f -name "IGTalkSession*" -print0 | xargs -0 rm -f) 45*055d4590SKeyi Gui#$(call add-clean-step, rm -rf $(PRODUCT_OUT)/data/*) 46*055d4590SKeyi Gui#$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libdvm*) 47*055d4590SKeyi Gui$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libdvm*) 48*055d4590SKeyi Gui$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libdvm*) 49*055d4590SKeyi Gui$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libdvm*) 50*055d4590SKeyi Gui$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libdvm*) 51*055d4590SKeyi Gui$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libdvm*) 52*055d4590SKeyi Gui$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libdvm*) 53*055d4590SKeyi Gui$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/SHARED_LIBRARIES/libdvm*) 54*055d4590SKeyi Gui# ************************************************ 55*055d4590SKeyi Gui# NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST 56*055d4590SKeyi Gui# ************************************************ 57*055d4590SKeyi Gui$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/STATIC_LIBRARIES/libdex_intermediates/import_includes) 58