add new switch use-system-libcares
add command line switch (--use-system-cares)
move code around