Proper domain setup.

Also Proper multiple PrivateBinPath handling
Merge pull request #1 from xumix/master

Added some minor and major changes)