From 2ec90792d7ef6a0acf32cca3dca7089ab317b01e Mon Sep 17 00:00:00 2001 From: marktwtn Date: Tue, 23 Jul 2019 15:17:07 +0800 Subject: [PATCH] build: Add de10-nano board specific compiler flags -mcpu=cortex-a9: The CPU of de10-nano board is Cortex-A9. -mfloat-abi=softfp: The NEON intrinsics are not available with the soft option. Use softfp instead of soft. -mfpu=neon: neon equals to neon-vfpv3. --- Makefile | 3 +++ mk/board.mk | 3 +++ 2 files changed, 6 insertions(+) create mode 100644 mk/board.mk diff --git a/Makefile b/Makefile index 0a42915..011b7c7 100644 --- a/Makefile +++ b/Makefile @@ -35,6 +35,9 @@ include mk/cpu-features.mk # Handle git submodule include mk/submodule.mk +# Board specific compiler flags +include mk/board.mk + # Assign the hardware to CPU if no hardware is specified PLATFORMS := $(BUILD_AVX) $(BUILD_SSE) $(BUILD_GENERIC) $(BUILD_GPU) $(BUILD_FPGA_ACCEL) ENABLE_PLATFORMS := $(findstring 1,$(PLATFORMS)) diff --git a/mk/board.mk b/mk/board.mk new file mode 100644 index 0000000..8c4e944 --- /dev/null +++ b/mk/board.mk @@ -0,0 +1,3 @@ +ifeq ($(BOARD),de10nano) + CFLAGS += -mcpu=cortex-a9 -mfloat-abi=softfp -mfpu=neon +endif