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