diff options
-rw-r--r-- | ChangeLog | 9 | ||||
-rw-r--r-- | configure.ac | 6 | ||||
-rw-r--r-- | m4/gecko.m4 | 22 |
3 files changed, 27 insertions, 10 deletions
@@ -1,5 +1,14 @@ 2005-11-09 Christian Persch <chpe@cvs.gnome.org> + * configure.ac: + * m4/gecko.m4: + + Add check for contract IDs which we need but are only provided + by extensions which may or may not have been built into gecko. + We cannot check for the headers here since they are always present. + +2005-11-09 Christian Persch <chpe@cvs.gnome.org> + * data/glade/epiphany.glade: Because the Dwnloads window is a GtkDiaog for technical reasons, diff --git a/configure.ac b/configure.ac index c34aa0a6a..85b5b748a 100644 --- a/configure.ac +++ b/configure.ac @@ -405,6 +405,12 @@ if test "x$enable_filepicker" = "xyes"; then AC_DEFINE([ENABLE_FILEPICKER],[1],[Define to enable the native filepicker]) fi +dnl Check for some contractIDs that we need but are provided by extensions +dnl which may or may not have been built. + +GECKO_CHECK_CONTRACTID([PermissionsManager],[@mozilla.org/permissionmanager;1]) +GECKO_CHECK_CONTRACTID([CookiePermission],[@mozilla.org/cookie/permission;1]) + dnl *************** dnl Multimedia keys dnl *************** diff --git a/m4/gecko.m4 b/m4/gecko.m4 index 2c656d0a7..29542fbd3 100644 --- a/m4/gecko.m4 +++ b/m4/gecko.m4 @@ -177,15 +177,15 @@ dnl *************************************************************************** dnl *************************************************************************** dnl *************************************************************************** -dnl GECKO_CHECK_CONTRACTID_REGISTERED(IDENTIFIER, CONTRACTID, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) +dnl GECKO_CHECK_CONTRACTID(IDENTIFIER, CONTRACTID, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) dnl -AC_DEFUN([GECKO_CHECK_CONTRACTID_REGISTERED], +AC_DEFUN([GECKO_CHECK_CONTRACTID], [AC_REQUIRE([GECKO_INIT])dnl AC_CACHE_CHECK([for the $2 XPCOM component], -[gecko_cv_xpcom_service_[]$1], +[gecko_cv_xpcom_contractid_[]$1], [ -gecko_cv_xpcom_service_[]$1[]=no +gecko_cv_xpcom_contractid_[]$1[]=no AC_LANG_PUSH([C++]) @@ -210,7 +210,7 @@ if (NS_FAILED (rv) || !serviceManager) { } nsCOMPtr<nsISupports> service; -rv = serviceManager->GetServiceByContractID ($2, NS_GET_IID (nsISupports), getter_AddRefs (service)); +rv = serviceManager->GetServiceByContractID ("$2", NS_GET_IID (nsISupports), getter_AddRefs (service)); if (NS_FAILED (rv) || !service) { NS_ShutdownXPCOM (nsnull); exit (EXIT_FAILURE); @@ -220,9 +220,9 @@ NS_ShutdownXPCOM (nsnull); exit (EXIT_SUCCESS); ]) ], -[gecko_cv_xpcom_service_[]$1[]=yes], -[gecko_cv_xpcom_service_[]$1[]=no], -[gecko_cv_xpcom_service_[]$1[]="no (cross-compiling)"]) +[gecko_cv_xpcom_contractid_[]$1[]=yes], +[gecko_cv_xpcom_contractid_[]$1[]=no], +[gecko_cv_xpcom_contractid_[]$1[]="no (cross-compiling)"]) CPPFLAGS="$_SAVE_CPPFLAGS" CXXFLAGS="$_SAVE_CXXFLAGS" @@ -232,10 +232,12 @@ AC_LANG_POP([C++]) ]) -if test "$gecko_cv_xpcom_service_[]$1" = "yes"; then +if test "$gecko_cv_xpcom_contractid_[]$1" = "yes"; then ifelse([$3],,[:],[$3]) else - ifelse([$4],,[:],[$4]) + ifelse([$4],,[AC_MSG_FAILURE([dnl +Contract ID "$2" is not registered, but this program depends on it.])], + [$4]) fi ]) |