Hello, On 2025/01/07 20:37, nick black wrote:
nick black left as an exercise for the reader:this wasm file is, again, distributed with the zig-bootstrap and zig sources. it is a binary and knocks us out of main. this file can be recreated, using sources from within the zig repository, with a working zig. but even the "zig-bootstrap" source cannot move forward without either this file or a working zig with which to create it ("zig-bootstrap" is more about vendoring LLVM).i looked at a few other distros: - arch just builds it and is done with it - guix, from what i can tell, is picking up a previous zig build of their own and using that to bootstrap. i am 0% certain of this interpretation [0]. - fedora looks promising; they certainly remove zig1.wasm before building; i will examine this further.
From what I understand talking to upstream, we don't actually need zig-boostrap at all. You can get a zig compiler up and running from only even the zig upstream source.
The problem is that that repo contains a rather large amount of embedded files. The people who initially tried to package this for Debian struggled quite a bit, as you can see in the ITP:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=995670Fortunately, those embedded files aren't needed for the core compiler (called the stage2 compiler, which eventually builds the full zig tool/compiler). This stage2 compiler *should* be enough to compile other upstream projects written in zig too, so my intention is to upload this to main as zig-minimal, which *should* be enough at least in terms of building zig stuff that we want in the archive (upstream themselves sound a little unsure about this... and said that we should test a few upstream projects with it).
I broke my local build last when I worked on it, going to poke a bit at it now, but my work so far is at:
https://salsa.debian.org/debian/zig I strip out all the vendored stuff in debian/copyright: https://salsa.debian.org/debian/zig/-/blob/main/debian/copyright?ref_type=heads#L5That makes it really easy to upload a dfsg-free version that is somewhat useful.
Also, apologies for any typos / nonsensical grammar here, been a long day :) -Jonathan PS: also, bad bad bad nick for planting a will smith song in my head!