diff --git a/buildroot-external/Config.in b/buildroot-external/Config.in index f62602b4..7274c5f2 100644 --- a/buildroot-external/Config.in +++ b/buildroot-external/Config.in @@ -89,6 +89,7 @@ endmenu source "$BR2_EXTERNAL_OPENVOICEOS_PATH/package/userland-tools/Config.in" source "$BR2_EXTERNAL_OPENVOICEOS_PATH/package/virtual-touch/Config.in" source "$BR2_EXTERNAL_OPENVOICEOS_PATH/package/wifi-connect/Config.in" + source "$BR2_EXTERNAL_OPENVOICEOS_PATH/package/xvf3510/Config.in" endmenu menu "Additional external python modules" source "$BR2_EXTERNAL_OPENVOICEOS_PATH/package/python-adapt-parser/Config.in" diff --git a/buildroot-external/configs/rpi4_64-gui_defconfig b/buildroot-external/configs/rpi4_64-gui_defconfig index 2136cc5a..e228a5a6 100644 --- a/buildroot-external/configs/rpi4_64-gui_defconfig +++ b/buildroot-external/configs/rpi4_64-gui_defconfig @@ -540,6 +540,7 @@ BR2_PACKAGE_SNAPCAST_SERVER=y BR2_PACKAGE_SPOTIFYD=y BR2_PACKAGE_USERLAND_TOOLS=y BR2_PACKAGE_WIFI_CONNECT=y +BR2_PACKAGE_XVF3510=y BR2_PACKAGE_PYTHON_ADAPT_PARSER=y BR2_PACKAGE_PYTHON_ASTRAL=y BR2_PACKAGE_PYTHON_COLOUR=y diff --git a/buildroot-external/package/xvf3510/0001-Patch-clk_dac_setup-Makefile-to-honour-cross-compili.patch b/buildroot-external/package/xvf3510/0001-Patch-clk_dac_setup-Makefile-to-honour-cross-compili.patch new file mode 100644 index 00000000..8e4e7846 --- /dev/null +++ b/buildroot-external/package/xvf3510/0001-Patch-clk_dac_setup-Makefile-to-honour-cross-compili.patch @@ -0,0 +1,31 @@ +From 9e8e51e22890b6b61672ef08976c91cd8ea73a86 Mon Sep 17 00:00:00 2001 +From: j1nx +Date: Wed, 14 Apr 2021 17:27:34 +0200 +Subject: [PATCH 1/1] Patch clk_dac_setup Makefile to honour cross compiling + +--- + resources/clk_dac_setup/Makefile | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +diff --git a/resources/clk_dac_setup/Makefile b/resources/clk_dac_setup/Makefile +index 24c7ec0..2f73c18 100644 +--- a/resources/clk_dac_setup/Makefile ++++ b/resources/clk_dac_setup/Makefile +@@ -1,10 +1,12 @@ ++CC = gcc ++ + default: bclk mclk + + bclk: setup_mclk_bclk.c +- gcc -g -o setup_bclk setup_mclk_bclk.c ++ $(CC) -g -o setup_bclk setup_mclk_bclk.c + + mclk: setup_mclk_bclk.c +- gcc -g -DMCLK -o setup_mclk setup_mclk_bclk.c ++ $(CC) -g -DMCLK -o setup_mclk setup_mclk_bclk.c + + clean: + rm -f setup_mclk +-- +2.20.1 + diff --git a/buildroot-external/package/xvf3510/Config.in b/buildroot-external/package/xvf3510/Config.in new file mode 100644 index 00000000..a4293e3f --- /dev/null +++ b/buildroot-external/package/xvf3510/Config.in @@ -0,0 +1,10 @@ +config BR2_PACKAGE_XVF3510 + bool "xvf3510" + help + xCORE VocalFusion Raspberry Pi + drivers and tools to support the + sj201 daughterboard used in the + Mark2. + + https://github.com/xmos/vocalfusion-rpi-setup/ + diff --git a/buildroot-external/package/xvf3510/xvf3510.hash b/buildroot-external/package/xvf3510/xvf3510.hash new file mode 100644 index 00000000..6c6e3449 --- /dev/null +++ b/buildroot-external/package/xvf3510/xvf3510.hash @@ -0,0 +1,2 @@ +# Locally computed +sha256 12b2b3c16e208791b1ead0562bae34d7345db8778e4702e5bd782aa0622cb404 xvf3510-4cfcc2c418ac0076277b11aa9e410816a62ce673.tar.gz diff --git a/buildroot-external/package/xvf3510/xvf3510.mk b/buildroot-external/package/xvf3510/xvf3510.mk new file mode 100644 index 00000000..8a069ffc --- /dev/null +++ b/buildroot-external/package/xvf3510/xvf3510.mk @@ -0,0 +1,33 @@ +################################################################################ +# +# xvf3510 +# +################################################################################ + +XVF3510_VERSION = 4cfcc2c418ac0076277b11aa9e410816a62ce673 +XVF3510_SITE = $(call github,xmos,vocalfusion-rpi-setup,$(XVF3510_VERSION)) +XVF3510_MODULE_SUBDIRS = loader/i2s_master +XVF3510_MODULE_MAKE_OPTS = CFLAGS_MODULE="-DRPI_4B -DI2S_MASTER" \ + KVER=$(LINUX_VERSION_PROBED) \ + KSRC=$(LINUX_DIR) + +XVF3510_POST_EXTRACT_HOOKS = XVF3510_MOVE_SRC_FILE + +define XVF3510_MOVE_SRC_FILE + cp $(@D)/loader/src/loader.c $(@D)/loader/i2s_master/i2s_master_loader.c +endef + +$(eval $(kernel-module)) + +define XVF3510_BUILD_CMDS + $(MAKE) CC="$(TARGET_CC)" LD="$(TARGET_LD)" -C $(@D)/resources/clk_dac_setup default +endef + +define XVF3510_INSTALL_TARGET_CMDS + $(INSTALL) -D -m 0755 $(@D)/resources/clk_dac_setup/setup_bclk \ + $(TARGET_DIR)/usr/bin + $(INSTALL) -D -m 0755 $(@D)/resources/clk_dac_setup/setup_mclk \ + $(TARGET_DIR)/usr/bin +endef + +$(eval $(generic-package))