Skip to content

compile with SDCC 4.2.0#82

Open
macpijan wants to merge 1 commit intomasterfrom
update-toolchain
Open

compile with SDCC 4.2.0#82
macpijan wants to merge 1 commit intomasterfrom
update-toolchain

Conversation

@macpijan
Copy link

@macpijan macpijan commented Feb 27, 2026

4.5.0 used to fail with:

src/board/system76/common/smfi.c:209: error 110: conditional flow changed by optimizer: so said EVELYN the modified DOG
make: *** [src/arch/8051/toolchain.mk:54: build/novacustom/v540tu/2026-02-27_41e94a7/board/system76/common/smfi.rel] Error 1
Failed to build EC firmware : (2)

Tried to build in: Dasharo/ec-sdk#2

Switching to 4.2.0 results in successfull build.

SDCC 4.2+ enforces C23-style strict prototypes and rejects empty
parameter lists as error 283 ("function declarator with no prototype").
Replace () with (void) in all function declarations and definitions.

Fixes build with sdcc >= 4.2.0.

Signed-off-by: Maciej Pijanowski <maciej.pijanowski@3mdeb.com>
@macpijan macpijan changed the title WIP: compile with SDCC 4.5.0 compile with SDCC 4.2.0 Feb 27, 2026
@macpijan macpijan requested a review from mkopec February 27, 2026 15:15
@macpijan
Copy link
Author

macpijan commented Feb 27, 2026

We use :main tag here, possibly it alters older builds: https://github.com/Dasharo/ec/blob/master/build.sh#L74 when merged and uploaded under :main tag ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants