There are some conflicts with wait() function defined in test programs and OS X system wait(). I simply renamed the function, made some ld option compatible with OS X in Makefile. After that it compiled and works fine.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
There are some conflicts with wait() function defined in test programs and OS X system wait(). I simply renamed the function, made some ld option compatible with OS X in Makefile. After that it compiled and works fine.