blob: 7bcf631da6522fd3d3e223bbc6e59890258b3c85 [file] [log] [blame]
The Android Open Source Project9066cfe2009-03-03 19:31:44 -08001#
Adam Lesinskifab50872014-04-16 14:40:42 -07002# Copyright (C) 2014 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.
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080015#
16
Ying Wang74bebf62014-03-07 15:55:14 -080017ifeq ($(TARGET_BUILD_APPS)$(filter true,$(TARGET_BUILD_PDK)),)
Joe Onorato74905e52010-06-10 18:34:55 -070018
Adam Lesinskifab50872014-04-16 14:40:42 -070019# ==========================================================
20# Setup some common variables for the different build
21# targets here.
22# ==========================================================
23LOCAL_PATH:= $(call my-dir)
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080024
Adam Lesinskifab50872014-04-16 14:40:42 -070025aaptHostStaticLibs := \
26 libandroidfw \
27 libpng \
Adam Lesinskifab50872014-04-16 14:40:42 -070028 libutils \
Sergio Girod90d8d62016-06-28 18:26:10 +010029 liblog \
Adam Lesinskifab50872014-04-16 14:40:42 -070030 libcutils \
31 libexpat \
Colin Cross9a1a3bc2016-08-26 11:15:17 -070032 libziparchive \
Dan Willemsen85aee732017-09-08 21:26:31 -070033 libbase \
34 libz
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080035
Dan Willemsen896f0182017-09-08 22:02:41 -070036aaptCFlags := -Wall -Werror
Adam Lesinskiad751222014-08-18 14:06:38 -070037
Adam Lesinskifab50872014-04-16 14:40:42 -070038# ==========================================================
Adam Lesinskifab50872014-04-16 14:40:42 -070039# Build the host executable: aapt
40# ==========================================================
41include $(CLEAR_VARS)
42
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080043LOCAL_MODULE := aapt
Dan Willemsen4aa679f2015-08-19 11:13:56 -070044LOCAL_MODULE_HOST_OS := darwin linux windows
Dan Willemsen896f0182017-09-08 22:02:41 -070045LOCAL_CFLAGS := -DAAPT_VERSION=\"$(BUILD_NUMBER_FROM_FILE)\" $(aaptCFlags)
Dan Willemsend3eac262017-09-08 22:47:47 -070046LOCAL_SRC_FILES := Main.cpp
Dan Willemsen4aa679f2015-08-19 11:13:56 -070047LOCAL_STATIC_LIBRARIES := libaapt $(aaptHostStaticLibs)
Adam Lesinskifab50872014-04-16 14:40:42 -070048
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080049include $(BUILD_HOST_EXECUTABLE)
50
Ying Wang74bebf62014-03-07 15:55:14 -080051endif # No TARGET_BUILD_APPS or TARGET_BUILD_PDK