build: handle AM_PROG_AR not present in autoconf 1.11
[platform/upstream/kmscon.git] / configure.ac
1 #
2 # Kmscon - build configuration script
3 # Copyright (c) 2012 David Herrmann <dh.herrmann@googlemail.com>
4 #
5
6 AC_PREREQ(2.68)
7
8 AC_INIT([kmscon], [5])
9 AC_SUBST(PACKAGE_URL, [https://github.com/dvdhrm/kmscon])
10 AC_CONFIG_SRCDIR([src/main.c])
11 AC_CONFIG_AUX_DIR([build-aux])
12 AC_CONFIG_MACRO_DIR([m4])
13 AC_CONFIG_HEADER(config.h)
14
15 AM_INIT_AUTOMAKE([foreign 1.11 subdir-objects dist-bzip2 no-dist-gzip tar-pax -Wall -Werror])
16 AM_SILENT_RULES([yes])
17
18 #
19 # Don't add a default "-g -O2" if CFLAGS wasn't specified. For debugging it is
20 # often more convenient to have "-g -O0". You can still override it by
21 # explicitely setting it on the command line.
22 #
23
24 : ${CFLAGS=""}
25
26 AC_USE_SYSTEM_EXTENSIONS
27 AC_PROG_CC
28 AC_PROG_CC_C99
29 AM_PROG_CC_C_O
30 m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
31
32 LT_PREREQ(2.2)
33 LT_INIT
34
35 #
36 # pkg-config dependencies
37 # This unconditionally checks for all dependencies even if they are disabled. We
38 # later look whether all required depedencies are met and finish the
39 # configuration. We group similar packages into one logical group here to avoid
40 # having variables for each single library.
41 # This, however, makes ./configure output very unintuitive error messages if a
42 # package is not found so we must make sure we print more verbose messages
43 # ourself.
44 #
45
46 PKG_CHECK_MODULES([SYSTEMD], [libsystemd-login],
47                   [have_systemd=yes], [have_systemd=no])
48
49 PKG_CHECK_MODULES([UDEV], [libudev],
50                   [have_udev=yes], [have_udev=no])
51
52 PKG_CHECK_MODULES([DBUS], [dbus-1],
53                   [have_dbus=yes], [have_dbus=no])
54
55 PKG_CHECK_MODULES([DRM], [libdrm],
56                   [have_drm=yes], [have_drm=no])
57
58 PKG_CHECK_MODULES([GBM], [gbm],
59                   [have_gbm=yes], [have_gbm=no])
60
61 PKG_CHECK_MODULES([EGL], [egl],
62                   [have_egl=yes], [have_egl=no])
63
64 PKG_CHECK_MODULES([GLES2], [glesv2],
65                   [have_gles2=yes], [have_gles2=no])
66
67 PKG_CHECK_MODULES([XKBCOMMON], [xkbcommon],
68                   [have_xkbcommon=yes], [have_xkbcommon=no])
69
70 PKG_CHECK_MODULES([FREETYPE2], [freetype2 fontconfig],
71                   [have_freetype2=yes], [have_freetype2=no])
72
73 PKG_CHECK_MODULES([PANGO], [pango pangoft2],
74                   [have_pango=yes], [have_pango=no])
75
76 PKG_CHECK_MODULES([WAYLAND], [wayland-client wayland-server wayland-cursor],
77                   [have_wayland=yes], [have_wayland=no])
78
79 #
80 # Parse arguments for applications
81 # Parse all command-line arguments that enable or disable build of applications.
82 # This allows us to compute which dependencies we need.
83 #
84
85 AC_MSG_CHECKING([whether to compile eloop])
86 AC_ARG_ENABLE([eloop],
87               [AS_HELP_STRING([--enable-eloop],
88                               [build eloop library])])
89 AC_MSG_RESULT([ok])
90
91 AC_MSG_CHECKING([whether to compile TSM])
92 AC_ARG_ENABLE([tsm],
93               [AS_HELP_STRING([--enable-tsm],
94                               [build tsm library])])
95 AC_MSG_RESULT([ok])
96
97 AC_MSG_CHECKING([whether to compile uterm])
98 AC_ARG_ENABLE([uterm],
99               [AS_HELP_STRING([--enable-uterm],
100                               [build uterm library])])
101 AC_MSG_RESULT([ok])
102
103 AC_MSG_CHECKING([whether to compile kmscon])
104 AC_ARG_ENABLE([kmscon],
105               [AS_HELP_STRING([--disable-kmscon],
106                               [do not build kmscon])])
107 AC_MSG_RESULT([ok])
108
109 AC_MSG_CHECKING([whether to build wlterm])
110 AC_ARG_ENABLE([wlterm],
111               [AS_HELP_STRING([--enable-wlterm],
112                               [build wlterm])])
113 AC_MSG_RESULT([ok])
114
115 #
116 # Parse depedency arguments
117 # This parses all command-line arguments to check for which dependencies should
118 # be used and how the applications should be built.
119 #
120
121 AC_MSG_CHECKING([whether to use systemd for multi-seat support])
122 AC_ARG_ENABLE([systemd],
123               [AS_HELP_STRING([--enable-systemd],
124                               [enable multi-seat support with systemd])])
125 AC_MSG_RESULT([ok])
126
127 AC_MSG_CHECKING([whether to use udev for device hotplug support])
128 AC_ARG_ENABLE([udev],
129               [AS_HELP_STRING([--enable-udev],
130                               [enable device hotplug support with udev])])
131 AC_MSG_RESULT([ok])
132
133 AC_MSG_CHECKING([whether to use dbus for IPC])
134 AC_ARG_ENABLE([dbus],
135               [AS_HELP_STRING([--enable-dbus],
136                               [enable dbus IPC])])
137 AC_MSG_RESULT([ok])
138
139 AC_MSG_CHECKING([whether to use uterm fbdev video backend])
140 AC_ARG_ENABLE([fbdev],
141               [AS_HELP_STRING([--enable-fbdev],
142                               [enable uterm fbdev video backend])])
143 AC_MSG_RESULT([ok])
144
145 AC_MSG_CHECKING([whether to use uterm drm video backend])
146 AC_ARG_ENABLE([drm],
147               [AS_HELP_STRING([--enable-drm],
148                               [enable uterm drm video backend])])
149 AC_MSG_RESULT([ok])
150
151 AC_MSG_CHECKING([whether to provide OpenGLES2 support])
152 AC_ARG_ENABLE([gles2],
153               [AS_HELP_STRING([--enable-gles2],
154                               [provide uterm OpenGLES2 support])])
155 AC_MSG_RESULT([ok])
156
157 AC_MSG_CHECKING([whether to use static unifont backend])
158 AC_ARG_ENABLE([unifont],
159               [AS_HELP_STRING([--enable-unifont],
160                               [enable static unifont font backend (GPL)])])
161 AC_MSG_RESULT([ok])
162
163 AC_MSG_CHECKING([whether to use static 8x16 font backend])
164 AC_ARG_ENABLE([f8x16],
165               [AS_HELP_STRING([--disable-f8x16],
166                               [disable static 8x16 font backend])])
167 AC_MSG_RESULT([ok])
168
169 AC_MSG_CHECKING([whether to use freetype2 font backend])
170 AC_ARG_ENABLE([freetype2],
171               [AS_HELP_STRING([--disable-freetype2],
172                               [disable freetype2 font backend])])
173 AC_MSG_RESULT([ok])
174
175 AC_MSG_CHECKING([whether to use pango font backend])
176 AC_ARG_ENABLE([pango],
177               [AS_HELP_STRING([--disable-pango],
178                               [disable pango font backend])])
179 AC_MSG_RESULT([ok])
180
181 AC_MSG_CHECKING([whether to use bblit rendering backend])
182 AC_ARG_ENABLE([bblit],
183               [AS_HELP_STRING([--disable-bblit],
184                               [disable bblit rendering backend])])
185 AC_MSG_RESULT([ok])
186
187 AC_MSG_CHECKING([whether to use bbulk rendering backend])
188 AC_ARG_ENABLE([bbulk],
189               [AS_HELP_STRING([--disable-bbulk],
190                               [disable bbulk rendering backend])])
191 AC_MSG_RESULT([ok])
192
193 #
194 # Parse miscellaneous arguments
195 # These don't belong into the categories above for several reason so they are
196 # handled specially.
197 # They configure compiler options and similar.
198 #
199
200 AC_MSG_CHECKING([whether to build with debugging on])
201 AC_ARG_ENABLE([debug],
202               [AS_HELP_STRING([--enable-debug],
203                               [whether to build with debugging on])])
204 AC_MSG_RESULT([ok])
205
206 AC_MSG_CHECKING([whether to disable code optimizations])
207 AC_ARG_ENABLE([optimizations],
208               [AS_HELP_STRING([--disable-optimizations],
209                               [whether to disable code optimizations])])
210 AC_MSG_RESULT([ok])
211
212 #
213 # Debug mode and code optimizations
214 # In debug mode we compile with -g and enable several debug-messages and flags.
215 # With optimizations (default), we add -O2 to compile-flags.
216 #
217
218 debug_enabled=no
219 if test x$enable_debug = xyes ; then
220         debug_enabled=yes
221 fi
222
223 optimizations_enabled=no
224 if test ! x$enable_optimizations = xno ; then
225         optimizations_enabled=yes
226 fi
227
228 if test x$debug_enabled = xyes ; then
229         AC_DEFINE([BUILD_ENABLE_DEBUG], [1],
230                   [Enable debug mode])
231 else
232         AC_DEFINE([NDEBUG], [1], [No Debug])
233 fi
234
235 AM_CONDITIONAL([BUILD_ENABLE_DEBUG],
236                [test x$debug_enabled = xyes])
237 AM_CONDITIONAL([BUILD_ENABLE_OPTIMIZATIONS],
238                [test x$optimizations_enabled = xyes])
239
240 # check for _Static_assert
241 AC_MSG_CHECKING([whether _Static_assert() is supported])
242 AC_LANG([C])
243 have_static_assert=yes
244 AC_COMPILE_IFELSE([AC_LANG_SOURCE([[_Static_assert(1, "What?");]])],
245                   [AC_DEFINE([BUILD_HAVE_STATIC_ASSERT],
246                              [1],
247                              [Define to 1 if _Static_assert() is supported])],
248                   [have_static_assert=no])
249 AC_MSG_RESULT([$have_static_assert])
250
251 #
252 # Main applications
253 # This checks which applications to build so we can optionally disable unused
254 # dependencies below.
255 #
256 # Dependency Calculations
257 # The first thing we do is checking which applications to build. Then we
258 # forcibly enable all libraries that are needed by these and then we forcibly
259 # enable all other source-code dependecies.
260 #
261 # The "enable_XY" flag is user input that is set to "yes" if they enabled it
262 # explicitly, "no" if they disabled it explicitly or "" (empty) if they did
263 # not specify it explicitly. In the latter case we enable it if all dependencies
264 # are met, otherwise, we disable it. This does not work for applications,
265 # though. If an application is not specified explicitly by the user, then we
266 # force the default value.
267 # An application also forces all _hard_ dependencies to "yes" and so fails if
268 # they cannot be met.
269 #
270
271 kmscon_enabled=no
272 if test ! x$enable_kmscon = xno ; then
273         kmscon_enabled=yes
274         enable_eloop=yes
275         enable_tsm=yes
276         enable_uterm=yes
277 fi
278
279 AM_CONDITIONAL([BUILD_ENABLE_KMSCON],
280                [test x$kmscon_enabled = xyes])
281
282 wlterm_enabled=no
283 if test x$enable_wlterm = xyes ; then
284         wlterm_enabled=yes
285         enable_eloop=yes
286         enable_tsm=yes
287         enable_wayland=yes
288 fi
289
290 AM_CONDITIONAL([BUILD_ENABLE_WLTERM],
291                [test x$wlterm_enabled = xyes])
292
293 uterm_enabled=no
294 if test x$enable_uterm = xyes ; then
295         uterm_enabled=yes
296         eloop_enabled=yes
297 fi
298
299 AM_CONDITIONAL([BUILD_ENABLE_UTERM],
300                [test x$uterm_enabled = xyes])
301
302 eloop_enabled=no
303 if test x$enable_eloop = xyes ; then
304         eloop_enabled=yes
305 fi
306
307 AM_CONDITIONAL([BUILD_ENABLE_ELOOP],
308                [test x$eloop_enabled = xyes])
309
310 tsm_enabled=no
311 if test x$enable_tsm = xyes ; then
312         tsm_enabled=yes
313 fi
314
315 AM_CONDITIONAL([BUILD_ENABLE_TSM],
316                [test x$tsm_enabled = xyes])
317
318 #
319 # Systemd dependency
320 # We can optionally use systemd for multi-seat support. If systemd is not
321 # available or the system was not started with systemd, we simply fall back to
322 # single-seat mode.
323 #
324
325 systemd_enabled=no
326 if test ! x$enable_systemd = xno ; then
327         if test x$have_systemd = xyes ; then
328                 systemd_enabled=yes
329         elif test x$enable_systemd = xyes ; then
330                 AC_ERROR([systemd libraries not found for multi-seat support])
331         fi
332 fi
333
334 if test x$systemd_enabled = xyes ; then
335         AC_DEFINE([BUILD_ENABLE_SYSTEMD], [1],
336                   [Use systemd for multi-seat support])
337 else
338         SYSTEMD_CFLAGS=""
339         SYSTEMD_LIBS=""
340 fi
341
342 #
343 # Udev dependency
344 # For hotplugging support we need udev to notify us about system events. If udev
345 # is not available, we simply fall back to static mode. Periodic scanning is
346 # also supported.
347 #
348
349 udev_enabled=no
350 if test ! x$enable_udev = xno ; then
351         if test x$have_udev = xyes ; then
352                 udev_enabled=yes
353         elif test x$enable_udev = xyes ; then
354                 AC_ERROR([udev libraries not found for device hotplug support])
355         fi
356 fi
357
358 if test x$udev_enabled = xyes ; then
359         AC_DEFINE([BUILD_ENABLE_UDEV], [1],
360                   [Use udev for device hotplug support])
361 else
362         UDEV_CFLAGS=""
363         UDEV_LIBS=""
364 fi
365
366 #
367 # DBus dependency
368 # For IPC mechanisms we use DBus. Especially multi-seat enabled multi-session
369 # capable applications need DBus to manage application and terminal switching.
370 #
371
372 dbus_enabled=no
373 if test x$enable_dbus = xyes ; then
374         if test x$have_dbus = xyes ; then
375                 dbus_enabled=yes
376         elif test x$enable_dbus = xyes; then
377                 AC_ERROR([dbus libraries not found])
378         fi
379 fi
380
381 if test x$dbus_enabled = xyes; then
382         AC_DEFINE([BUILD_ENABLE_DBUS], [1],
383                   [Use dbus for IPC])
384 else
385         DBUS_CFLAGS=""
386         DBUS_LIBS=""
387 fi
388
389 AM_CONDITIONAL([BUILD_ENABLE_DBUS], [test x$dbus_enabled = xyes])
390
391 #
392 # Uterm fbdev backend
393 # This checks whether the fbdev backend was requested and enables it then. There
394 # are no special dependencies for it except the kernel headers.
395 # TODO: check for kernel headers here
396 #
397
398 fbdev_enabled=no
399 if test ! x$enable_fbdev = xno ; then
400         fbdev_enabled=yes
401 fi
402
403 if test x$fbdev_enabled = xyes ; then
404         AC_DEFINE([BUILD_ENABLE_FBDEV], [1],
405                   [Use uterm fbdev video backend])
406 fi
407
408 AM_CONDITIONAL([BUILD_ENABLE_FBDEV], [test x$fbdev_enabled = xyes])
409
410 #
411 # Uterm drm backend
412 # This checks whether libdrm is available and some combination of libgbm, egl
413 # and gl or glesv2. If it is not available, then the drm backend is simply not
414 # built.
415 #
416
417 dumb_enabled=no
418 drm_enabled=no
419 gles2_enabled=no
420 if test ! x$enable_drm = xno ; then
421         if test x$have_drm = xyes ; then
422                 dumb_enabled=yes
423         fi
424
425         if test ! x$enable_gles2 = xno ; then
426                 if test x$have_drm = xyes -a x$have_gbm = xyes -a x$have_egl = xyes ; then
427                         if test x$have_gles2 = xyes ; then
428                                 drm_enabled=yes
429                                 gles2_enabled=yes
430                         fi
431                 fi
432         fi
433
434         if test x$enable_drm = xyes -a x$dumb_enabled = xno ; then
435                 AC_ERROR([drm library not found for uterm dumb drm backend])
436         fi
437
438         if test x$enable_gles2 = xyes -a x$drm_enabled = xno ; then
439                 AC_ERROR([drm, gbm, egl, gl or gles2 libraries not found for uterm drm backend])
440         fi
441 fi
442
443 if test x$dumb_enabled = xyes ; then
444         AC_DEFINE([BUILD_ENABLE_DUMB], [1],
445                   [Use uterm dumb drm video backend])
446
447         if test x$drm_enabled = xyes ; then
448                 AC_DEFINE([BUILD_ENABLE_DRM], [1],
449                           [Use uterm DRM video backend])
450         else
451                 GBM_CFLAGS=""
452                 GBM_LIBS=""
453                 EGL_CFLAGS=""
454                 EGL_LIBS=""
455         fi
456 else
457         DRM_CFLAGS=""
458         DRM_LIBS=""
459         GBM_CFLAGS=""
460         GBM_LIBS=""
461         EGL_CFLAGS=""
462         EGL_LIBS=""
463 fi
464
465 if test x$gles2_enabled = xyes ; then
466         AC_DEFINE([BUILD_ENABLE_GLES2], [1],
467                   [Use OpenGLESv2 as drawing backend])
468 else
469         GLES2_CFLAGS=""
470         GLES2_LIBS=""
471 fi
472
473 AM_CONDITIONAL([BUILD_ENABLE_DUMB], [test x$dumb_enabled = xyes])
474 AM_CONDITIONAL([BUILD_ENABLE_DRM], [test x$drm_enabled = xyes])
475 AM_CONDITIONAL([BUILD_ENABLE_GLES2], [test x$gles2_enabled = xyes])
476
477 # check for gbm_bo_get_stride() function, otherwise gbm_bo_get_pitch() is used
478 if test x$have_gbm = xyes ; then
479         save_CFLAGS="$CFLAGS"
480         save_LIBS="$LIBS"
481         save_LDFLAGS="$LDFLAGS"
482         CFLAGS="$DRM_CFLAGS $GBM_CFLAGS"
483         LIBS="$DRM_LIBS $GBM_LIBS"
484         LDFLAGS=""
485         AC_CHECK_LIB([gbm],
486                      [gbm_bo_get_stride],
487                      [AC_DEFINE([BUILD_HAVE_GBM_BO_GET_STRIDE],
488                                 [1],
489                                 [Define to 1 if your libgbm provides gbm_bo_get_stride])])
490         CFLAGS="$save_CFLAGS"
491         LIBS="$save_LIBS"
492         LDFLAGS="$save_LDFLAGS"
493 fi
494
495 #
496 # xkbcommon keyboard backend
497 # This checks for the xkbcommon library for keyboard handling in uterm. We
498 # require this library as there is no other way to handle keyboard input
499 # properly.
500 #
501
502 xkbcommon_enabled=no
503 if test ! x$have_xkbcommon = xno ; then
504         xkbcommon_enabled=yes
505 else
506         AC_ERROR([xkbcommon not found for keyboard backend])
507 fi
508
509 #
510 # Font backends
511 # This checks for the unifont, 8x16, freetype2 and pango font backends and
512 # enables them if requested and available.
513 #
514 # Please note that the Unifont-data is GPL'ed and we compile this statically
515 # into our application. I do not consider this a "derivative" but a lawyer may
516 # disagree. So please make sure you enable this only if you use the GPL as
517 # license for kmscon.
518 #
519
520 unifont_enabled=no
521 if test x$enable_unifont = xyes ; then
522         unifont_enabled=yes
523 fi
524
525 if test x$unifont_enabled = xyes ; then
526         AC_DEFINE([BUILD_ENABLE_UNIFONT], [1],
527                   [Use static unifont backend])
528 fi
529
530 AM_CONDITIONAL([BUILD_ENABLE_UNIFONT], [test x$unifont_enabled = xyes])
531
532 f8x16_enabled=no
533 if test ! x$enable_f8x16 = xno ; then
534         f8x16_enabled=yes
535 fi
536
537 if test x$f8x16_enabled = xyes ; then
538         AC_DEFINE([BUILD_ENABLE_8X16], [1],
539                   [Use static 8x16 font backend])
540 fi
541
542 AM_CONDITIONAL([BUILD_ENABLE_8X16], [test x$f8x16_enabled = xyes])
543
544 freetype2_enabled=no
545 if test ! x$enable_freetype2 = xno ; then
546         if test x$have_freetype2 = xyes ; then
547                 freetype2_enabled=yes
548         elif test x$enable_freetype2 = xyes ; then
549                 AC_ERROR([freetype2/fontconfig not found for freetype2 backend])
550         fi
551 fi
552
553 if test x$freetype2_enabled = xyes ; then
554         AC_DEFINE([BUILD_ENABLE_FREETYPE2], [1],
555                   [Use freetype2 as font backend])
556 else
557         FREETYPE2_CFLAGS=""
558         FREETYPE2_LIBS=""
559 fi
560
561 AM_CONDITIONAL([BUILD_ENABLE_FREETYPE2], [test x$freetype2_enabled = xyes])
562
563 pango_enabled=no
564 if test ! x$enable_pango = xno ; then
565         if test x$have_pango = xyes ; then
566                 pango_enabled=yes
567         elif test x$enable_pango = xyes ; then
568                 AC_ERROR([pango not found for pango font backend])
569         fi
570 fi
571
572 if test x$pango_enabled = xyes ; then
573         AC_DEFINE([BUILD_ENABLE_PANGO], [1],
574                   [Use pango as font backend])
575 else
576         PANGO_CFLAGS=""
577         PANGO_LIBS=""
578 fi
579
580 AM_CONDITIONAL([BUILD_ENABLE_PANGO], [test x$pango_enabled = xyes])
581
582 #
583 # BBlit Rendering backend
584 #
585
586 bblit_enabled=no
587 if test ! x$enable_bblit = xno ; then
588         bblit_enabled=yes
589 fi
590
591 if test x$bblit_enabled = xyes ; then
592         AC_DEFINE([BUILD_ENABLE_BBLIT], [1],
593                   [Use bblit rendering backend])
594 fi
595
596 AM_CONDITIONAL([BUILD_ENABLE_BBLIT], [test x$bblit_enabled = xyes])
597
598 #
599 # BBulk Rendering backend
600 #
601
602 bbulk_enabled=no
603 if test ! x$enable_bbulk = xno ; then
604         bbulk_enabled=yes
605 fi
606
607 if test x$bbulk_enabled = xyes ; then
608         AC_DEFINE([BUILD_ENABLE_BBULK], [1],
609                   [Use bbulk rendering backend])
610 fi
611
612 AM_CONDITIONAL([BUILD_ENABLE_BBULK], [test x$bbulk_enabled = xyes])
613
614 #
615 # OpenGL Texture rendering backend
616 # This is not really an option but automatically enabled if OpenGLES2 support
617 # was selected.
618 #
619
620 gltex_enabled=no
621 if test x$gles2_enabled = xyes ; then
622         gltex_enabled=yes
623 fi
624
625 #
626 # Wayland
627 # This checks whether the wayland libraries are needed and available.
628 #
629
630 wayland_enabled=no
631 if test ! x$enable_wayland = xno ; then
632         if test x$have_wayland = xyes ; then
633                 wayland_enabled=yes
634         elif test x$enable_wayland = xyes ; then
635                 AC_ERROR([wayland libraries not found])
636         fi
637 fi
638
639 if test x$wayland_enabled = xyes ; then
640         AC_DEFINE([BUILD_ENABLE_WAYLAND], [1],
641                   [Enable wayland backends])
642 else
643         WAYLAND_CFLAGS=""
644         WAYLAND_LIBS=""
645 fi
646
647 #
648 # Makefile vars
649 # After everything is configured, we correctly substitute the values for the
650 # makefiles.
651 #
652
653 AC_SUBST(SYSTEMD_CFLAGS)
654 AC_SUBST(SYSTEMD_LIBS)
655 AC_SUBST(DBUS_CFLAGS)
656 AC_SUBST(DBUS_LIBS)
657 AC_SUBST(DRM_CFLAGS)
658 AC_SUBST(DRM_LIBS)
659 AC_SUBST(EGL_CFLAGS)
660 AC_SUBST(EGL_LIBS)
661 AC_SUBST(GBM_CFLAGS)
662 AC_SUBST(GBM_LIBS)
663 AC_SUBST(GLES2_CFLAGS)
664 AC_SUBST(GLES2_LIBS)
665 AC_SUBST(UDEV_CFLAGS)
666 AC_SUBST(UDEV_LIBS)
667 AC_SUBST(XKBCOMMON_CFLAGS)
668 AC_SUBST(XKBCOMMON_LIBS)
669 AC_SUBST(FREETYPE2_CFLAGS)
670 AC_SUBST(FREETYPE2_LIBS)
671 AC_SUBST(PANGO_CFLAGS)
672 AC_SUBST(PANGO_LIBS)
673 AC_SUBST(WAYLAND_CFLAGS)
674 AC_SUBST(WAYLAND_LIBS)
675
676 AC_CONFIG_FILES([Makefile libeloop.pc libtsm.pc libuterm.pc])
677 AC_OUTPUT
678
679 #
680 # Configuration output
681 # Show configuration to the user so they can check whether everything was
682 # configured as expected.
683 #
684
685 AC_MSG_NOTICE([Build configuration:
686
687   Applications and libraries:
688                kmscon: $kmscon_enabled
689                wlterm: $wlterm_enabled
690                 uterm: $uterm_enabled
691                 eloop: $eloop_enabled
692                   tsm: $tsm_enabled
693
694   Miscellaneous options:
695                 debug: $debug_enabled
696         optimizations: $optimizations_enabled
697
698   Optional dependencies:
699               systemd: $systemd_enabled
700                  udev: $udev_enabled
701                  dbus: $dbus_enabled
702             xkbcommon: $xkbcommon_enabled
703
704   libuterm video backends:
705                 fbdev: $fbdev_enabled
706              dumb drm: $dumb_enabled
707                   drm: $drm_enabled
708             OpenGLES2: $gles2_enabled
709
710   font backends:
711               unifont: $unifont_enabled
712                  8x16: $f8x16_enabled
713             freetype2: $freetype2_enabled
714                 pango: $pango_enabled
715
716   rendering backends:
717                 bblit: $bblit_enabled
718                 bbulk: $bbulk_enabled
719                 gltex: $gltex_enabled
720
721         Run "make" to start compilation process])