6 ms·
The Zig programming language has been ported to SerenityOS
- euclaise 4y agoNice! There's some work on porting it to Plan 9 too.
- Conscat 4y agoThat's being done by like one guy, too. It's pretty impressive imo despite being incomplete.
- nerdponx 4y agoA totally new kernel and a totally new systems operating language. Cool!
- sigzero 4y agoWow, excellent.
- akling 4y agoHello friends! For more details, here's a blog post that sin-ack wrote about the porting work: https://sin-ack.github.io/posts/sycl-talk-20221007/ https://sin-ack.github.io/posts/sycl-talk-20221007/ He also gave an in-person talk about Zig on SerenityOS at Software You Can Love 2022, there's a video of the talk here: https://www.youtube.com/watch?v=Ug3p8vELJqQ https://www.youtube.com/watch?v=Ug3p8vELJqQ
- mysterydip 4y agoFinally gave the build a go and really enjoyed playing around with it! Hope to contribute back someday. Kudos for all the progress.
- codetrotter 4y agoY’all just keep crushing it! :100: I remain hopeful that one day some company will acquire Serenity and ship SerenityOS to millions and millions of people. Idk if that is even aligned with what the people of SerenityOS wish for, but I think it would be very cool if that was to happen :D
- ducktective 4y ago>some company will acquire Serenity JS interpreter on Start Menu when?
- codetrotter 4y agoI wasn’t thinking of MSFT but sure if that’s what’s gonna happen then that’s what’s gonna happen :)
- rvz 4y ago> I remain hopeful that one day some company will acquire Serenity and ship SerenityOS to millions and millions of people. Who would want to acquire this exactly? This frankly sounds like the most devoid of all comments I have ever read and the furthest from reality. Any hobbyist OS fanatic would have said the exact same thing about GNU/Hurd, Haiku, HelenOS, ToaruOS, RedoxOS, etc. This is not 2005 anymore.
- LeFantome 4y agoIt is Open Source. Why does it have to be acquired?
- UltraViolence 4y agoBecause turning it into a workable product takes time, money and effort. As brilliant as SerenityOS is, it's still missing huge swaths of functionality people take for granted these days. Things like WiFi and GPU drivers and good audio/video decoders in the web browser, for example.
- AndyKelley 4y agoCan we have a stable syscall ABI yet for third party applications? :P
- akling 4y agoNo but you can call our POSIX C library whenever you want :^)
- AndyKelley 4y agoI had a chat with AK over on Mastodon and seems like dynamic linking libc should work just fine for cross compilation targeting SerenityOS!
- ADKaster 4y agoHello is this the AK thread? :)
- aaronpkelly 4y agoi'm in the right place so!
- celeritascelery 4y agoIs zig being considered for writing core modules?
- kristoff_it 4y agoI hope not, having a consistent ecosystem where all parts of the system share the same building blocks is one of the beautiful aspects of SerenityOS. For example in this video Andreas implements palette support for commands (commands are usually shown in the menu bar or contextual menus) and it has the nice side effect of immediately enabling them on every GUI program, even the desktop itself! https://www.youtube.com/watch?v=LAqGLkRCFb8 https://www.youtube.com/watch?v=LAqGLkRCFb8 I think Zig can be a polite guest in SerenityOS thanks to Zig's general interest in supporting uncommon targets, but the hosts are C++ and Jakt.
- cies 4y agoI really like Jakt: https://github.com/SerenityOS/jakt https://github.com/SerenityOS/jakt
- asddubs 4y agojudging by past answers given, no. this is just so you can develop on serenity using zig, but anything in-tree needs to be C++ (or Jakt once that's ready)
- pjmlp 4y agoJakt seems to at least be ready enough to write Nintendo emulators. :)
- asddubs 4y agoIt's more about integration into the rest of the system. E.g. the jakt and serenity string classes differed, so now the old string class has been deprecated and replaced by the jakt one. I'm not actively involved in the project though so I couldn't tell you much more than that
- shp0ngle 4y agoFrom the look of the PR, does this mean they ported LLVM to Serenity, so all languages that build to LLVM will work? Or am I way off the mark?
- tialaramex 4y agoSurely even for a language with a very light runtime, the startup routines need to understand Serenity and so that's actual porting work, and if your runtime has any heft to it, or you supply standard libraries that do anything (e.g. an allocator, file I/O, networking) that all needs porting to Serenity as well. So for example C freestanding or Rust "no-std" will "work" but you can't do very much, freestanding doesn't have this idea of you "running" a program since that implies the existence of some supervisory agent, the resulting machine code generally gets burned into a ROM, or whatever. The full blown hosted C, or Rust's std needs a bunch of porting, each is separate, the fact you made C's fopen() work doesn't magically make Rust's File APIs work so the fact Zig stuff works doesn't make Clang or rustc deliver their hosted/ std environments.
- TillE 4y agoThis is where it helps to have a firm grasp of what running on bare metal is, so you can better understand what an OS really does. You have some code that runs on a CPU, but beyond that how do you actually talk to anything else? There's an address bus so you can use memory without much trouble, but you have to know where the RAM is mapped. So yeah, there's a big step from compiling machine code to working correctly with a particular OS.
- resuresu 4y agoAll these “alternative” OSes are nothing more than toy’s because generally it seems the devs working on them have no desire whatsoever to make them run on bare metal. Just a toy that boots up in a VM completely dependent upon a host OS.
- simongr3dal 4y ago
- deleted 4y ago[deleted]
- jbirer 4y agoAwesome to see new technology being boldly adopted and tried, we need variety in this space. Kudos.
- keepquestioning 4y ago
- deleted 4y ago[deleted]
- trashburger 4y agoThanks for the shout-out, Andreas!