fix absolute/relative paths for files and support package names