I don't belive in ifdef blocks within a single function. Ideally
keep the blocks separate at worst. I think if this is necessary
at the time it's permissible but overall it's fucking ugly.
To make this maintainable (for now), split the machine querying
code into separate files. I'd like to be able to modify the file
without fear of breaking it here or there. Also, for anyone who
wants to make a change or ammendment doing this is cleaner.