Make these directives more platform independent