"Final" cleanup

If osx and bsd test is ok, it should be ready for merge