Author Topic: Proper BSD Detection wCustom Icons  (Read 17623 times)

0 Members and 1 Guest are viewing this topic.

PolishOX

  • Observer
  • Posts: 12
Proper BSD Detection wCustom Icons
« 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.


nawcom

  • VoodooLabs
  • Posts: 5
Re: Proper BSD Detection wCustom Icons
« Reply #1 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.



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
« Last Edit: July 28, 2010, 10:15:18 PM by nawcom »

s0nykus

  • Observer
  • Posts: 12
  • Coders know all the right MOV-s! ;)
Re: Proper BSD Detection wCustom Icons
« Reply #2 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!
Dell Latitude D830
BIOS A14
Core2 Duo T9500 Penryn 2.6GHz
Intel PM965, 82801HBM (ICH8-ME)
4GB Hyundai PC2-5300 nVidia Quadro NVS 140M Broadcom BCM5755M Gbit (32bit drv) Wi-Fi Intel 4965 AGN (no drv) USB Wi-Fi Canyon CNP-WF518 (32bit drv) Triple boot SL 10.6.2/Ubuntu 9.10/Win7 x64

nawcom

  • VoodooLabs
  • Posts: 5
Re: Proper BSD Detection wCustom Icons
« Reply #3 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.
« Last Edit: December 05, 2009, 02:33:55 AM by nawcom »

rocksteady

  • Global Moderator
  • Posts: 233
  • Root Down
Re: Proper BSD Detection wCustom Icons
« Reply #4 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
Stop bitching, start coding or documenting or both..

P5Q-EM : Q6600 : 8GB RAM : 8800GT : SATA Drives

s0nykus

  • Observer
  • Posts: 12
  • Coders know all the right MOV-s! ;)
Re: Proper BSD Detection wCustom Icons
« Reply #5 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
Dell Latitude D830
BIOS A14
Core2 Duo T9500 Penryn 2.6GHz
Intel PM965, 82801HBM (ICH8-ME)
4GB Hyundai PC2-5300 nVidia Quadro NVS 140M Broadcom BCM5755M Gbit (32bit drv) Wi-Fi Intel 4965 AGN (no drv) USB Wi-Fi Canyon CNP-WF518 (32bit drv) Triple boot SL 10.6.2/Ubuntu 9.10/Win7 x64

valv

  • VoodooLabs
  • Posts: 72
    • The AnVAL Forum (fr)
Re: Proper BSD Detection wCustom Icons
« Reply #6 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.

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: Proper BSD Detection wCustom Icons
« Reply #7 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.



10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

valv

  • VoodooLabs
  • Posts: 72
    • The AnVAL Forum (fr)
Re: Proper BSD Detection wCustom Icons
« Reply #8 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

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: Proper BSD Detection wCustom Icons
« Reply #9 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 ? 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).. :)
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

valv

  • VoodooLabs
  • Posts: 72
    • The AnVAL Forum (fr)
Re: Proper BSD Detection wCustom Icons
« Reply #10 on: December 20, 2010, 02:49:13 PM »
So view them from a different perspective? a bit like Blackosx_Default_II
yes and yes.
 ;D am very happy to have you my friend. HUGE Thank

rocksteady

  • Global Moderator
  • Posts: 233
  • Root Down
Re: Proper BSD Detection wCustom Icons
« Reply #11 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 :)
Stop bitching, start coding or documenting or both..

P5Q-EM : Q6600 : 8GB RAM : 8800GT : SATA Drives

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: Proper BSD Detection wCustom Icons
« Reply #12 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.
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

valv

  • VoodooLabs
  • Posts: 72
    • The AnVAL Forum (fr)
Re: Proper BSD Detection wCustom Icons
« Reply #13 on: January 04, 2011, 06:08:22 PM »
Great! and again, thanks.
btw, Happy new year to you (rock, black and the folks) ;D

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: Proper BSD Detection wCustom Icons
« Reply #14 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.
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB