blob: 207a1774757a2cb144d44e52716800ca66745964 [file] [log] [blame]
Tvrtko Ursulin5d764962014-04-23 17:03:23 +01001LOCAL_PATH := $(call my-dir)
2
3include $(LOCAL_PATH)/Makefile.sources
4
5#================#
6
7define add_benchmark
8 include $(CLEAR_VARS)
9
10 LOCAL_SRC_FILES := $1.c
11
12 LOCAL_CFLAGS += -DHAVE_STRUCT_SYSINFO_TOTALRAM
13 LOCAL_CFLAGS += -DANDROID -UNDEBUG -include "check-ndebug.h"
Tim Gorea11117e2014-12-12 12:14:33 +000014 LOCAL_CFLAGS += -std=gnu99
Tvrtko Ursulin5d764962014-04-23 17:03:23 +010015 # FIXME: drop once Bionic correctly annotates "noreturn" on pthread_exit
16 LOCAL_CFLAGS += -Wno-error=return-type
17 # Excessive complaining for established cases. Rely on the Linux version warnings.
18 LOCAL_CFLAGS += -Wno-sign-compare
19
Derek Morton1ae1d292015-07-27 11:30:58 +010020 LOCAL_MODULE := $1_benchmark
Tvrtko Ursulin5d764962014-04-23 17:03:23 +010021 LOCAL_MODULE_TAGS := optional
Derek Mortond524a962015-08-13 11:27:35 +010022 LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/intel/validation/core/igt/benchmarks
Tvrtko Ursulin5d764962014-04-23 17:03:23 +010023
24 LOCAL_STATIC_LIBRARIES := libintel_gpu_tools
25
26 LOCAL_SHARED_LIBRARIES := libpciaccess \
27 libdrm \
28 libdrm_intel
29
30 include $(BUILD_EXECUTABLE)
31endef
32
33#================#
34
Derek Mortond524a962015-08-13 11:27:35 +010035benchmark_list := $(benchmarks_PROGRAMS)
Tvrtko Ursulin5d764962014-04-23 17:03:23 +010036
37$(foreach item,$(benchmark_list),$(eval $(call add_benchmark,$(item))))