gpu-gles: schtruck/fpse merge: gl error checks
[pcsx_rearmed.git] / plugins / gpu_neon / Makefile
CommitLineData
1ab64c54 1CC = $(CROSS_COMPILE)gcc
56f08d83 2
3ARCH = $(shell $(CC) -v 2>&1 | grep -i 'target:' | awk '{print $$2}' | awk -F '-' '{print $$1}')
4
62d7fa95 5HAVE_NEON = $(shell $(CC) -E -dD $(CFLAGS_) ../gpulib/gpu.h | grep -q '__ARM_NEON__ 1' && echo 1)
1ab64c54 6
62d7fa95 7# FIXME: rework NEON detection to get rid of this
56f08d83 8ifeq "$(ARCH)" "arm"
62d7fa95 9 ARM_CORTEXA8 ?= 1
10 ifeq "$(ARM_CORTEXA8)" "1"
11 CFLAGS_ += -mcpu=cortex-a8 -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp
12 endif
56f08d83 13endif
1ab64c54 14
62d7fa95 15CFLAGS += -ggdb -Wall -fPIC -O2
7d993ee2 16
62d7fa95 17SRC += psx_gpu_if.c
b78edec7 18
62d7fa95 19CFLAGS += -DTEXTURE_CACHE_4BPP -DTEXTURE_CACHE_8BPP
7d993ee2 20ifeq "$(HAVE_NEON)" "1"
62d7fa95 21SRC += psx_gpu/psx_gpu_arm_neon.S
22CFLAGS += -DNEON_BUILD
b78edec7 23else
62d7fa95 24CFLAGS += -fno-strict-aliasing
b78edec7 25endif
6f2ee2be 26
62d7fa95 27BIN_GPULIB = gpu_neon.so
28include ../gpulib/gpulib.mak