1667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# Copyright (C) 2013 The Android Open Source Project 2667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# 3667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# Licensed under the Apache License, Version 2.0 (the "License"); 4667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# you may not use this file except in compliance with the License. 5667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# You may obtain a copy of the License at 6667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# 7667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# http://www.apache.org/licenses/LICENSE-2.0 8667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# 9667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# Unless required by applicable law or agreed to in writing, software 10667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# distributed under the License is distributed on an "AS IS" BASIS, 11667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# See the License for the specific language governing permissions and 13667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu# limitations under the License. 14667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu 15667f9a8a8155c41970a83be1414b57b5e37de336Maurice ChuLOCAL_PATH := $(call my-dir) 16667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chu 17667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chuinclude $(CLEAR_VARS) 18667f9a8a8155c41970a83be1414b57b5e37de336Maurice ChuLOCAL_MODULE := android-support-multidex 197dfb545d0f92125162ba2bacdfa1b96e88d06886Yohann RousselLOCAL_SDK_VERSION := 4 20667f9a8a8155c41970a83be1414b57b5e37de336Maurice ChuLOCAL_SRC_FILES := $(call all-java-files-under, src) 21abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel 22abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Rousselifneq "" "$(filter eng.%,$(BUILD_NUMBER))" 23abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel ASMD_VERSION_NAME_TAG := eng.$(USER) 24abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Rousselelse 25abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel ASMD_VERSION_NAME_TAG := $(BUILD_NUMBER) 26abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Rousselendif 27abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel 28abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann RousselASMD_GIT_VERSION_TAG := `cd $(LOCAL_PATH); git log --format="%H" -n 1` 29abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel 30abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann RousselASMD_VERSION_INTERMEDIATE = $(call intermediates-dir-for,JAVA_LIBRARIES,$(LOCAL_MODULE),,COMMON)/$(LOCAL_MODULE).version.txt 31abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel$(ASMD_VERSION_INTERMEDIATE): 32abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel $(hide) mkdir -p $(dir $@) 33abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel $(hide) echo "build.version=$(ASMD_VERSION_NAME_TAG)" > $@ 34abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel $(hide) echo "build.id=$(BUILD_ID)" >> $@ 35abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel $(hide) echo "git.version=$(ASMD_GIT_VERSION_TAG)" >> $@ 36abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel 37abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann RousselLOCAL_JAVA_RESOURCE_FILES := $(ASMD_VERSION_INTERMEDIATE) 38abaf93c8f92de8b8d44173e78b0d7629b0324031Yohann Roussel 396624fbd355c4b3c874bec920aab662b2056a7278Yohann Roussel# Use a dir because we have files in subfolders and we want to keep the path into the archive 406624fbd355c4b3c874bec920aab662b2056a7278Yohann Roussel# 416624fbd355c4b3c874bec920aab662b2056a7278Yohann Roussel# use "resources" instead of "res" because res is already used for packaging the SDK project 426624fbd355c4b3c874bec920aab662b2056a7278Yohann RousselLOCAL_JAVA_RESOURCE_DIRS := resources 436624fbd355c4b3c874bec920aab662b2056a7278Yohann Roussel 44667f9a8a8155c41970a83be1414b57b5e37de336Maurice Chuinclude $(BUILD_STATIC_JAVA_LIBRARY) 45