Promoting OS checks to the shared directory

This may be later usefull for writing generic definitions.