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