cmake UPDATE link libcurl directly if no config file found

Refs #1582
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f6792d1..74b0172 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -259,7 +259,13 @@
 
     # dependencies - libcurl
     find_package(CURL 7.30.0 REQUIRED)
-    target_link_libraries(netconf2 CURL::libcurl)
+    if(TARGET CURL::libcurl)
+        target_link_libraries(netconf2 CURL::libcurl)
+    else()
+        target_link_libraries(netconf2 ${CURL_LIBRARIES})
+        list(APPEND CMAKE_REQUIRED_LIBRARIES ${CURL_LIBRARY})
+        include_directories(${CURL_INCLUDE_DIRS})
+    endif()
 
     # crypt (if not found, assume no library needs to be linked)
     if(${CMAKE_SYSTEM_NAME} MATCHES "QNX")