Added unistd include to eventloop-integration.cpp
Added PTHREAD_LIBS variable to be set in another discovery case in acx_pthread
Fix crash when invoking method without specifying interface

Previously this meant the interface variable is NULL, which led to an invalid
string conversion from NULL to string, causing a crash. Check for NULL before
doing the conversion.