fix issues for OSX
replaced glib thread and mutex with cpp ones
glib cond to cpp cond
scan dylib plugins
using std::thread in gtk plugin
correctly using gtk_idle_add in gtk plugin
fix gtk plugin issues on linux