RHEL support

And some other minor changes. Warning, I did not test some of them after last merge...