Use OS-independent path delimiter

Fixes #1187