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