1# Copyright (C) 2013 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#
15LOCAL_PATH := $(call my-dir)
16
17include $(CLEAR_VARS)
18
19SYSTEM_PREBUILT_PACKAGE ?= true
20
21LOCAL_MODULE    := libjni_abcc
22LOCAL_MODULE_CLASS := SHARED_LIBRARIES
23LOCAL_C_INCLUDES := $(LOCAL_PATH)/device
24LOCAL_CFLAGS += -DON_DEVICE=1
25LOCAL_SRC_FILES := \
26  Abcc.cpp \
27  device/Abcc_device.cpp \
28  device/main.cpp
29
30# Check in AOSP or NDK usage
31ifeq ($(SYSTEM_PREBUILT_PACKAGE),true)
32
33LOCAL_SHARED_LIBRARIES := liblog libstlport
34include external/stlport/libstlport.mk
35
36include $(BUILD_SHARED_LIBRARY)
37else  # SYSTEM_PREBUILT_PACKAGE
38
39#FIXME: parallel llvm codegen is not yet ported to llvm-3.5
40#LOCAL_CFLAGS += -DENABLE_PARALLEL_LLVM_CG=1
41LOCAL_CFLAGS += -DVERBOSE=0
42LOCAL_LDLIBS := -llog
43LOCAL_STATIC_LIBRARIES := cpufeatures
44include $(BUILD_SHARED_LIBRARY)
45
46$(call import-module,android/cpufeatures)
47
48endif
49
50