OSDev.org

The Place to Start for Operating System Developers
It is currently Fri Mar 29, 2024 8:48 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 3898 posts ]  Go to page Previous  1 ... 241, 242, 243, 244, 245, 246, 247 ... 260  Next
Author Message
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Wed Feb 03, 2021 1:14 pm 
Offline
Member
Member
User avatar

Joined: Mon Jun 05, 2006 11:00 pm
Posts: 2293
Location: USA (and Australia)
PeterX wrote:
Only thing: How do you know which object file should end where? I mean: If you have several cpp/c/asm files and want to link the resulting object files to a complete program, you have to tell it explicitely, or not?

My build system has two targets: "perception" (my OS) and "local" (the host OS, where it calls the system's C++ compiler) - a secondary goal is to one day be able to build hobby C++ programs and be able to compile it both for my OS and locally! There are three configurations: "optimized" (which does whole program optimization), the default (fast build), and "debug" (symbols and stack traces.)

By build system creates a temp directory called "build/" which has some interesting things in it:
  • <target-configuration>/ - A mirror of the "source/" tree where the object files go. e.g. "source/abc/def.cc" turns into "build/perception-optimized/abc/def.cc.o".
  • <target-configuration>/dependencies.json - A map of source file => dependent files (headers). GCC can output all the header files that a source file depends on. I read it, store it in here, and use it to determine if to rebuild a source file if any of the dependent timestamps are newer than the object file.
  • <target-configuration>.lib - (For libraries) The object files linked together into a single object.
  • <target-configuration>/.app/.exe - (For programs) The final executable.

You have the problem of everything being called "perception-debug.app" or "local-optimized.exe" , but I have a final step in my build system that copies it into the "fs/" tree and renames it to the program's name, then turns it into a bootable ISO image. There's no reason you couldn't do something similar if you wanted to package a program for distribution.

Usage is:
Code:
# Builds application "Hello World" for the local host with all optimizations and runs it locally.
./build run --opt --local Hello World
# Fast builds everything for Perception, turns it into an OS image.
./build all
# Builds everything with optimizations, turns it into an OS image, and starts QEMU.
./build run --opt
# Builds the "musl" library
./build library musl
# Builds the application "Hello World"
./build application Hello World

One day I hope to add a `./build test` for unit testing a package.

_________________
My OS is Perception.


Last edited by AndrewAPrice on Wed Feb 03, 2021 1:20 pm, edited 4 times in total.

Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Wed Feb 03, 2021 1:14 pm 
Offline
Member
Member
User avatar

Joined: Sun Feb 18, 2007 7:28 pm
Posts: 1564
AndrewAPrice wrote:
nakst wrote:


At a quick glance, it looks like you have your own build system? (Or is it just a program that invokes make?)

Now I'm not alone! :D

Hi,

So, er...no worries, you aren't alone in this. I wrote a build utility, "nbuild" back in 2016 -- the original version just recursively scanned the source tree and ran make. Since then I paused development efforts to focus on a complete SDK and build system. Visual Studio didn't represent the source structure very well as all being independent projects, and I wanted a way to self-host and keep the source repository independent, small, and clean, without unnecessary clutter of 3rd party applications or the need of a complex build setup. I plan to rewrite "nbuild" when everything is ready, but it would still use our internal "nmake" for building projects, "nbuild" would hopefully be smarter with dependency tracking. I should be able to do something like "b -x86 -debug" and it should "just work" by invoking nmake, nimg, etc to produce "mydisk.img". OS and toolchain specific build options are hidden in global environment makefiles (right now, they are in the form "tool-os-arch" like "link-win-x86.def") that are selected and included in the parent makefile.def depending on project-specific options (which has its own per-project makefile.) Per-project specific makefiles are kept very simple (just defines SOURCES, LIBS, TARGETNAME, TARGETTYPE, etc.) Project is of course still ongoing -- in all honestly though its been a lot of fun researching.

_________________
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Wed Feb 03, 2021 1:24 pm 
Offline
Member
Member
User avatar

Joined: Mon Jun 05, 2006 11:00 pm
Posts: 2293
Location: USA (and Australia)
eekee wrote:
has to figure out where each operating system or each Linux distro, gah! puts each and every one of the headers and libraries it needs.


This is a real problem! It shouldn't be this hard. That's one motivation for me to make a simpler build system for my OS.

_________________
My OS is Perception.


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Wed Feb 03, 2021 1:27 pm 
Offline
Member
Member
User avatar

Joined: Mon May 22, 2017 5:56 am
Posts: 812
Location: Hyperspace
AndrewAPrice wrote:
eekee wrote:
has to figure out where each operating system or each Linux distro, gah! puts each and every one of the headers and libraries it needs.


This is a real problem! It shouldn't be this hard. That's one motivation for me to make a simpler build system for my OS.

Me too. :) Some languages have kind-of solved it for anything written in that langauge, having package managers of their own, but I'm not keen on package managers and am thinking of other ways of organizing everything. I'm even thinking of multi-access filesystems so the user-visible tree as such is just one way to find things, not the only way.

_________________
Kaph — a modular OS intended to be easy and fun to administer and code for.
"May wisdom, fun, and the greater good shine forth in all your work." — Leo Brodie


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Wed Feb 03, 2021 2:39 pm 
Offline
Member
Member

Joined: Tue Feb 18, 2020 3:29 pm
Posts: 1071
I planned on writing my own build system, and I sort of did (just a very large script which does a lot of sanitization and has some nice abstractions. I actually use CMake, and then the aforementioned script calls CMake. It works quite well.

_________________
"How did you do this?"
"It's very simple — you read the protocol and write the code." - Bill Joy
Projects: NexNix | libnex | nnpkg


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Wed Feb 03, 2021 5:34 pm 
Offline
Member
Member
User avatar

Joined: Sat Sep 17, 2016 2:14 am
Posts: 83
Location: Moscow, Russia
nakst wrote:
Lots of applications :)

Image

That GUI looks impressive, but I suggest that there should be a bit more functionality, such as date/time displayed on the taskbar (similar to Windows NT 3.51 NewShell and up), an in-house support for Python, a self-hosting environment and a programming IDE (in case it will be too hard, no offence)
I give it a 10/10!

_________________
Coffee is not airplane fuel.


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Sat Feb 06, 2021 4:43 am 
Offline
Member
Member
User avatar

Joined: Sun Jan 17, 2016 7:57 am
Posts: 51
Shutdown modal.
Image


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Sat Feb 06, 2021 10:41 am 
Offline
Member
Member
User avatar

Joined: Mon May 22, 2017 5:56 am
Posts: 812
Location: Hyperspace
Showin off dat blur! Nice! :D

TimothyARyazanov reminds me I really liked it when I could have almost any program I wanted in a dock or panel. Various FVWM modules could "swallow" literally any graphical program. I was glad of this when I needed multiple timezone clocks. I later stopped bothering with configuring FVWM to swallow windows; it was difficult to set up. Instead, I had them open in specific positions and FVWM to avoid that area when placing windows. That was much easier to set up and worked well. In between, I used WindowMaker which would dock icons which worked with X11's icon window extension. Because the dockable clock programs were launched with a normal command line, I could set the timezone for each clock. This was impossible with Gnome of that era which had a very opaque, unscriptable interface to launching panel applets. I was hardly a programmer in those days. Documentation was horrible, code was worse, and the biggest obstacle of all was I was sinking all my creativity and attention into something else.

_________________
Kaph — a modular OS intended to be easy and fun to administer and code for.
"May wisdom, fun, and the greater good shine forth in all your work." — Leo Brodie


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Sun Feb 07, 2021 10:08 pm 
Offline
Member
Member

Joined: Wed Apr 25, 2018 2:44 pm
Posts: 33
Some of you guys have such amazing OS', kinda makes me nervous about showing my progress so far lol


Attachments:
File comment: Current OS UI
Capture.PNG
Capture.PNG [ 14.66 KiB | Viewed 6177 times ]
Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Mon Feb 08, 2021 12:18 am 
Offline
Member
Member
User avatar

Joined: Mon May 22, 2017 5:56 am
Posts: 812
Location: Hyperspace
@Armature: There have been plenty of screenshots like yours and simpler. :) Well done on getting a file system working. Dark blue on bright white is smart and most unusual for a text display. I'm not a fan of white backgrounds, but any high-contrast display is, for me, an improvement over the default low contrast of PC text modes.

_________________
Kaph — a modular OS intended to be easy and fun to administer and code for.
"May wisdom, fun, and the greater good shine forth in all your work." — Leo Brodie


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Tue Feb 09, 2021 2:18 pm 
Offline
Member
Member

Joined: Fri Jun 02, 2017 3:01 pm
Posts: 35
Finally implemented backtracing (with the symbol name being resolved), this should make debugging easier, unlike before, that I always had to just grab the instruction pointer, manually find the function using the address, and try discover what went wrong/what other function could have called it.

Image

_________________
https://github.com/ilmmatias/palladium


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Tue Feb 09, 2021 11:53 pm 
Offline
Member
Member

Joined: Wed Apr 25, 2018 2:44 pm
Posts: 33
eekee wrote:
@Armature: There have been plenty of screenshots like yours and simpler. :) Well done on getting a file system working. Dark blue on bright white is smart and most unusual for a text display. I'm not a fan of white backgrounds, but any high-contrast display is, for me, an improvement over the default low contrast of PC text modes.


Hey man thanks, I've spent the past few days working on Text input, that poxy backspace really got me lol. I tried uploading a video of It working but the file was too big. I'll try creating a smaller video


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Wed Feb 10, 2021 5:17 am 
Offline
Member
Member
User avatar

Joined: Tue Feb 11, 2014 4:59 pm
Posts: 74
Hey!

I managed to write simple graphics library (named: RGL - Raw Graphics Layer)

So, I'm ready to finish my Tetris clone :)

https://www.youtube.com/watch?v=e07igXIsiE4


_________________
https://blackdev.org/ - system programming, my own 64 bit kernel and software.


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Sun Feb 14, 2021 9:52 pm 
Offline
Member
Member

Joined: Wed Apr 25, 2018 2:44 pm
Posts: 33
I got my system running on my machine! :D

I'd show you a picture but apparently the maximum size is 128KiB.


Top
 Profile  
 
 Post subject: Re: What does your OS look like? (Screen Shots..)
PostPosted: Sun Feb 14, 2021 10:14 pm 
Offline
Member
Member

Joined: Wed Mar 30, 2011 12:31 am
Posts: 676
Armature wrote:
I got my system running on my machine! :D

I'd show you a picture but apparently the maximum size is 128KiB.

Most people upload their screenshots to external services.



I hacked together some basic TLS support and was able to build the new multithreading-capable version of my bytecode interpreter, so I can run this little threading demo that generates noise:

Image

_________________
toaruos on github | toaruos.org | gitlab | twitter | bim - a text editor


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3898 posts ]  Go to page Previous  1 ... 241, 242, 243, 244, 245, 246, 247 ... 260  Next

All times are UTC - 6 hours


Who is online

Users browsing this forum: Bing [Bot], Ethin, Google [Bot], SemrushBot [Bot] and 226 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group