added pthread to TARGET_LINK_LIBRARIES