1 | dnl# |
1 | dnl# |
2 | dnl# Process this file with autoconf to produce a configure script. |
2 | dnl# Process this file with autoconf to produce a configure script. |
3 | dnl# |
3 | dnl# |
4 | |
4 | |
5 | AC_INIT |
5 | AC_INIT |
6 | AC_PREREQ(2.50) |
6 | AC_PREREQ(2.71) |
7 | AC_CONFIG_SRCDIR([src/feature.h]) |
7 | AC_CONFIG_SRCDIR([src/feature.h]) |
8 | AC_CONFIG_HEADER(config.h:config.h.in) |
8 | AC_CONFIG_HEADERS(config.h:config.h.in) |
9 | |
9 | |
10 | AC_CANONICAL_HOST |
10 | AC_CANONICAL_HOST |
11 | |
11 | |
12 | dnl RXVT version |
12 | dnl RXVT version |
13 | changequote(, )dnl |
13 | changequote(, )dnl |
… | |
… | |
26 | dnl# Checks for programs. |
26 | dnl# Checks for programs. |
27 | AC_PROG_CC |
27 | AC_PROG_CC |
28 | AC_PROG_CXX |
28 | AC_PROG_CXX |
29 | AC_PROG_INSTALL |
29 | AC_PROG_INSTALL |
30 | |
30 | |
31 | AC_AIX |
31 | AC_USE_SYSTEM_EXTENSIONS |
32 | AC_GNU_SOURCE |
|
|
33 | AC_ISC_POSIX |
|
|
34 | AC_LANG(C++) |
32 | AC_LANG(C++) |
|
|
33 | |
|
|
34 | if test "$ac_prog_cxx_stdcxx" != cxx11; then |
|
|
35 | AC_MSG_ERROR([the compiler does not support C++11]) |
|
|
36 | fi |
35 | |
37 | |
36 | LINKER="$CXX" |
38 | LINKER="$CXX" |
37 | dnl check whether we can link with gcc -lsupc++ |
39 | dnl check whether we can link with gcc -lsupc++ |
38 | if test x$GCC = xyes && test x$GXX = xyes; then |
40 | if test x$GCC = xyes && test x$GXX = xyes; then |
39 | dnl FreeBSD (at least up to 5.3) has a broken GCC, workaround it |
41 | dnl FreeBSD (at least up to 5.3) has a broken GCC, workaround it |
… | |
… | |
293 | [ --disable-delete-key disable handling of the delete key], |
295 | [ --disable-delete-key disable handling of the delete key], |
294 | [if test x$enableval = xno; then |
296 | [if test x$enableval = xno; then |
295 | AC_DEFINE(NO_DELETE_KEY, 1, Define if you don't want support for the (non-keypad) delete key) |
297 | AC_DEFINE(NO_DELETE_KEY, 1, Define if you don't want support for the (non-keypad) delete key) |
296 | fi]) |
298 | fi]) |
297 | |
299 | |
|
|
300 | support_resources=yes |
298 | AC_ARG_ENABLE(resources, |
301 | AC_ARG_ENABLE(resources, |
299 | [ --disable-resources disable all resource checking], |
302 | [ --disable-resources disable all resource checking], |
300 | [if test x$enableval = xno; then |
303 | [if test x$enableval = xno; then |
301 | AC_DEFINE(NO_RESOURCES, 1, Define if you don't want any resources read) |
304 | support_resources=no |
302 | fi]) |
305 | fi]) |
303 | |
306 | |
304 | AC_ARG_ENABLE(8bitctrls, |
307 | AC_ARG_ENABLE(8bitctrls, |
305 | [ --enable-8bitctrls enable 8 bit control sequences (not recommended)], |
308 | [ --enable-8bitctrls enable 8 bit control sequences (not recommended)], |
306 | [if test x$enableval = xyes -o x$enableval = xno; then |
309 | [if test x$enableval = xyes -o x$enableval = xno; then |
… | |
… | |
410 | [ --with-terminfo=PATH set the path to the terminfo tree to PATH], |
413 | [ --with-terminfo=PATH set the path to the terminfo tree to PATH], |
411 | [if test x$withval != x; then |
414 | [if test x$withval != x; then |
412 | AC_DEFINE_UNQUOTED(RXVT_TERMINFO, "$withval", Set TERMINFO value to the value given by configure) terminfo="$withval" |
415 | AC_DEFINE_UNQUOTED(RXVT_TERMINFO, "$withval", Set TERMINFO value to the value given by configure) terminfo="$withval" |
413 | fi]) |
416 | fi]) |
414 | |
417 | |
|
|
418 | if test x$support_resources = xno; then |
|
|
419 | if test x$support_frills = xyes || test x$support_perl = xyes; then |
|
|
420 | AC_MSG_ERROR([--disable-resources requires --disable-frills --disable-perl]) |
|
|
421 | fi |
|
|
422 | |
|
|
423 | AC_DEFINE(NO_RESOURCES, 1, Define if you don't want any resources read) |
|
|
424 | fi |
|
|
425 | |
415 | dnl# -------------------------------------------------------------------------- |
426 | dnl# -------------------------------------------------------------------------- |
416 | |
427 | |
417 | LIBEV_M4_AVOID_LIBRT=1 |
428 | LIBEV_M4_AVOID_LIBRT=1 |
418 | m4_include([libev/libev.m4]) |
429 | m4_include([libev/libev.m4]) |
419 | |
430 | |
… | |
… | |
422 | AC_PATH_PROG(TIC, tic, :) |
433 | AC_PATH_PROG(TIC, tic, :) |
423 | |
434 | |
424 | AC_PATH_XTRA |
435 | AC_PATH_XTRA |
425 | |
436 | |
426 | AC_PATH_TOOL(PKG_CONFIG, pkg-config, no) |
437 | AC_PATH_TOOL(PKG_CONFIG, pkg-config, no) |
|
|
438 | |
|
|
439 | RXVT_CHECK_MODULES([PTYTTY], [libptytty], [:], [ |
|
|
440 | AC_MSG_ERROR([unable to find libptytty]) |
|
|
441 | ]) |
|
|
442 | |
|
|
443 | AC_SUBST(PTYTTY_CFLAGS) |
|
|
444 | AC_SUBST(PTYTTY_LIBS) |
427 | |
445 | |
428 | image_lib=none |
446 | image_lib=none |
429 | |
447 | |
430 | PIXBUF_CFLAGS= |
448 | PIXBUF_CFLAGS= |
431 | PIXBUF_LIBS= |
449 | PIXBUF_LIBS= |
… | |
… | |
501 | |
519 | |
502 | dnl# -------------------------------------------------------------------------- |
520 | dnl# -------------------------------------------------------------------------- |
503 | dnl# CHECKING FOR LIBRARY FUNCTIONS |
521 | dnl# CHECKING FOR LIBRARY FUNCTIONS |
504 | dnl# -------------------------------------------------------------------------- |
522 | dnl# -------------------------------------------------------------------------- |
505 | AC_CHECK_FUNCS(unsetenv) |
523 | AC_CHECK_FUNCS(unsetenv) |
506 | |
|
|
507 | UTMP_CHECK |
|
|
508 | |
524 | |
509 | dnl# -------------------------------------------------------------------------- |
525 | dnl# -------------------------------------------------------------------------- |
510 | |
526 | |
511 | dnl# -------------------------------------------------------------------------- |
527 | dnl# -------------------------------------------------------------------------- |
512 | dnl# -------------------------------------------------------------------------- |
528 | dnl# -------------------------------------------------------------------------- |
… | |
… | |
562 | [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <langinfo.h>]], [[nl_langinfo(CODESET);]])],[rxvt_cv_func_nl_langinfo=yes],[rxvt_cv_func_nl_langinfo=no])]) |
578 | [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <langinfo.h>]], [[nl_langinfo(CODESET);]])],[rxvt_cv_func_nl_langinfo=yes],[rxvt_cv_func_nl_langinfo=no])]) |
563 | if test x$rxvt_cv_func_nl_langinfo = xyes; then |
579 | if test x$rxvt_cv_func_nl_langinfo = xyes; then |
564 | AC_DEFINE(HAVE_NL_LANGINFO, 1, Define if nl_langinfo(CODESET) works) |
580 | AC_DEFINE(HAVE_NL_LANGINFO, 1, Define if nl_langinfo(CODESET) works) |
565 | fi |
581 | fi |
566 | |
582 | |
567 | SCM_RIGHTS_CHECK |
|
|
568 | |
|
|
569 | PTY_CHECK |
|
|
570 | |
|
|
571 | TTY_GROUP_CHECK |
|
|
572 | |
|
|
573 | dnl# -------------------------------------------------------------------------- |
583 | dnl# -------------------------------------------------------------------------- |
574 | dnl# now add and remove other stuff |
584 | dnl# now add and remove other stuff |
575 | dnl# -------------------------------------------------------------------------- |
585 | dnl# -------------------------------------------------------------------------- |
576 | support_image=no |
586 | support_image=no |
577 | if test x$support_inheritpixmap = xyes || test x$support_pixbuf = xyes; then |
587 | if test x$support_inheritpixmap = xyes || test x$support_pixbuf = xyes; then |