Added Makefile.
Added checking for regular files, directories and symlinks.