various changes mainly due to unix build