configure: separate LDFLAGS and extra-libraries fields

Fixes #13.