linux: link to pthread and ldl