fix usage of file separators on Windows

file separator should always be "/" in directives (uncoupled from the OS environment)
previous implementation threw exceptions on Windows, because "\" was not quoted for RegEx (.split())