blob: 5a6aae247967d0eb359020c3dcac3f6d87f6c8a2 [file] [log] [blame]
Greg Hartman8527e472015-11-02 13:08:12 -08001#
2# Copyright 2015 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
Nicolas Capens352e56c2017-08-10 16:57:25 -040017LOCAL_PATH := $(call my-dir)
Merck Hung90c0c552018-09-28 16:08:14 +080018swiftshader_root := $(LOCAL_PATH)
Greg Hartman8527e472015-11-02 13:08:12 -080019
Nicolas Capensfde88d92018-10-15 12:55:02 -040020# Subzero is an alternative JIT compiler. It is smaller and generally slower.
21REACTOR_USE_SUBZERO := false
Logan Chien17b75892018-08-27 10:49:24 +080022
Ben Claytond632e6d2019-04-12 16:51:47 -040023# SwiftShader requires C++11.
Nicolas Capensfde88d92018-10-15 12:55:02 -040024# Full C++11 support is only available from Marshmallow and up.
Nicolas Capens352e56c2017-08-10 16:57:25 -040025ifeq ($(shell test $(PLATFORM_SDK_VERSION) -lt 23 && echo PreMarshmallow),PreMarshmallow)
Ben Claytond632e6d2019-04-12 16:51:47 -040026swiftshader_unsupported_build := true
Nicolas Capens352e56c2017-08-10 16:57:25 -040027endif
Logan Chien17b75892018-08-27 10:49:24 +080028
29# Check whether $(TARGET_ARCH) is supported.
Logan Chien17b75892018-08-27 10:49:24 +080030ifneq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),x86 x86_64 arm arm64))
Logan Chien6aad6a72018-09-25 17:59:20 +080031swiftshader_unsupported_build := true
Logan Chien17b75892018-08-27 10:49:24 +080032endif
Logan Chien17b75892018-08-27 10:49:24 +080033
Merck Hung90c0c552018-09-28 16:08:14 +080034ifneq ($(swiftshader_unsupported_build),true)
35include $(swiftshader_root)/src/Android.mk
Alexis Hetud16a5042018-10-17 10:10:23 -040036include $(swiftshader_root)/tests/GLESUnitTests/Android.mk
Merck Hung90c0c552018-09-28 16:08:14 +080037include $(swiftshader_root)/third_party/llvm-7.0/Android.mk
38endif