ported to qt4. be sure unistd.h in included in cmxply.h