Add missing #include <iostream> to glfw_main to fix Mac build.
Manually skip over . and .. as the S_ISDIR macro does not appear to work on MacOS.