add path options, better pathlist handling.
fix pathlist