Looking for someone who can achieve the following for both BSD & Mac platforms. If you can only do one, please mention so. There should be a lot of similarities between the two. Just need a single piece of code with preprocessors.
Features needed:
- Retrieve computer manufacturer into string (could just be a "Apple" string for Mac if the BSD route doesn't work on Mac)
- Retrieve computer serial number into string
- Retrieve BIOS make & model as well as version number into strings (not needed for Mac)
- Retrieve number of physical CPUs into int (number of CPUs, not cores)
- Retrieve number of cores on CPU into int (cores per CPU if multiple CPUs)
- Retrieve operating system name & version into strings (not required for Mac OS X, only BSD variants)
- Check whether a Mac is a member of an Active Directory domain and retrieve the domain name into a string (not for BSD)
- Retrieve last logged in user into string
- Retrieve VGA adapter name into string (i.e. "nVidia GeForce 9300")
- Retrieve list of PCI devices into array of strings (only names)
Requirements:
- No popen/system calls please. I know it's fairly straightforward to query a lot of this information via shell commands, that's not what's needed.
- sysctl calls are fine. Try to avoid hardware/OS dependent calls (such as 'machdep', etc.) where possible, obviously.
- No third party libraries please. Only standard C++.
- If you can only do a portion of the work, please say so.
- A simple .cpp file would be accepted as deliverable.
More work will follow.