Ying Wang | b335bb0 | 2011-11-29 10:23:55 -0800 | [diff] [blame] | 1 | # |
| 2 | # Copyright (C) 2010 The Android Open Source Project |
| 3 | # |
| 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | # you may not use this file except in compliance with the License. |
| 6 | # You may obtain a copy of the License at |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 10 | # Unless required by applicable law or agreed to in writing, software |
| 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | # See the License for the specific language governing permissions and |
| 14 | # limitations under the License. |
| 15 | # |
| 16 | |
| 17 | LOCAL_PATH:= $(call my-dir) |
Ying Wang | c703682 | 2015-04-16 11:54:37 -0700 | [diff] [blame] | 18 | |
Yohann Roussel | 855a950 | 2016-08-19 18:58:57 +0200 | [diff] [blame] | 19 | # $(1): sdk version |
| 20 | define declare_sdk_prebuilts |
| 21 | |
Ying Wang | b335bb0 | 2011-11-29 10:23:55 -0800 | [diff] [blame] | 22 | include $(CLEAR_VARS) |
Yohann Roussel | 855a950 | 2016-08-19 18:58:57 +0200 | [diff] [blame] | 23 | LOCAL_MODULE := sdk_v$(1) |
| 24 | LOCAL_SRC_FILES := $(1)/android.jar |
| 25 | LOCAL_MODULE_CLASS := JAVA_LIBRARIES |
| 26 | LOCAL_MODULE_SUFFIX := $(COMMON_JAVA_PACKAGE_SUFFIX) |
| 27 | LOCAL_BUILT_MODULE_STEM := sdk_v$(1)$(COMMON_JAVA_PACKAGE_SUFFIX) |
Dan Willemsen | e383f13 | 2016-09-30 18:41:21 -0700 | [diff] [blame] | 28 | LOCAL_MIN_SDK_VERSION := $(if $(call math_is_number,$(strip $(1))),$(1),$(PLATFORM_JACK_MIN_SDK_VERSION)) |
Yohann Roussel | 855a950 | 2016-08-19 18:58:57 +0200 | [diff] [blame] | 29 | LOCAL_UNINSTALLABLE_MODULE := true |
| 30 | include $(BUILD_PREBUILT) |
Ying Wang | b335bb0 | 2011-11-29 10:23:55 -0800 | [diff] [blame] | 31 | |
Colin Cross | 449c318 | 2016-10-21 10:35:17 -0700 | [diff] [blame^] | 32 | ifneq (,$(wildcard $(LOCAL_PATH)/$(1)/uiautomator.jar)) |
Yohann Roussel | 855a950 | 2016-08-19 18:58:57 +0200 | [diff] [blame] | 33 | include $(CLEAR_VARS) |
| 34 | LOCAL_MODULE := uiautomator_sdk_v$(1) |
| 35 | LOCAL_SRC_FILES := $(1)/uiautomator.jar |
| 36 | LOCAL_MODULE_CLASS := JAVA_LIBRARIES |
| 37 | LOCAL_MODULE_SUFFIX := $(COMMON_JAVA_PACKAGE_SUFFIX) |
| 38 | LOCAL_BUILT_MODULE_STEM := uiautomator_sdk_v$(1)$(COMMON_JAVA_PACKAGE_SUFFIX) |
Dan Willemsen | e383f13 | 2016-09-30 18:41:21 -0700 | [diff] [blame] | 39 | LOCAL_MIN_SDK_VERSION := $(if $(call math_is_number,$(strip $(1))),$(1),$(PLATFORM_JACK_MIN_SDK_VERSION)) |
Yohann Roussel | 855a950 | 2016-08-19 18:58:57 +0200 | [diff] [blame] | 40 | LOCAL_UNINSTALLABLE_MODULE := true |
| 41 | include $(BUILD_PREBUILT) |
Colin Cross | 449c318 | 2016-10-21 10:35:17 -0700 | [diff] [blame^] | 42 | endif |
Ying Wang | b335bb0 | 2011-11-29 10:23:55 -0800 | [diff] [blame] | 43 | |
Yohann Roussel | 855a950 | 2016-08-19 18:58:57 +0200 | [diff] [blame] | 44 | endef |
| 45 | |
Colin Cross | 449c318 | 2016-10-21 10:35:17 -0700 | [diff] [blame^] | 46 | $(foreach s,$(filter-out test_current,$(TARGET_AVAILABLE_SDK_VERSIONS)),\ |
Yohann Roussel | 855a950 | 2016-08-19 18:58:57 +0200 | [diff] [blame] | 47 | $(eval $(call declare_sdk_prebuilts,$(s)))) |
Ying Wang | 2a38d24 | 2014-04-25 14:49:31 -0700 | [diff] [blame] | 48 | |
Ying Wang | b335bb0 | 2011-11-29 10:23:55 -0800 | [diff] [blame] | 49 | include $(call all-makefiles-under,$(LOCAL_PATH)) |