+# Establish location of opensaml catalogs.
+OPENSAMLXMLDIR=""
+if test "x$with_saml" = "x" ; then
+ with_saml="/usr"
+fi
+if test -f $with_saml/share/xml/opensaml/saml20-catalog.xml ; then
+ OPENSAMLXMLDIR="$with_saml"
+else
+ if test -f $with_xmltooling/share/xml/opensaml/saml20-catalog.xml ; then
+ OPENSAMLXMLDIR="$with_xmltooling"
+ else
+ if test -f $with_xerces/share/xml/opensaml/saml20-catalog.xml ; then
+ OPENSAMLXMLDIR="$with_xerces"
+ else
+ if test -f $with_log4shib/share/xml/opensaml/saml20-catalog.xml ; then
+ OPENSAMLXMLDIR="$with_log4shib"
+ fi
+ fi
+ fi
+fi
+if test "x$OPENSAMLXMLDIR" = "x" ; then
+ AC_MSG_ERROR([opensaml XML catalogs not found, may need to use --with-saml option])
+fi
+OPENSAMLXMLDIR="$OPENSAMLXMLDIR/share/xml/opensaml"
+AC_SUBST(OPENSAMLXMLDIR);
+