diff options
author | Christian Persch <chpe@cvs.gnome.org> | 2006-02-03 02:33:49 +0800 |
---|---|---|
committer | Christian Persch <chpe@src.gnome.org> | 2006-02-03 02:33:49 +0800 |
commit | ee0fbb04172977f5c8076f4a99658c35eef645d4 (patch) | |
tree | 9bef1360436ae633cae93e13401bb44b8559813c | |
parent | b311ff4ba10c572412ff812806a9e53c8928500c (diff) | |
download | gsoc2013-epiphany-ee0fbb04172977f5c8076f4a99658c35eef645d4.tar gsoc2013-epiphany-ee0fbb04172977f5c8076f4a99658c35eef645d4.tar.gz gsoc2013-epiphany-ee0fbb04172977f5c8076f4a99658c35eef645d4.tar.bz2 gsoc2013-epiphany-ee0fbb04172977f5c8076f4a99658c35eef645d4.tar.lz gsoc2013-epiphany-ee0fbb04172977f5c8076f4a99658c35eef645d4.tar.xz gsoc2013-epiphany-ee0fbb04172977f5c8076f4a99658c35eef645d4.tar.zst gsoc2013-epiphany-ee0fbb04172977f5c8076f4a99658c35eef645d4.zip |
Add GECKO_XPIDL to check for xpidl compiler and include directory.
2006-02-02 Christian Persch <chpe@cvs.gnome.org>
* m4/gecko.m4:
Add GECKO_XPIDL to check for xpidl compiler and include directory.
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | m4/gecko.m4 | 42 |
2 files changed, 48 insertions, 0 deletions
@@ -2,6 +2,12 @@ * m4/gecko.m4: + Add GECKO_XPIDL to check for xpidl compiler and include directory. + +2006-02-02 Christian Persch <chpe@cvs.gnome.org> + + * m4/gecko.m4: + Add GECKO_CHECK_HEADERS, wrapping AC_CHECK_HEADERS. * configure.ac: diff --git a/m4/gecko.m4 b/m4/gecko.m4 index 0611b024d..a6d456e5a 100644 --- a/m4/gecko.m4 +++ b/m4/gecko.m4 @@ -418,3 +418,45 @@ fi AS_VAR_POPDEF([gecko_cv_have_CID]) ]) + +# *************************************************************************** +# *************************************************************************** +# *************************************************************************** + +# GECKO_XPIDL([ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND]) +# +# Checks for xpidl program and include directory +# +# Variables set: +# XPIDL: the xpidl program +# XPIDL_IDLDIR: the xpidl include directory + +AC_DEFUN([GECKO_XPIDL], +[AC_REQUIRE([GECKO_INIT])dnl + +_GECKO_LIBDIR="`$PKG_CONFIG --variable=libdir ${gecko_cv_gecko}-xpcom`" + +AC_PATH_PROG([XPIDL],[xpidl],[no],[$_GECKO_LIBDIR:$PATH]) + +XPIDL_IDLDIR="`$PKG_CONFIG --variable=idldir ${gecko_cv_gecko}-xpcom`" + +# Older gecko's don't have this variable, see +# https://bugzilla.mozilla.org/show_bug.cgi?id=240473 + +if test -z "$XPIDL_IDLDIR" -o ! -f "$XPIDL_IDLDIR/nsISupports.idl"; then + XPIDL_IDLDIR="`echo $_GECKO_LIBDIR | sed -e s!lib!share/idl!`" +fi + +# Some distributions (Gentoo) have it in unusual places + +if test -z "$XPIDL_IDLDIR" -o ! -f "$XPIDL_IDLDIR/nsISupports.idl"; then + XPIDL_IDLDIR="$_GECKO_INCLUDE_ROOT/idl" +fi + +if test "$XPIDL" != "no" -a -n "$XPIDL_IDLDIR" -a -f "$XPIDL_IDLDIR/nsISupports.idl"; then + ifelse([$1],,[:],[$1]) +else + ifelse([$2],,[AC_MSG_FAILURE([XPIDL program or include directory not found])],[$2]) +fi + +]) |