1 # Copyright (C) 2008 The Android Open Source Project 2 # 3 # Licensed under the Apache License, Version 2.0 (the "License"); 4 # you may not use this file except in compliance with the License. 5 # You may obtain a copy of the License at 6 # 7 # http://www.apache.org/licenses/LICENSE-2.0 8 # 9 # Unless required by applicable law or agreed to in writing, software 10 # distributed under the License is distributed on an "AS IS" BASIS, 11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 # See the License for the specific language governing permissions and 13 # limitations under the License. 14 15 LOCAL_PATH := $(call my-dir) 16 17 include $(CLEAR_VARS) 18 19 LOCAL_CLANG := true 20 LOCAL_SRC_FILES := applypatch.cpp bspatch.cpp freecache.cpp imgpatch.cpp utils.cpp 21 LOCAL_MODULE := libapplypatch 22 LOCAL_MODULE_TAGS := eng 23 LOCAL_C_INCLUDES += bootable/recovery 24 LOCAL_STATIC_LIBRARIES += libbase libotafault libmtdutils libcrypto_static libbz libz 25 26 include $(BUILD_STATIC_LIBRARY) 27 28 include $(CLEAR_VARS) 29 30 LOCAL_CLANG := true 31 LOCAL_SRC_FILES := bspatch.cpp imgpatch.cpp utils.cpp 32 LOCAL_MODULE := libimgpatch 33 LOCAL_C_INCLUDES += bootable/recovery 34 LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/include 35 LOCAL_STATIC_LIBRARIES += libcrypto_static libbz libz 36 37 include $(BUILD_STATIC_LIBRARY) 38 39 ifeq ($(HOST_OS),linux) 40 include $(CLEAR_VARS) 41 42 LOCAL_CLANG := true 43 LOCAL_SRC_FILES := bspatch.cpp imgpatch.cpp utils.cpp 44 LOCAL_MODULE := libimgpatch 45 LOCAL_C_INCLUDES += bootable/recovery 46 LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/include 47 LOCAL_STATIC_LIBRARIES += libcrypto_static libbz libz 48 49 include $(BUILD_HOST_STATIC_LIBRARY) 50 endif # HOST_OS == linux 51 52 include $(CLEAR_VARS) 53 54 LOCAL_CLANG := true 55 LOCAL_SRC_FILES := main.cpp 56 LOCAL_MODULE := applypatch 57 LOCAL_C_INCLUDES += bootable/recovery 58 LOCAL_STATIC_LIBRARIES += libapplypatch libbase libotafault libmtdutils libcrypto_static libbz \ 59 libedify \ 60 61 LOCAL_SHARED_LIBRARIES += libz libcutils libc 62 63 include $(BUILD_EXECUTABLE) 64 65 include $(CLEAR_VARS) 66 67 LOCAL_CLANG := true 68 LOCAL_SRC_FILES := imgdiff.cpp utils.cpp bsdiff.cpp 69 LOCAL_MODULE := imgdiff 70 LOCAL_FORCE_STATIC_EXECUTABLE := true 71 LOCAL_C_INCLUDES += external/zlib external/bzip2 72 LOCAL_STATIC_LIBRARIES += libz libbz 73 74 include $(BUILD_HOST_EXECUTABLE) 75