1 # 2 # Copyright (C) 2011 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 18 #===================================================================== 19 # Architecture Selection 20 #===================================================================== 21 22 ifeq ($(LOCAL_IS_HOST_MODULE),) # Target Build 23 24 # Note: We should only use -DFORCE_ARCH_CODEGEN on target build. 25 # For the host build, we will include as many architecture as possible, 26 # so that we can test the execution engine easily. 27 28 ifeq ($(TARGET_ARCH),arm) 29 LOCAL_CFLAGS += -DFORCE_ARM_CODEGEN 30 ifeq ($(ARCH_ARM_HAVE_VFP),true) 31 LOCAL_CFLAGS += -DARCH_ARM_HAVE_VFP 32 ifeq ($(ARCH_ARM_HAVE_VFP_D32),true) 33 LOCAL_CFLAGS += -DARCH_ARM_HAVE_VFP_D32 34 endif 35 endif 36 ifeq ($(ARCH_ARM_HAVE_NEON),true) 37 LOCAL_CFLAGS += -DARCH_ARM_HAVE_NEON 38 endif 39 else 40 ifeq ($(TARGET_ARCH),mips) 41 LOCAL_CFLAGS += -DFORCE_MIPS_CODEGEN 42 else 43 ifeq ($(TARGET_ARCH),x86) 44 LOCAL_CFLAGS += -DFORCE_X86_CODEGEN 45 else 46 $(error Unsupported architecture $(TARGET_ARCH)) 47 endif 48 endif 49 endif 50 51 endif 52