It seems the world is tired of waiting for Zig to reach stability and has decided to start using it.
cat-whisperer 7 hours ago [-]
in my opinion, bun and ghostty were the only product that were keeping zig afloat. Now, it's ghostty and flipper zero zig template
pjmlp 7 hours ago [-]
Plenty of languages fit that scenario, how many actually take off is another matter.
bpavuk 1 days ago [-]
`@cImport` is dead, apparently, so the example should be updated.
bsder 17 hours ago [-]
"No no he's not dead, he's, he's restin'!"
@cImport is moving to the build system in an upcoming version (0.17, I think?). It's inconvenient, but it's unfortunately necessary.
The issue with @cImport is that when and the order the imports occur are almost impossible to define if you have multiple files and libraries. By moving it to the build system, the order now becomes deterministic and you can refer to it properly.
Zambyte 2 hours ago [-]
@cImport is dead. It's not moving anywhere, it's being deleted.
The build system allows you to expose C libraries as Zig modules that can be imported with the normal @import builtin.
Narew 1 days ago [-]
It's deprecated not removed yet.
bpavuk 1 days ago [-]
I'm a little too lazy to double-check, but either way 0.17.0 is around the corner, where it will totally get nixed
nyrikki 21 hours ago [-]
It is being moved not going away.
It is just a wrapper around zig translate-c, moving it to the build system moves the resulting clang dependency to a place where it can be optional.
The functionality is staying, it is just moving.
Conscat 19 hours ago [-]
The point here is that these examples need to be updated because @cImport, the syntactic feature of Zig, is being deprecated and removed. That there exists an alternative isn't relevant.
downvoted to oblivion. huh. ok, let me give you a hint:
> A modern, production-ready template for developing Flipper Zero applications using the Zig programming language. This project provides a streamlined build system that integrates Zig with the Flipper Zero SDK, enabling developers to write type-safe, memory-safe applications for the Flipper Zero platform.
replace "Flipper Zero" (the seventh and eighth words) in the first line with:
[Flipper Zero](https://flipper.net/)
Syzygies 8 hours ago [-]
Not everyone expects to appear on HN, but chasing links this is a par two golf course:
UFBT: Unofficial Flipper Build Tool (installation guide)
uFBT is a cross-platform tool for building applications for Flipper Zero.
cat-whisperer 4 hours ago [-]
I just updated the README :)
1 days ago [-]
Rendered at 17:47:20 GMT+0000 (Coordinated Universal Time) with Vercel.
@cImport is moving to the build system in an upcoming version (0.17, I think?). It's inconvenient, but it's unfortunately necessary.
The issue with @cImport is that when and the order the imports occur are almost impossible to define if you have multiple files and libraries. By moving it to the build system, the order now becomes deterministic and you can refer to it properly.
The build system allows you to expose C libraries as Zig modules that can be imported with the normal @import builtin.
It is just a wrapper around zig translate-c, moving it to the build system moves the resulting clang dependency to a place where it can be optional.
The functionality is staying, it is just moving.
It’s also decoupling Zig compiler and C compiler so they’re updated independently.
It’s still a bummer in my view as I just replaced my build pipelines with just a Zig compiler instead of emscripten but that’s fine.
This was an unnecessary prelude to an otherwise helpful comment.
https://flipper.net/products/flipper-zero
> A modern, production-ready template for developing Flipper Zero applications using the Zig programming language. This project provides a streamlined build system that integrates Zig with the Flipper Zero SDK, enabling developers to write type-safe, memory-safe applications for the Flipper Zero platform.
replace "Flipper Zero" (the seventh and eighth words) in the first line with: