From 7dc54160d1ada865f2a168e048fa3db8a24b4ceb Mon Sep 17 00:00:00 2001 From: Leah Rowe Date: Wed, 23 Sep 2026 15:40:18 +0100 Subject: fix pico-serprog build error on gcc 16 baud is already global. no need to pass it here. gcc 16 is much stricter, so this resulted in a warning that lead to a build error. this patch fixes it. Signed-off-by: Leah Rowe --- .../0001-fix-build-error-enable_spi-baud.patch | 39 ++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 config/module/pico-serprog/default/patches/0001-fix-build-error-enable_spi-baud.patch (limited to 'config/module') diff --git a/config/module/pico-serprog/default/patches/0001-fix-build-error-enable_spi-baud.patch b/config/module/pico-serprog/default/patches/0001-fix-build-error-enable_spi-baud.patch new file mode 100644 index 00000000..55445a1a --- /dev/null +++ b/config/module/pico-serprog/default/patches/0001-fix-build-error-enable_spi-baud.patch @@ -0,0 +1,39 @@ +From c5af7ae4716ddb729573df950eee0a4b8ce2d23e Mon Sep 17 00:00:00 2001 +From: Leah Rowe +Date: Wed, 23 Sep 2026 15:38:45 +0100 +Subject: [PATCH 1/1] fix build error: enable_spi(baud) + +baud is a global variable in this code. we don't +need to pass it here. i think riku added this by +mistake. + +it would have resulted in a warning before, on +older compilers, but would have still compiled. + +on gcc 16, it fails with a build error. no worries. +semantically different with this change, but behaviour +remains the same. + +this fixes the build on gcc16, tested in arch linux. + +Signed-off-by: Leah Rowe +--- + main.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/main.c b/main.c +index b06f92f..36a9265 100644 +--- a/main.c ++++ b/main.c +@@ -322,7 +322,7 @@ int main() { + /* Setup USB */ + tusb_init(); + /* Setup PL022 SPI */ +- enable_spi(baud); ++ enable_spi(); + + command_loop(); + } +-- +2.47.3 + -- cgit v1.2.1