Fixes bugs with relative path handling

Use Cwd::chdir for a safer implementation of chdir.
Resolve $relpath to absolute path before calling rel2abs,
which seems to fix a bug on windows with the Watchdog.
Implements better handling for included files

Watchdog now picks up changes done in imported css files.