build: Make -lpthread take preference over -pthread

This makes libpoppler link to pthreads and fixes runtime error due to
unresolved pthread symbols when running some of the utils and tests.
3 files changed