~ubuntu-branches/debian/jessie/cheese/jessie

« back to all changes in this revision

Viewing changes to m4/gtk-doc.m4

  • Committer: Package Import Robot
  • Author(s): Andreas Henriksson
  • Date: 2014-04-02 21:39:33 UTC
  • mfrom: (1.5.1) (15.1.7 experimental)
  • Revision ID: package-import@ubuntu.com-20140402213933-r0w3gna0pv7q7085
Tags: 3.12.0-1
* New upstream release.
* Revert changes done in 3.10.1-3
  - i.e. lower gnome-desktop build-dependency again.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
dnl -*- mode: autoconf -*-
2
2
 
3
 
# serial 1
 
3
# serial 2
4
4
 
5
5
dnl Usage:
6
6
dnl   GTK_DOC_CHECK([minimum-gtk-doc-version])
10
10
  AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
11
11
  AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
12
12
 
 
13
  ifelse([$1],[],[gtk_doc_requires="gtk-doc"],[gtk_doc_requires="gtk-doc >= $1"])
 
14
  AC_MSG_CHECKING([for gtk-doc])
 
15
  PKG_CHECK_EXISTS([$gtk_doc_requires],[have_gtk_doc=yes],[have_gtk_doc=no])
 
16
  AC_MSG_RESULT($have_gtk_doc)
 
17
 
 
18
  if test "$have_gtk_doc" = "no"; then
 
19
      AC_MSG_WARN([
 
20
  You will not be able to create source packages with 'make dist'
 
21
  because $gtk_doc_requires is not found.])
 
22
  fi
 
23
 
13
24
  dnl check for tools we added during development
14
25
  dnl Use AC_CHECK_PROG to avoid the check target using an absolute path that
15
26
  dnl may not be writable by the user. Currently, automake requires that the
33
44
                   [use gtk-doc to build documentation [[default=no]]]),,
34
45
    [enable_gtk_doc=no])
35
46
 
36
 
  if test x$enable_gtk_doc = xyes; then
37
 
    ifelse([$1],[],
38
 
      [PKG_CHECK_EXISTS([gtk-doc],,
39
 
                        AC_MSG_ERROR([gtk-doc not installed and --enable-gtk-doc requested]))],
40
 
      [PKG_CHECK_EXISTS([gtk-doc >= $1],,
41
 
                        AC_MSG_ERROR([You need to have gtk-doc >= $1 installed to build $PACKAGE_NAME]))])
42
 
    dnl don't check for glib if we build glib
43
 
    if test "x$PACKAGE_NAME" != "xglib"; then
44
 
      dnl don't fail if someone does not have glib
45
 
      PKG_CHECK_MODULES(GTKDOC_DEPS, glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0,,[:])
46
 
    fi
47
 
  fi
48
 
 
49
47
  AC_MSG_CHECKING([whether to build gtk-doc documentation])
50
48
  AC_MSG_RESULT($enable_gtk_doc)
51
49
 
 
50
  if test "x$enable_gtk_doc" = "xyes" && test "$have_gtk_doc" = "no"; then
 
51
    AC_MSG_ERROR([
 
52
  You must have $gtk_doc_requires installed to build documentation for
 
53
  $PACKAGE_NAME. Please install gtk-doc or disable building the
 
54
  documentation by adding '--disable-gtk-doc' to '[$]0'.])
 
55
  fi
 
56
 
 
57
  dnl don't check for glib if we build glib
 
58
  if test "x$PACKAGE_NAME" != "xglib"; then
 
59
    dnl don't fail if someone does not have glib
 
60
    PKG_CHECK_MODULES(GTKDOC_DEPS, glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0,,[:])
 
61
  fi
 
62
 
52
63
  dnl enable/disable output formats
53
64
  AC_ARG_ENABLE([gtk-doc-html],
54
65
    AS_HELP_STRING([--enable-gtk-doc-html],
68
79
  fi
69
80
  AC_SUBST([AM_DEFAULT_VERBOSITY])
70
81
 
 
82
  AM_CONDITIONAL([HAVE_GTK_DOC], [test x$have_gtk_doc = xyes])
71
83
  AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes])
72
84
  AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes])
73
85
  AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes])