No longer confuse curl and libcurl in the configure script

Closes #2559
Review 1775 by @larkost