Fix ReplaceSpecialPaths() and use XDG specs

Something like this... please check if this is really what is needed for Linux (directory names, etc).