Module for generic platform information: platform.py

Malcolm Tredinnick malcolmt at smart.net.au
Wed Oct 27 05:16:43 EDT 1999


On Wed, Oct 27, 1999 at 09:55:19AM +0100, Adrian Eyre wrote:
> BTW: You can add in detection for Minix as well. I should be able
> to test this.
> 
> The canonical way is to check for the presence of the file:
> 
> /usr/include/minix/config.h

When Marc originally proposed this module, I thought of doing the Linux
detect this way, but after a bit of thinking one realises that it won't be
generic enough. Imagine that you create a production Linux box that is only
meant to run scripts and pre-compiled programs. Since you wouldn't have (or
be allowed to) compile programs, there is no reason for the header files to
exist on that machine. I'm not sure how real-world this type of situation
is, but I nearly have it in practice on my laptop at the moment (I've
stripped out absolutely everything I don't need to do my work while
travelling about the city).

Cheers,
Malcolm Tredinnick





More information about the Python-list mailing list