http://people.cs.pitt.edu/~znati/Courses/IntrOS/Dir-Proj/Prj1.pdf