Added POSIX examples and modified extred.c for function prototypes due to gcc 4.7 under debian wheezy.