source: trunk/third/libgnomeprintui/configure.in @ 18799

Revision 18799, 4.6 KB checked in by ghudson, 22 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r18798, which included commits to RCS files with non-trunk default branches.
Line 
1-*- mode: m4 -*-
2AC_PREREQ(2.52)
3AC_INIT(libgnomeprintui, 2.2.1.1,
4        http://bugzilla.gnome.org/enter_bug.cgi?product=gnome-print)
5
6AM_CONFIG_HEADER(config.h)
7AM_INIT_AUTOMAKE(libgnomeprintui,2.2.1.1)
8
9AM_MAINTAINER_MODE
10
11AC_ISC_POSIX
12AC_PROG_CC
13AC_PROG_CPP
14AC_PROG_CXX
15AC_STDC_HEADERS
16AM_PROG_LIBTOOL
17
18AC_DEFINE(WE_ARE_LIBGNOMEPRINT_INTERNALS, 1, [Define it so that we can read libgnomprint's private headers])
19
20dnl =============
21dnl Warning flags
22dnl =============
23GNOME_COMPILE_WARNINGS(maximum)
24CFLAGS="$CFLAGS $warning_flags"
25
26dnl =======
27dnl gettext
28dnl =======
29GETTEXT_PACKAGE=libgnomeprintui-2.2
30AC_SUBST(GETTEXT_PACKAGE)
31AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Gettext package])
32
33ALL_LINGUAS="am ar az be bg cs da de ca el es et eu fi fr ga gl he hi hr hu it ja ko lt lv mn ms nl nn no pl pt pt_BR ro ru sk sl sv ta tr uk vi wa zh_CN zh_TW"
34AM_GLIB_GNU_GETTEXT
35
36dnl ==========================================
37dnl Checks for gtk-doc and docbook-tools
38dnl ==========================================
39AC_ARG_WITH(html-dir, [  --with-html-dir=PATH    path to installed docs])
40if test "x$with_html_dir" = "x" ; then
41  HTML_DIR='${datadir}/gtk-doc/html'
42else
43  HTML_DIR=$with_html_dir
44fi
45AC_SUBST(HTML_DIR)
46
47AC_CHECK_PROG(GTKDOC, gtkdoc-mkdb, true, false)
48gtk_doc_min_version=0.9
49if $GTKDOC ; then
50    gtk_doc_version=`gtkdoc-mkdb --version`
51    AC_MSG_CHECKING([gtk-doc version ($gtk_doc_version) >= $gtk_doc_min_version])
52
53    IFS="${IFS=         }"; gtk_save_IFS="$IFS"; IFS="."
54    set $gtk_doc_version
55    for min in $gtk_doc_min_version ; do
56        cur=$1; shift
57        if test -z $min ; then break; fi
58        if test -z $cur ; then GTKDOC=false; break; fi
59        if test $cur -gt $min ; then break ; fi
60        if test $cur -lt $min ; then GTKDOC=false; break ; fi
61    done
62    IFS="$gtk_save_IFS"
63
64    if $GTKDOC ; then
65      AC_MSG_RESULT(yes)
66    else
67      AC_MSG_RESULT(no)
68    fi
69fi
70
71AM_CONDITIONAL(HAVE_GTK_DOC, $GTKDOC)
72AC_SUBST(HAVE_GTK_DOC)
73
74AC_CHECK_PROG(DB2HTML, db2html, true, false)
75AM_CONDITIONAL(HAVE_DOCBOOK, $DB2HTML)
76
77dnl Let people disable the gtk-doc stuff.
78AC_ARG_ENABLE(gtk-doc, [  --enable-gtk-doc        use gtk-doc to build documentation [default=auto]], enable_gtk_doc="$enableval", enable_gtk_doc=no)
79
80if test x$enable_gtk_doc = xyes ; then
81  if test x$GTKDOC = xtrue ; then
82    enable_gtk_doc=yes
83  else
84    enable_gtk_doc=no
85  fi
86fi
87
88dnl NOTE: We need to use a separate automake conditional for this
89dnl       to make this work with the tarballs.
90AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes)
91dnl ==========================================
92dnl END: Checks for gtk-doc and docbook-tools
93dnl ==========================================
94
95dnl =================
96dnl pkg-config checks
97dnl =================
98PKG_CHECK_MODULES(LIBGNOMEPRINTUI,
99        libgnomeprint-2.2 >= 2.2.1.1 \
100        libgnomecanvas-2.0 >= 1.117.0)
101AC_SUBST(LIBGNOMEPRINTUI_CFLAGS)
102AC_SUBST(LIBGNOMEPRINTUI_LIBS)
103
104AC_PATH_PROG(GLIB_GENMARSHAL, glib-genmarshal)
105
106dnl ================
107dnl CFLAGS & LDFLAGS
108dnl ================
109AC_SUBST(CFLAGS)
110AC_SUBST(CPPFLAGS)
111AC_SUBST(LDFLAGS)
112
113dnl ================================================
114dnl Used for the examples that need libglade support
115dnl ================================================
116PKG_CHECK_MODULES(LIBGLADE, [libglade-2.0], [libglade_msg=yes], [libglade_msg=no], [foo=yes])
117AM_CONDITIONAL(WITH_LIBGLADE, test x"$libglade_msg" = "xyes")
118AC_SUBST(LIBGLADE_CFLAGS)
119AC_SUBST(LIBGLADE_LIBS)
120
121dnl ============================================================================
122dnl We might want to link the examples with
123dnl ../libgnomeprint/libgnomeprint/libgnomeprint-2-2.la to not have to make
124dnl install after modifying libgnomeprint
125dnl ============================================================================
126AC_CHECK_FILE(../libgnomeprint/libgnomeprint/libgnomeprint-2-2.la, use_local_libgnomeprint_la="yes", use_local_libgnomeprint_la="no")
127AM_CONDITIONAL(EXAMPLES_USE_LOCAL_LIBGNOMEPRINT, test "x$use_local_libgnomeprint_la" = "xyes")
128
129AC_OUTPUT([
130Makefile
131po/Makefile.in
132libgnomeprintui/Makefile
133libgnomeprintui/gpaui/Makefile
134libgnomeprintui/libgnomeprintui-2.2.pc
135tests/Makefile
136examples/Makefile
137doc/Makefile
138])
139
140echo "
141        Compiler:               ${CC}
142        Compiler flags:         ${CFLAGS}"
143if test "x$use_local_libgnomeprint_la" = "xyes" ; then
144   echo "       Use local libgnomeprint-2-2.la for examples : Yes"
145else
146   echo "       Use local libgnomeprint-2-2.la for examples : No"
147fi
148if test "x$set_more_warnings" = "xno" ; then
149   echo "       Disable more warnings:  Yes"
150else
151   echo "       Disable more warnings:  No"
152fi
153if test x$enable_gtk_doc = xyes ; then
154   echo "       Enable gtk-doc:         Yes"
155else
156   echo "       Enable gtk-doc:         No"
157fi
158echo
Note: See TracBrowser for help on using the repository browser.