1 | AC_INIT(vte.pc.in) |
---|
2 | VERSION=`grep ^Version: $srcdir/vte.spec | awk '{print $NF}'` |
---|
3 | AM_INIT_AUTOMAKE(vte,$VERSION) |
---|
4 | |
---|
5 | AC_ISC_POSIX |
---|
6 | AC_PROG_CC |
---|
7 | AC_STDC_HEADERS |
---|
8 | AM_PROG_CC_STDC |
---|
9 | AM_MAINTAINER_MODE |
---|
10 | |
---|
11 | AM_PROG_LIBTOOL |
---|
12 | ALL_LINGUAS="am ar az be bg bn ca cs cy da de el en_CA en_GB es et eu fa fi fr ga gu he hr hu id is it ja ko li lt lv mk ml mn ms ne nl nn no pa pl pt pt_BR ro ru sk sl sq sr sr@Latn sv tr uk vi wa zh_CN zh_TW" |
---|
13 | |
---|
14 | AM_GLIB_GNU_GETTEXT |
---|
15 | AC_CHECK_DECLS(bind_textdomain_codeset,,,[#include "libintl.h"]) |
---|
16 | |
---|
17 | AC_PATH_XTRA |
---|
18 | CFLAGS="$X_CFLAGS $CFLAGS" |
---|
19 | LIBS="$X_LIBS $LIBS" |
---|
20 | |
---|
21 | if pkg-config --exists "gtk+-2.0 >= 2.2" ; then |
---|
22 | MODULEGTK="gtk+-2.0 >= 2.2" |
---|
23 | AC_DEFINE(GDK_MULTIHEAD_SAFE,1,[Force use of GDK's multihead-safe APIs.]) |
---|
24 | else |
---|
25 | MODULEGTK="gtk+-2.0" |
---|
26 | fi |
---|
27 | PKG_CHECK_MODULES(GLIB,glib-2.0) |
---|
28 | PKG_CHECK_MODULES(GOBJECT,[glib-2.0 gobject-2.0]) |
---|
29 | PKG_CHECK_MODULES(GTK,[glib-2.0 gobject-2.0 $MODULEGTK]) |
---|
30 | |
---|
31 | wantedmodules="glib-2.0 gobject-2.0 $MODULEGTK fontconfig" |
---|
32 | |
---|
33 | # Let the user specify the default terminal emulation. |
---|
34 | AC_ARG_WITH(default-emulation, |
---|
35 | AS_HELP_STRING(--with-default-emulation=xterm,default terminal type to be emulated), |
---|
36 | emulation=$withval,emulation=xterm) |
---|
37 | AC_DEFINE_UNQUOTED(VTE_DEFAULT_EMULATION,"$emulation",[The default terminal type to be emulated.]) |
---|
38 | VTE_DEFAULT_EMULATION=$emulation |
---|
39 | AC_SUBST(VTE_DEFAULT_EMULATION) |
---|
40 | |
---|
41 | # Use Xft2 if Pango has Xft2 support and it isn't disabled. |
---|
42 | if test "$have_x" = yes ; then |
---|
43 | AC_ARG_WITH(xft2,[AS_HELP_STRING(--with-xft2,enable drawing using Xft2)],with_xft2=$withval,with_xft2=yes) |
---|
44 | if test $with_xft2 = yes ; then |
---|
45 | if pkg-config --exists pangoxft '>=' 1.1.0 ; then |
---|
46 | AC_DEFINE(HAVE_XFT2,1,[Whether we have Xft2]) |
---|
47 | wantedmodules="$wantedmodules pangoxft >= 1.1.0" |
---|
48 | wantedmodules="xft >= 2.0 $wantedmodules" |
---|
49 | else |
---|
50 | AC_MSG_WARN([Xft2 not detected]) |
---|
51 | fi |
---|
52 | fi |
---|
53 | fi |
---|
54 | |
---|
55 | # Use PangoX if we have it and it isn't disabled. |
---|
56 | if test "$have_x" = yes ; then |
---|
57 | AC_ARG_WITH(pangox,[AS_HELP_STRING(--with-pangox,enable drawing using PangoX)],with_pangox=$withval,with_pangox=yes) |
---|
58 | if test $with_pangox = yes ; then |
---|
59 | if pkg-config --exists pangox ; then |
---|
60 | AC_DEFINE(HAVE_PANGOX,1,[Whether we have PangoX]) |
---|
61 | wantedmodules="$wantedmodules pangox" |
---|
62 | else |
---|
63 | AC_MSG_WARN([PangoX not detected]) |
---|
64 | fi |
---|
65 | fi |
---|
66 | fi |
---|
67 | |
---|
68 | # Use glX if we have it and it isn't disabled. |
---|
69 | if test "$have_x" = yes ; then |
---|
70 | AC_ARG_WITH(glX,[AS_HELP_STRING(--with-glX,enable drawing using glX)],with_glx=$withval,with_glx=no) |
---|
71 | if test $with_glx = yes ; then |
---|
72 | have_gl=0 |
---|
73 | have_libgl=0 |
---|
74 | AC_CHECK_HEADERS(GL/glx.h) |
---|
75 | if test $ac_cv_header_GL_glx_h = yes ; then |
---|
76 | AC_CHECK_FUNC(glXQueryExtension,[have_gl=1],AC_CHECK_LIB(GL,glXQueryExtension,[have_gl=1;have_libgl=1])) |
---|
77 | fi |
---|
78 | if test $have_gl = 1 ; then |
---|
79 | AC_DEFINE(HAVE_GL,1,[Whether we have GL and glX.]) |
---|
80 | fi |
---|
81 | if test $have_libgl = 1 ; then |
---|
82 | LIBS="-lGLU -lGL $LIBS" |
---|
83 | fi |
---|
84 | fi |
---|
85 | fi |
---|
86 | |
---|
87 | # Search for the required modules. |
---|
88 | PKG_CHECK_MODULES(VTE,[$wantedmodules]) |
---|
89 | NEEDEDPACKAGES="$wantedmodules" |
---|
90 | AC_SUBST(NEEDEDPACKAGES) |
---|
91 | |
---|
92 | # Require Freetype2. We use our local copy of the macro because packages of |
---|
93 | # freetype's development files don't always include the proper macro. |
---|
94 | VTE_CHECK_FT2(6.1.0,,[AC_MSG_ERROR([You must have freetype 2.0.2 or later to build vte.])]) |
---|
95 | |
---|
96 | # Temporarily pull in the Freetype cflags and libs for checking what's |
---|
97 | # available in this version. |
---|
98 | savecflags="$CFLAGS" |
---|
99 | CFLAGS="$CFLAGS $FT2_CFLAGS" |
---|
100 | savecppflags="$CPPFLAGS" |
---|
101 | CPPFLAGS="$CPPFLAGS $FT2_CFLAGS" |
---|
102 | if test -d "$ac_x_includes" ; then |
---|
103 | CFLAGS="$CFLAGS -I$ac_x_includes" |
---|
104 | CPPFLAGS="$CPPFLAGS -I$ac_x_includes" |
---|
105 | fi |
---|
106 | AC_CHECK_HEADERS(ft2build.h) |
---|
107 | if test x$ac_cv_header_ft2build_h != xyes ; then |
---|
108 | AC_MSG_ERROR([You must have freetype 2.0.2 or later to build vte.]) |
---|
109 | fi |
---|
110 | |
---|
111 | AC_CHECK_DECL(ft_render_mode_mono,[AC_DEFINE(HAVE_DECL_ft_render_mode_mono,1,Define if your freetype2 installation defines ft_render_mode_mono.)],,[ |
---|
112 | #ifdef HAVE_FT2BUILD_H |
---|
113 | #include <ft2build.h> |
---|
114 | #include FT_FREETYPE_H |
---|
115 | #endif |
---|
116 | ]) |
---|
117 | |
---|
118 | AC_CHECK_DECL(FT_RENDER_MODE_MONO,[AC_DEFINE(HAVE_DECL_FT_RENDER_MODE_MONO,1,Define if your freetype2 installation defines FT_RENDER_MODE_MONO.)],,[ |
---|
119 | #ifdef HAVE_FT2BUILD_H |
---|
120 | #include <ft2build.h> |
---|
121 | #include FT_FREETYPE_H |
---|
122 | #endif |
---|
123 | ]) |
---|
124 | |
---|
125 | AC_CHECK_DECLS(FT_LOAD_NO_HINTING,,,[ |
---|
126 | #ifdef HAVE_FT2BUILD_H |
---|
127 | #include <ft2build.h> |
---|
128 | #include FT_FREETYPE_H |
---|
129 | #endif |
---|
130 | ]) |
---|
131 | |
---|
132 | AC_CHECK_DECLS(FT_RENDER_MODE_LIGHT,,,[ |
---|
133 | #ifdef HAVE_FT2BUILD_H |
---|
134 | #include <ft2build.h> |
---|
135 | #include FT_FREETYPE_H |
---|
136 | #endif |
---|
137 | ]) |
---|
138 | |
---|
139 | AC_CHECK_DECLS(FT_RENDER_MODE_NORMAL,,,[ |
---|
140 | #ifdef HAVE_FT2BUILD_H |
---|
141 | #include <ft2build.h> |
---|
142 | #include FT_FREETYPE_H |
---|
143 | #endif |
---|
144 | ]) |
---|
145 | |
---|
146 | AC_CHECK_DECL(FT_PIXEL_MODE_MONO,[AC_DEFINE(HAVE_DECL_FT_PIXEL_MODE_MONO,1,Define if your freetype2 build declares FT_PIXEL_MODE_MONO.)],,[ |
---|
147 | #ifdef HAVE_FT2BUILD_H |
---|
148 | #include <ft2build.h> |
---|
149 | #include FT_FREETYPE_H |
---|
150 | #endif |
---|
151 | ]) |
---|
152 | AC_CHECK_DECL(ft_pixel_mode_mono,[AC_DEFINE(HAVE_DECL_ft_pixel_mode_mono,1,Define if your freetype2 build declares ft_pixel_mode_mono.)],,[ |
---|
153 | #ifdef HAVE_FT2BUILD_H |
---|
154 | #include <ft2build.h> |
---|
155 | #include FT_FREETYPE_H |
---|
156 | #endif |
---|
157 | ]) |
---|
158 | |
---|
159 | AC_CHECK_DECLS(FT_PIXEL_MODE_GRAY2,,,[ |
---|
160 | #ifdef HAVE_FT2BUILD_H |
---|
161 | #include <ft2build.h> |
---|
162 | #include FT_FREETYPE_H |
---|
163 | #endif |
---|
164 | ]) |
---|
165 | AC_CHECK_DECLS(FT_PIXEL_MODE_GRAY4,,,[ |
---|
166 | #ifdef HAVE_FT2BUILD_H |
---|
167 | #include <ft2build.h> |
---|
168 | #include FT_FREETYPE_H |
---|
169 | #endif |
---|
170 | ]) |
---|
171 | |
---|
172 | AC_CHECK_DECL(FT_PIXEL_MODE_GRAY,[AC_DEFINE(HAVE_DECL_FT_PIXEL_MODE_GRAY,1,Define if your freetype2 build declares FT_PIXEL_MODE_GRAY.)],,[ |
---|
173 | #ifdef HAVE_FT2BUILD_H |
---|
174 | #include <ft2build.h> |
---|
175 | #include FT_FREETYPE_H |
---|
176 | #endif |
---|
177 | ]) |
---|
178 | AC_CHECK_DECL(ft_pixel_mode_grays,[AC_DEFINE(HAVE_DECL_ft_pixel_mode_grays,1,Define if your freetype2 build declares ft_pixel_mode_grays.)],,[ |
---|
179 | #ifdef HAVE_FT2BUILD_H |
---|
180 | #include <ft2build.h> |
---|
181 | #include FT_FREETYPE_H |
---|
182 | #endif |
---|
183 | ]) |
---|
184 | |
---|
185 | AC_CHECK_DECLS(FT_PIXEL_MODE_LCD,,,[ |
---|
186 | #ifdef HAVE_FT2BUILD_H |
---|
187 | #include <ft2build.h> |
---|
188 | #include FT_FREETYPE_H |
---|
189 | #endif |
---|
190 | ]) |
---|
191 | |
---|
192 | CFLAGS="$savecflags" |
---|
193 | CPPFLAGS="$savecppflags" |
---|
194 | |
---|
195 | # Use all available features under glibc, and disable accidental use of |
---|
196 | # deprecated functionality. |
---|
197 | AC_EGREP_CPP(glibc, |
---|
198 | [ |
---|
199 | #include <stdio.h> |
---|
200 | #ifdef __GLIBC__ |
---|
201 | glibc |
---|
202 | #endif |
---|
203 | ], |
---|
204 | AC_DEFINE(_GNU_SOURCE,1,[Use all glibc features.])) |
---|
205 | AC_DEFINE(_XOPEN_SOURCE_EXTENDED,1,[Needed to get declarations for msg_control and msg_controllen on Solaris]) |
---|
206 | AC_DEFINE(_XOPEN_SOURCE,1,[Needed to get declarations for msg_control and msg_controllen on Solaris]) |
---|
207 | AC_DEFINE(__EXTENSIONS__,1,[Needed to get declarations for msg_control and msg_controllen on Solaris]) |
---|
208 | |
---|
209 | AC_ARG_ENABLE(deprecation,[AS_HELP_STRING(--enable-deprecation,prohibit VTE from using deprecated GLib/Pango/GDK/GTK+ features)],usedeprecation=$enableval,usedeprecation=no) |
---|
210 | if test "$usedeprecation" = yes ; then |
---|
211 | AC_DEFINE(G_DISABLE_DEPRECATED,1,[Disable deprecated GLib features.]) |
---|
212 | AC_DEFINE(GDK_DISABLE_DEPRECATED,1,[Disable deprecated GDK features.]) |
---|
213 | AC_DEFINE(GDK_PIXBUF_DISABLE_DEPRECATED,1,[Disable deprecated gdk-pixbuf features.]) |
---|
214 | AC_DEFINE(GTK_DISABLE_DEPRECATED,1,[Disable deprecated GTK+ features.]) |
---|
215 | AC_DEFINE(PANGO_DISABLE_DEPRECATED,1,[Disable deprecated Pango features.]) |
---|
216 | fi |
---|
217 | |
---|
218 | # Miscellaneous definitions. |
---|
219 | AC_DEFINE(VTE_UTF8_BPC,6,[Maximum number of bytes used per UTF-8 character.]) |
---|
220 | AC_DEFINE(VTE_INVALID_SOURCE,-1,[A number which can never be a valid source ID.]) |
---|
221 | AC_DEFINE_UNQUOTED(PACKAGE,"$PACKAGE",[Package name.]) |
---|
222 | |
---|
223 | # Check for headers. |
---|
224 | AC_CHECK_HEADERS(sys/select.h sys/termios.h sys/un.h stropts.h termios.h wchar.h) |
---|
225 | AC_HEADER_TIOCGWINSZ |
---|
226 | |
---|
227 | # Check for PTY handling functions. |
---|
228 | AC_CHECK_FUNCS(cfmakeraw getpgid getpt grantpt unlockpt ptsname ptsname_r) |
---|
229 | |
---|
230 | # Pull in the right libraries for various functions which might not be |
---|
231 | # bundled into an exploded libc. |
---|
232 | AC_CHECK_FUNC(socket,[have_socket=1],AC_CHECK_LIB(socket,socket,[have_socket=1; LIBS="$LIBS -lsocket"])) |
---|
233 | AC_CHECK_FUNC(socketpair,[have_socketpair=1],AC_CHECK_LIB(socket,socketpair,[have_socketpair=1; LIBS="$LIBS -lsocket"])) |
---|
234 | AC_CHECK_FUNC(recvmsg,[have_recvmsg=1],AC_CHECK_LIB(socket,recvmsg,[have_recvmsg=1; LIBS="$LIBS -lsocket -lnsl"])) |
---|
235 | if test x$have_socket = x1 ; then |
---|
236 | AC_DEFINE(HAVE_SOCKET,1,[Define if you have the socket function.]) |
---|
237 | fi |
---|
238 | if test x$have_socketpair = x1 ; then |
---|
239 | AC_DEFINE(HAVE_SOCKETPAIR,1,[Define if you have the socketpair function.]) |
---|
240 | fi |
---|
241 | if test x$have_recvmsg = x1 ; then |
---|
242 | AC_DEFINE(HAVE_RECVMSG,1,[Define if you have the recvmsg function.]) |
---|
243 | fi |
---|
244 | AC_CHECK_FUNC(floor,,AC_CHECK_LIB(m,floor,LIBS=["$LIBS -lm"])) |
---|
245 | |
---|
246 | # Look for ncurses or curses or termcap. |
---|
247 | AC_CHECK_HEADER(ncurses.h,[AC_CHECK_HEADER(term.h,[AC_CHECK_LIB(ncurses,tgetent,[LIBS="-lncurses $LIBS";AC_DEFINE(HAVE_NCURSES,1,[Define if you have ncurses.h and libncurses])])])]) |
---|
248 | if test x$ac_cv_lib_ncurses_tgetent != xyes ; then |
---|
249 | AC_CHECK_HEADER(curses.h,[AC_CHECK_HEADER(term.h,[AC_CHECK_LIB(curses,tgetent,[LIBS="-lcurses $LIBS";AC_DEFINE(HAVE_CURSES,1,[Define if you have curses.h and libcurses])])])]) |
---|
250 | if test x$ac_cv_lib_curses_tgetent != xyes ; then |
---|
251 | AC_CHECK_HEADER(termcap.h,[AC_CHECK_LIB(termcap,tgetent,[LIBS="-ltermcap $LIBS";AC_DEFINE(HAVE_TERMCAP,1,[Define if you have termcap.h and libtermcap])])]) |
---|
252 | if test x$ac_cv_header_termcap_h != xyes ; then |
---|
253 | AC_MSG_ERROR([You must have at least one of ncurses, curses, or libtermcap installed to build vte.]) |
---|
254 | fi |
---|
255 | fi |
---|
256 | fi |
---|
257 | |
---|
258 | # Save the names of these other libraries. |
---|
259 | OTHERCFLAGS="$X_CFLAGS" |
---|
260 | AC_SUBST(OTHERCFLAGS) |
---|
261 | OTHERLIBS="$LIBS" |
---|
262 | AC_SUBST(OTHERLIBS) |
---|
263 | |
---|
264 | # Enable debugging messages and additional run-time checks. |
---|
265 | AC_ARG_ENABLE(debugging,[AS_HELP_STRING(--enable-debugging,enable extra debugging checks and logging messages)],DEBUG=$enableval,DEBUG=no) |
---|
266 | if test x$DEBUG != x ; then |
---|
267 | if test x$DEBUG != xno ; then |
---|
268 | if test x$GCC = xyes ; then |
---|
269 | AC_CHECK_CC_OPT(-std=c99,vte_std_c99) |
---|
270 | CFLAGS="${CFLAGS} $vte_std_c99" |
---|
271 | CFLAGS="${CFLAGS} -Wall" |
---|
272 | CFLAGS="${CFLAGS} -Waggregate-return" |
---|
273 | CFLAGS="${CFLAGS} -Wcast-align" |
---|
274 | CFLAGS="${CFLAGS} -Wimplicit" |
---|
275 | CFLAGS="${CFLAGS} -Wmissing-declarations" |
---|
276 | CFLAGS="${CFLAGS} -Wmissing-prototypes" |
---|
277 | CFLAGS="${CFLAGS} -Wpointer-arith" |
---|
278 | CFLAGS="${CFLAGS} -Wstrict-prototypes" |
---|
279 | CFLAGS="${CFLAGS} -Wuninitialized" |
---|
280 | #CFLAGS="${CFLAGS} -Wsign-compare" |
---|
281 | #CFLAGS="${CFLAGS} -Wunused-value" |
---|
282 | fi |
---|
283 | VTE_DEBUG=1 |
---|
284 | fi |
---|
285 | fi |
---|
286 | if test x$VTE_DEBUG = x1 ; then |
---|
287 | AC_MSG_RESULT([enabling debug checks and messages]) |
---|
288 | AC_DEFINE(VTE_DEBUG,1,[Enable debugging messages.]) |
---|
289 | fi |
---|
290 | |
---|
291 | wcs_funcs_includes=" |
---|
292 | #ifdef HAVE_STRING_H |
---|
293 | # if !STDC_HEADERS && HAVE_MEMORY_H |
---|
294 | # include <memory.h> |
---|
295 | # endif |
---|
296 | # include <string.h> |
---|
297 | #else |
---|
298 | # ifdef HAVE_STRINGS_H |
---|
299 | # include <strings.h> |
---|
300 | # endif |
---|
301 | #endif |
---|
302 | #ifdef HAVE_WCHAR_H |
---|
303 | # include <wchar.h> |
---|
304 | #endif |
---|
305 | " |
---|
306 | |
---|
307 | AC_CHECK_TYPES(wint_t, AC_DEFINE(HAVE_WINT_T, , [Defined when the wint_t type is supported]), ,$wcs_funcs_includes) |
---|
308 | |
---|
309 | # Search for Python. |
---|
310 | BUILD_PYTHON=true |
---|
311 | AC_ARG_ENABLE(python, [AS_HELP_STRING(--enable-python,Build python bindings [default=yes])],[ |
---|
312 | if test x"$enableval" != xno ; then |
---|
313 | BUILD_PYTHON=true |
---|
314 | else |
---|
315 | BUILD_PYTHON=false |
---|
316 | fi],BUILD_PYTHON=true) |
---|
317 | |
---|
318 | if $BUILD_PYTHON ; then |
---|
319 | AM_PATH_PYTHON |
---|
320 | if test -z "$PYTHON" ; then |
---|
321 | BUILD_PYTHON=false |
---|
322 | fi |
---|
323 | fi |
---|
324 | |
---|
325 | if $BUILD_PYTHON ; then |
---|
326 | AC_MSG_CHECKING(for python >= 2.2) |
---|
327 | prog=" |
---|
328 | import sys, string |
---|
329 | minver = (2,2,0,'final',0) |
---|
330 | if sys.version_info < minver: |
---|
331 | sys.exit(1) |
---|
332 | sys.exit(0) |
---|
333 | " |
---|
334 | if $PYTHON -c "$prog" 1>&AC_FD_CC 2>&AC_FD_CC |
---|
335 | then |
---|
336 | AC_MSG_RESULT([okay]) |
---|
337 | else |
---|
338 | BUILD_PYTHON=false |
---|
339 | AC_MSG_RESULT([too old]) |
---|
340 | fi |
---|
341 | fi |
---|
342 | |
---|
343 | if $BUILD_PYTHON ; then |
---|
344 | AM_CHECK_PYTHON_HEADERS(,BUILD_PYTHON=false) |
---|
345 | fi |
---|
346 | |
---|
347 | if $BUILD_PYTHON ; then |
---|
348 | AC_MSG_CHECKING([for pygtk-2.0]) |
---|
349 | if pkg-config --exists pygtk-2.0 ; then |
---|
350 | AC_MSG_RESULT([found]) |
---|
351 | PKG_CHECK_MODULES(PYGTK,[pygtk-2.0]) |
---|
352 | PYGTK_DATADIR=`pkg-config --variable=datadir pygtk-2.0` |
---|
353 | AC_SUBST(PYGTK_DATADIR) |
---|
354 | else |
---|
355 | AC_MSG_RESULT([not found]) |
---|
356 | BUILD_PYTHON=false |
---|
357 | fi |
---|
358 | fi |
---|
359 | |
---|
360 | if ! $BUILD_PYTHON ; then |
---|
361 | AC_MSG_RESULT([Python bindings disabled.]) |
---|
362 | fi |
---|
363 | |
---|
364 | AC_SUBST(PYTHONREV) |
---|
365 | AC_SUBST(PYTHONMODULES) |
---|
366 | AM_CONDITIONAL(BUILD_PYTHON_MODULES, $BUILD_PYTHON) |
---|
367 | |
---|
368 | # If we can find libzvt on the system, set up to build a variant of "reflect" |
---|
369 | # which uses it. |
---|
370 | REFLECT_ZVT=false |
---|
371 | if pkg-config --exists libzvt-2.0 ; then |
---|
372 | REFLECT_ZVT=true |
---|
373 | ZVT_DEFS=-DHAVE_ZVT |
---|
374 | PKG_CHECK_MODULES(ZVT,[gtk+-2.0 libzvt-2.0]) |
---|
375 | fi |
---|
376 | AC_SUBST(ZVT_DEFS) |
---|
377 | AM_CONDITIONAL(REFLECT_USE_ZVT, $REFLECT_ZVT) |
---|
378 | |
---|
379 | mylibdir=`eval echo $libdir` |
---|
380 | mylibexecdir=`eval echo $libexecdir` |
---|
381 | mydatadir=`eval echo $datadir` |
---|
382 | if test x$exec_prefix = xNONE ; then |
---|
383 | if test x$prefix = xNONE ; then |
---|
384 | mylibdir=` echo $mylibdir | sed s,NONE,$ac_default_prefix,g` |
---|
385 | mylibexecdir=` echo $mylibexecdir | sed s,NONE,$ac_default_prefix,g` |
---|
386 | else |
---|
387 | mylibdir=` echo $mylibdir | sed s,NONE,$prefix,g` |
---|
388 | mylibexecdir=` echo $mylibexecdir | sed s,NONE,$prefix,g` |
---|
389 | fi |
---|
390 | fi |
---|
391 | if test x$prefix = xNONE ; then |
---|
392 | mydatadir=`echo $mydatadir | sed s,NONE,$ac_default_prefix,g` |
---|
393 | fi |
---|
394 | AC_DEFINE_UNQUOTED(PKGLIBDIR,"$mylibdir/$PACKAGE", |
---|
395 | [The location where package-specific helpers can be found.]) |
---|
396 | AC_DEFINE_UNQUOTED(LIBEXECDIR,"$mylibexecdir", |
---|
397 | [The location where package-specific helpers can be found.]) |
---|
398 | AC_DEFINE_UNQUOTED(DATADIR,"$mydatadir", |
---|
399 | [The location where arch-independent package-specific data can be found.]) |
---|
400 | AC_DEFINE_UNQUOTED(LOCALEDIR,"$mydatadir/locale", |
---|
401 | [The location where locale data can be found.]) |
---|
402 | |
---|
403 | GETTEXT_PACKAGE=vte |
---|
404 | AC_SUBST(GETTEXT_PACKAGE) |
---|
405 | |
---|
406 | AC_ARG_ENABLE(gnome-pty-helper, [AS_HELP_STRING(--enable-gnome-pty-helper,Build a setuid helper for opening ptys [default=yes])], enable_gnome_pty_helper="$enableval", enable_gnome_pty_helper=yes) |
---|
407 | if test "$enable_gnome_pty_helper" != no; then |
---|
408 | AC_DEFINE(VTE_USE_GNOME_PTY_HELPER,1,[Define if you intend to use gnome-pty-helper.]) |
---|
409 | AC_CONFIG_SUBDIRS(gnome-pty-helper) |
---|
410 | fi |
---|
411 | AM_CONDITIONAL(BUILD_GNOME_PTY_HELPER,[test "$enable_gnome_pty_helper" != no]) |
---|
412 | |
---|
413 | ################################################################################ |
---|
414 | |
---|
415 | # This is a check for gtk-doc which you can insert into your configure.in. |
---|
416 | # You shouldn't need to change it at all. |
---|
417 | |
---|
418 | ################################################## |
---|
419 | # Check for gtk-doc. |
---|
420 | ################################################## |
---|
421 | |
---|
422 | AC_ARG_WITH(html-dir, [AS_HELP_STRING(--with-html-dir=PATH,path to installed docs)]) |
---|
423 | |
---|
424 | if test "x$with_html_dir" = "x" ; then |
---|
425 | HTML_DIR='${datadir}/gtk-doc/html' |
---|
426 | else |
---|
427 | HTML_DIR=$with_html_dir |
---|
428 | fi |
---|
429 | |
---|
430 | AC_SUBST(HTML_DIR) |
---|
431 | |
---|
432 | AC_CHECK_PROG(GTKDOC, gtkdoc-mkdb, true, false) |
---|
433 | |
---|
434 | gtk_doc_min_version=0.6 |
---|
435 | if $GTKDOC ; then |
---|
436 | gtk_doc_version=`gtkdoc-mkdb --version` |
---|
437 | AC_MSG_CHECKING([gtk-doc version ($gtk_doc_version) >= $gtk_doc_min_version]) |
---|
438 | |
---|
439 | IFS="${IFS= }"; vte_save_IFS="$IFS"; IFS="." |
---|
440 | set $gtk_doc_version |
---|
441 | for min in $gtk_doc_min_version ; do |
---|
442 | cur=$1; shift |
---|
443 | if test -z $min ; then break; fi |
---|
444 | if test -z $cur ; then GTKDOC=false; break; fi |
---|
445 | if test $cur -gt $min ; then break ; fi |
---|
446 | if test $cur -lt $min ; then GTKDOC=false; break ; fi |
---|
447 | done |
---|
448 | IFS="$vte_save_IFS" |
---|
449 | |
---|
450 | if $GTKDOC ; then |
---|
451 | AC_MSG_RESULT(yes) |
---|
452 | else |
---|
453 | AC_MSG_RESULT(no) |
---|
454 | fi |
---|
455 | fi |
---|
456 | |
---|
457 | dnl Let people disable the gtk-doc stuff. |
---|
458 | AC_ARG_ENABLE(gtk-doc, [AS_HELP_STRING(--enable-gtk-doc,Use gtk-doc to build documentation [default=auto])], enable_gtk_doc="$enableval", enable_gtk_doc=auto) |
---|
459 | |
---|
460 | if test x$enable_gtk_doc = xauto ; then |
---|
461 | if test x$GTKDOC = xtrue ; then |
---|
462 | enable_gtk_doc=yes |
---|
463 | else |
---|
464 | enable_gtk_doc=no |
---|
465 | fi |
---|
466 | fi |
---|
467 | |
---|
468 | AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes) |
---|
469 | |
---|
470 | ################################################################################ |
---|
471 | |
---|
472 | AM_CONFIG_HEADER(config.h) |
---|
473 | |
---|
474 | AC_OUTPUT([ |
---|
475 | Makefile |
---|
476 | src/Makefile |
---|
477 | termcaps/Makefile |
---|
478 | python/Makefile |
---|
479 | po/Makefile.in |
---|
480 | doc/Makefile |
---|
481 | doc/openi18n/Makefile |
---|
482 | doc/reference/Makefile |
---|
483 | vte.pc |
---|
484 | vte-uninstalled.pc |
---|
485 | ]) |
---|