Closed frmdstryr closed 11 months ago
Appears to be due to https://github.com/ziglang/zig/commit/57562c8d507667b6fefcb7fbc7a305fbd610b5dd
Guess you have to now use this:
elf.entry = .{.symbol_name="resetHandler"};
If you are using a linker script that sets the entry point that seems like something that should still work. cc @kubkon
cc @andrewrk seems related to your latest yak shave. FWIW I can have a look as well when porting latest MachO over.
elf.entry = .{.symbol_name="resetHandler"};
This looks perfect to me.
I think we should transition to declarative linking as much as possible. I don't see any reason why a linker script should be used to specify the entry point when a declarative symbol name perfectly solves the problem.
It looks to me like this use case is handled just fine.
Related: #3206
elf.entry = .{.symbol_name="resetHandler"};
This looks perfect to me.
I think we should transition to declarative linking as much as possible. I don't see any reason why a linker script should be used to specify the entry point when a declarative symbol name perfectly solves the problem.
It looks to me like this use case is handled just fine.
Related: #3206
FWIW I will take declarative style and in Zig over GNU linker scripts any day.
Zig Version
0.12.0-dev.2059+42389cb9c
Steps to Reproduce and Observed Behavior
I recently updated from 0.12.0-dev.1721 ish to the version above... Now when trying to build with the I get:
And the firmware just immediately hard faults.
If I rename the actual entry point function (eg
resetHandler
) from the linker script to_start
it works but I'm not sure why it requires this now.Expected Behavior
It should either:
Entry(resetHandler)
)