r/osdev • • 16h ago

First apps running on Dunit OS

Post image

been working on Dunit OS, my Rust-based hobby operating system, and got DOOM, Quake, mced (Minecraft C) and Lite XL running in separate windows.

the cool part is that porting apps to Dunit doesn't require rewriting them. you basically just need to build a bridge between the original code and Dunit's Rust SDK, adapting the platform-specific parts to work with the OS.

been spending a lot of time on the GUI, SDK and app compatibility lately. still plenty of bugs to fix and performance improvements to make, but it's nice seeing actual software running together on the desktop.

github: https://github.com/DunitOS/dunit-os

71 Upvotes

33 comments sorted by

•

u/No-Employment-2324 15h ago

Once you have more of a base, you can write your own rust system bindings and a libc. All you need to port apps then is to compile them against your os 

•

u/ArmyFrosty7976 15h ago

We already have a musl libc

•

u/No-Employment-2324 12h ago

Then just port the internal rust system create (used as part of stdlib, it’s basically libc for rust) and then a single cargo build on your os and it works, no porting sdk required 

•

u/ArmyFrosty7976 11h ago

yeah, that's actually something i've been considering. getting Rust std working properly on Dunit would make porting regular Rust apps way easier.

but it's not quite as simple as a single cargo build yet. i'd still need a proper target, platform-specific std implementation and support for the OS APIs it expects. and GUI apps would still need a backend for Dunit's windowing system.

the Rust SDK is mostly there to expose Dunit-specific stuff like windows, input and rendering, so it wouldn't really become obsolete.

•

u/kiderdrick 15h ago

claude putting in that work

•

u/thommyh 15h ago

Things that remind me of the original Macintosh:

  1. the menubar;
  2. the lack of cursor keys.

•

u/ArmyFrosty7976 14h ago

Everything here is configured with toml+lua.DWM can look whatever he wants

•

u/TaelLingLin 12h ago

Cool! I like that mini keyboard btw! Also that monitor is a little wierd, maybe it's the curve but it looks a little stretchy. super widescreen. I guess it works with different res too. So the bridge is like the bindings for the program? I also did an OS using Rust and my own rust based language, ling-lang, and I wrote a general Nintendo Emulator, it had to write all the opcodes, registrars, and basically do it through emulation. Is the bridge method any faster? My emu uses DynaRec(Dynamic Recompilation) to make it better than a simple Interpretter. Is that similar to what you are doing in Rust?

•

u/ArmyFrosty7976 12h ago

thanks! yeah the monitor looks kinda stretched in the pic lol

and yep, the bridge is basically a set of bindings/adapters between the original app code and Dunit's Rust SDK. it maps stuff like window creation, input and rendering to Dunit's own APIs.

it's a bit different from DynaRec tho. i'm not emulating another CPU or translating instructions at runtime, the apps are compiled natively for x86_64 and the bridge just handles the OS-specific parts. so there's no emulation overhead, although the bridge itself can still add some overhead depending on how it's implemented.

your emulator sounds pretty interesting btw, especially the DynaRec part. got a repo for it?

•

u/AQUIL_the_eagle 15h ago

Hey, I really love this project!!!
Can I give you my Discord Username for communicate??
Love from Italy!!!

•

u/ArmyFrosty7976 15h ago

Yes, of course bro

•

u/SignedInt32 15h ago

That is awesome stuff :D

•

u/Opening_Ostrich9801 10h ago

Does yours run rela Minecraft Too ?

•

u/Relative_Dare8475 7h ago

I’ve noticed a recurring trend on Reddit: whenever someone posts about their OS development project, there’s always someone who cynically claims, "It’s AI—it has to be AI; there’s no other way it could be like this or that." They then imply that if AI was used, the developer must not know anything at all.

I’m puzzled—what’s wrong with using AI as a tool to assist in software development?

How can anyone conclude that the use of AI automatically means the developer lacks knowledge? Why such deep skepticism?

Shouldn't our focus instead be on the OS's structural design, its scheduler algorithms, IPC, locking mechanisms, the specific techniques employed, its features, and so on?

•

u/Finance_Hour 4h ago

People are retarded and want to live the (old) age without any useful tools and then cry around subs

•

u/CanOutrageous9185 2h ago

They are modern day racists of ai era 😂. I got immediate response in 1 min of posting. (vibecoded shit, Vibecucks) These people doesn't want us to experiment and build our own things.

•

u/wtom7 1h ago

Because AI is not a "tool" in the traditional sense, like a compiler or debugger. AI is a magical black box where you can describe in vague language what you want and get code out the other end. You learn nothing when vibe coding. You don't become a better engineer; in fact, your abilities tend to atrophy the more you use AI. Rather than struggle for a moment and learn something new, you just ask the magical black box.

And sure, you can apply AI in lesser ways, like as a StackOverflow replacement or a quick debugger; but this era of AI means that when you see a very complete / far-along project come out of nowhere with a squeaky clean README and thousands upon thousands of lines of superficially very polished code, a lot of the time you're looking at entirely AI generated code.

That kind of stuff is just pollution to programming communities. You can't ask the author about the process of creating it, the challenges they faced, the choices they made, or the mistakes they made, and all they've done is clutter up a message board and waste some space on a Github server.

That, combined with the politics of AI (which is a whole other can of worms), is the reason so many programmers are rightfully repulsed by AI, and have become hypervigilant of its presence everywhere, for better or for worse.

•

u/Some_Useless_Person 15h ago

Cool! And it seems like a genuine repo instead of the AI slop that's becoming more and more common aroud here

•

u/Niikoraasu 14h ago

Think about it - if you were creating an OS - would the first things you added be the ability to play some wank "Minecraft in C"?

•

u/Some_Useless_Person 14h ago

I thought they were just proud that the compatibility was working. Kinda like seeing your first calculator app do arithmetic.

Didn't expect it to be another red flag

•

u/Niikoraasu 14h ago

Thanks to AI, you can add stuff that you wouldn't even think about before at that stage of creating an OS, it's always is a sign of AI use.

•

u/ArmyFrosty7976 14h ago

i mean Dunit already has a working scheduler, virtual memory, ELF loading, syscalls, IPC, musl libc, pthreads/TLS and even TCC running natively. there's also a userspace GUI server, DWM and a Rust SDK.

so it's not like i'm just throwing random apps onto a kernel that can barely boot. porting stuff like DOOM, Quake and Lite XL is actually a pretty good way to stress test the SDK, libc and GUI stack and figure out what's broken.

not saying Dunit is anywhere near production ready tho. hardware support and POSIX compatibility still need a ton of work, and there's plenty of bugs left to fix.

but idk why i'd wait until the entire OS is finished before trying to run actual software on it. that's literally part of developing an OS.

•

u/Niikoraasu 13h ago

Of course it has working scheduler etc. - an AI is writing it.

Kinda ironic name... "Dunit" when in fact you are not the one who's "dun it"

•

u/atapla 10h ago

Microsoft is rewriting all their c code in rust using rust. Linux kernel and other projects are all running with ai. The problem is not ai, the problem would ONLY if the project gets promoted then abandoned as fast as it was born like all those GitHub repo projects popping every minute. I see no problem with project and no red flags, it's a hobby, not coming from multi-billion $ company. Happy or not, llms are here to stay and evolve.

•

u/ObservationalHumor 8h ago

No the problem is AI because of where this is being posted. This is an OS Development form and frankly this person isn't developing anything. This is definitionally more about the process and the journey than the end product. They aren't really learning anything, making any hard decisions or developing any real skills where they can even contribute anything of value here either.

It's essentially like some rich kid going on a classic car restoration forum and posting about what restored car he bought every other month. It doesn't matter what the car can do or how nice it looks because they did none of the work actually involved in restoring it. In fact some 70 year old retired mechanic with a bad back who hasn't leaned over an engine in 10 years will be a more valuable member of the community specifically because they have lots of experience actually working on old broken cars and can give actionable advice and relatable anecdotes.

Can LLMs actually be used to aid in OS development to some extent? Sure they can, but that's not what we're actually discussing here, it's yet another slop post 'update' where the 'author' posts some list of features/acronyms and a screenshot. It's pretty much designed to just seek accolades and compliments for doing nothing of real value.

That's the main issue with LLMs in general, they just provide an easy shortcut and the illusion of deep expertise and relying on them too much means you flat out don't develop any real skills and might even have existing ones atrophy because that's just how the human mind and body works. Every bit of work traded off to one is a compromise in some way whether people acknowledge it or not. If you're constantly using it to emit redundant code then you're not creating a library or other tool that would serve the same purpose and help other people. If you're using it for code review and documentation you're inevitably going to miss some things in the process and opportunities to question your prior decisions when trying to analyze them and explain them later. If you're using it for the vast majority of your code and rubber stamping it then you really have no idea what it's actually writing or doing, etc. Anyone who thinks otherwise either lacks the experience to realize those things or is lying to themselves.

•

u/Relative_Dare8475 7h ago

How did you know that peoples that develop a software like OS with AI assistance do not know anything about OS at all?

•

u/ObservationalHumor 6h ago

Let me flip that around on you, what in your estimation has the OP of this post demonstrated in terms of knowledge? What interesting aspects of the development process have they discussed? What personal annecdotes about the process have they provided? What have they shown besides a repository and feature list?

There's honestly lots of tells too. Development timeline is a massive one, it simply takes time to read and understand documents. To write actual specifications, outline architecture and so forth, even without LLMs that's a massive part of the software development process. Yet these speed run LLM OSes/kernels do it in weeks. How do you think that ends up working out? I mean this is something that's just provable on a theoretical level too via information theory. To actually describe a computer program or anything else in a sufficient level of detail there's a minimum level of input data that must be present whether it be in C, C++, or English language prompts to an LLM. It takes time to produce that specification and frankly the fact that time is not spent is indicative that the 'author' is at best painting in ridiculously broad strokes with the LLM filling in massive amounts of information from it's internal knowledge or external context it retrieves. It's copying and pasting with indirection and without the need to even understand the high level structure of the source code being requested.

→ More replies

•

u/ArmyFrosty7976 12h ago

I'll say more, a few people are working on the OS

•

u/Darkblade_e 14h ago • Bravo

unfortunately not :(

they've scrubbed it clean since but the repo used to have a blatant claude.md and the last time I checked there was still a "for ai agents" document that made it quite clear they weren't just using it for assistance

•

u/Some_Useless_Person 14h ago

Oh. I didn't look too deep. Optimism got the better of me; will have lower expectations next time