Voodooprojects

Chameleon => General Discussion => Topic started by: PolishOX on December 02, 2009, 12:44:31 AM

Title: Proper BSD Detection wCustom Icons
Post by: PolishOX on December 02, 2009, 12:44:31 AM
From the desktop of nawcom:

http://nawcom.com/pc_efi-10.5+bsd.diff

Another product of boredom.  I didn't like how the icons for any BSD OS is blank so I added support for detecting FreeBSD and OpenBSD OSs to the code.

(http://nawcom.com/poopzoom.jpg)(http://nawcom.com/poop.jpg)
Title: Re: Proper BSD Detection wCustom Icons
Post by: nawcom on December 02, 2009, 01:03:48 AM
 :o i wanted to use a better camera than the one in my $40 cellphone so i was going to wait until i took those and the  post this. I suppose PolishOX was too impatient or something hehe.

I'll have an actual screenshot later hehe as well as something to replace these horrible ones later. Well you get the idea from the picture.

*cue shitty camera in cellphone insults*

Instead of title-less, bland icons, you get the logos (or custom ones you provide via theme) + icon caption "FreeBSD" or "OpenBSD".. I'm sure I'll add the other ones later.

Erm.. BSD isn't dead... I swear d00ds..  :P heh
UPDATED

VMware is your friend when it comes to this shit.

(http://nawcom.com/screenshot.gif)

VERSION UPDATE

For Chameleon 2.0 RC4: http://nawcom.com/Chameleon-2.0-RC4-r684-BSD.diff

ANOTHER VERSION UPDATE

For Asere 1.1.9: http://nawcom.com/Chameleon-2.0-RC4_PCEFI-10.5_AsereBLN-BSD.diff

YET ANOTHER

Chameleon 2.0 RC5 r273 http://nawcom.com/Chameleon-2.0-RC5-r273-BSD.diff
Binaries http://nawcom.com/Chameleon-2.0-RC5-r273-BSD.bin.tar.gz
Title: Re: Proper BSD Detection wCustom Icons
Post by: s0nykus on December 02, 2009, 03:26:43 AM
You guys are fun, and woohoo! Let there be Pufferfish and Red Devils iconage! :)

I've had a good laugh over at nawcom.com, not that I'd know what to search for... hmm.. *scratches head*

But it makes me wonder... would Linux distro detection also be possible? What if I'd want a Slackware icon? :D
With the pipesmoking face of SubGenius J.R. Bob Dobbs? But we're yet again off topic. :) But still, what if, in theory?

Cheers!
Title: Re: Proper BSD Detection wCustom Icons
Post by: nawcom on December 05, 2009, 02:13:31 AM
s0nykus i keep my os x stuff in http://nawcom.com/osx86.

As for distributions, be sure and understand that there really isn't anything different when it comes down to distributions. I could put a Linux kernel together with my own customized GNU userspace environment and call it Nawcom Linux. It's still the Linux kernel with GNU userspace, just like Ubuntu, Fedora, Slackware, Debian, Gentoo. So the answer is no - you really can't tell what distribution it is, unless you want to specify it in the bootloader regarding the OS title which the bootloader can try and interpret, or add additional code for accessing files inside the ext* partition, which would be too much work and not worth it in my opinion. So ideally, no. There isn't any set standard for defining the distribution title via files.

If you look at the diff file you can see that this uses the same exact technique that is used for Linux detection, magic number values. Look at ext2fs.c, openbsd.c, freebsd.c and the functions FreeBSDProbe(), OpenBSDProbe(), and EX2Probe(). There is only one magic number value for Linux - not a special one for Ubuntu, Slackware, Fedora, Redhat, etc. The magic number is always the same regardless of Linux distribution. There are no "distributions" of BSDs per-say, as FreeBSD and NetBSD, OpenBSD, DragonflyBSD are all completely different OSs with different kernels, though of course all come from a common ancestor.
Title: Re: Proper BSD Detection wCustom Icons
Post by: rocksteady on December 08, 2009, 08:16:10 AM
heh smokin'

you guys should get together with our Theme Maestro - Blackosx and cook up a series of oldskool retro desktopia/bootscreenia
Title: Re: Proper BSD Detection wCustom Icons
Post by: s0nykus on December 16, 2009, 06:43:33 PM
Okay, so summing it up: Various flavours of BSD like OpenBSD, FreeBSD, NetBSD all come with different magic numbers, while all Linux distros come with the same magic number, making it virtually impossible to have a more fine-grained control over them. This sends us back to userland, and custom built themes and icons, so they can personalise their own installations to their liking. I know this is all irrelevant to proper functionality, but hey, we all know that style is essential!

Further on, I'll second what Rock says. All hail the Art of Boredom! Some of the best things in the world have been invented out of it. :D
Title: Re: Proper BSD Detection wCustom Icons
Post by: valv on October 05, 2010, 02:40:25 PM
As a passionate of bsd, I tried incorporating your patch into my branch, to end up with some warnings:
Code: [Select]
freebsd.c: In function ‘FreeBSDProbe’:
freebsd.c:9: warning: comparison is always false due to limited range of data type
openbsd.c:9:40: warning: integer constant is too large for its type
openbsd.c: In function ‘OpenBSDProbe’:
openbsd.c:9: warning: integer constant is too large for ‘long’ type
openbsd.c:9: warning: comparison is always false due to limited range of data type
I think it has to do with the long magic number.
Title: Re: Proper BSD Detection wCustom Icons
Post by: Blackosx on December 17, 2010, 06:08:14 PM
A year late - I know!   
But I have put together a couple of extra devices for Chameleon RC5's default theme to compliment nawcom's work for identifying FreeBSD and OpenBSD in the GUI.

(http://i52.tinypic.com/vrghs2.jpg)

Title: Re: Proper BSD Detection wCustom Icons
Post by: valv on December 17, 2010, 10:44:27 PM
Thank you dear. My branch gonna be happy with this one. Plus it is with one of your latest Themes.
Again thank you.
p.s.: please don't forget me when it comes to next themes. I do like your stuff over there :)
Following thoughts are not to criticize your work, but only suggestions:
1) I feel like drives would look nicer if they where closer to the horizontal
2) Regarding OpenDSB's logo, could the surrounding line be more darker (just like the FreeBSD one)
Even though am in love ;D
Title: Re: Proper BSD Detection wCustom Icons
Post by: Blackosx on December 20, 2010, 01:46:16 PM
Hi Valv

Thank you dear. My branch gonna be happy with this one. Plus it is with one of your latest Themes.
Again thank you.
p.s.: please don't forget me when it comes to next themes. I do like your stuff over there :)
No problem there :)  - I will add these to future themes and maybe (if I ever get time) go back and add extra devices to my existing themes.

1) I feel like drives would look nicer if they where closer to the horizontal
So view them from a different perspective? a bit like Blackosx_Default_II  (http://forum.voodooprojects.org/index.php/topic,1737.0.html)? or something different?

2) Regarding OpenDSB's logo, could the surrounding line be more darker (just like the FreeBSD one)
Yes, I'll tweak it (again when I get a chance).. :)
Title: Re: Proper BSD Detection wCustom Icons
Post by: valv on December 20, 2010, 02:49:13 PM
So view them from a different perspective? a bit like Blackosx_Default_II  (http://forum.voodooprojects.org/index.php/topic,1737.0.html)
yes and yes.
 ;D am very happy to have you my friend. HUGE Thank
Title: Re: Proper BSD Detection wCustom Icons
Post by: rocksteady on January 04, 2011, 01:26:30 AM
Good things come to those who wait

I'd almost forgotten this thread, thanks for reviving it B, smokin' pixels :)
Title: Re: Proper BSD Detection wCustom Icons
Post by: Blackosx on January 04, 2011, 02:04:05 PM
Cheers rocksteady, but the thanks goes to valv for taking on nawcom's addition and asking me to create the device icons.

And Valv, I will get round to tweaking the device icons soon - I just need to re-create the freeBSD and OpenBSD outlines in a vector package so I can add them in to the 3D app to make actual renders so I can produce matching device icons for the default / default II and default III themes.
Title: Re: Proper BSD Detection wCustom Icons
Post by: valv on January 04, 2011, 06:08:22 PM
Great! and again, thanks.
btw, Happy new year to you (rock, black and the folks) ;D
Title: Re: Proper BSD Detection wCustom Icons
Post by: Blackosx on January 04, 2011, 11:49:33 PM
Happy New Year Valv :)

You can find new BSD device icons at http://forum.voodooprojects.org/index.php/topic,1780.0.html
and I, and others if they choose, can add extra BSD device icons for other themes there too.
Title: Re: Proper BSD Detection wCustom Icons
Post by: Methanoid on April 05, 2012, 09:51:48 AM
This is just what i was looking for as a way to repurpose using Chameleon to boot other OS's with custom graphics.

The real question for me is how does Chameleon detect a partition is OpenBSD or FreeBSD? By format or by presence of a specific file(s)? I just need a small partition to "pretend" to be OpenBSD and then I can customise the graphics and chain load my alt OS.

If someone can help I promise to post some pretty pics etc when I am done  :)
Title: Re: Proper BSD Detection wCustom Icons
Post by: scorpius on May 07, 2012, 08:38:38 PM
It looks for the magic number at the beginning of a partition to see what type it is. For an example, the i386/libsaio/befs.c file shows how I added support for Haiku.
Title: Re: Proper BSD Detection wCustom Icons
Post by: Methanoid on May 08, 2012, 04:23:51 PM
If asked nicely could you add support for type &76 (Amiga) for Amithlon and AROS?  ;)   :)
Title: Re: Proper BSD Detection wCustom Icons
Post by: scorpius on May 08, 2012, 07:57:19 PM
I took a quick look at AROS (via a virtual machine) but couldn't find a way to install it to a single partition -- the installer kept failing. So I'm not able to help that much. However, if you can find the disk signature in the Amiga FFS partition, then that would be a good start.
Title: Re: Proper BSD Detection wCustom Icons
Post by: Tim S on August 21, 2012, 07:54:47 PM
Any chance for FreeDOS detection/icon?

Some of us multi-boot people use a FAT32 partition as a universal data partition.  But it's easy to throw FreeDOS on that partition.

I can get to it via Chameleon --> Linux --> GRUB2 Menu --> FreeDOS

But it would be great to access it directly from the Chameleon screen.