use autoconf macro to check for pkg-config (closes #15506)