ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/configure.ac
(Generate patch)

Comparing rxvt-unicode/configure.ac (file contents):
Revision 1.70 by ayin, Thu Aug 2 00:09:54 2007 UTC vs.
Revision 1.91 by ayin, Mon Dec 10 23:49:38 2007 UTC

15DATE=`sed -n -e 's/^.*[ \t]DATE.*"\(.*\)"$/\1/p' ${srcdir}/src/version.h` 15DATE=`sed -n -e 's/^.*[ \t]DATE.*"\(.*\)"$/\1/p' ${srcdir}/src/version.h`
16dnl LIBVERSION=`sed -n -e 's/^.*[ \t]LIBVERSION.*"\(.*\)"$/\1/p' ${srcdir}/src/version.h` 16dnl LIBVERSION=`sed -n -e 's/^.*[ \t]LIBVERSION.*"\(.*\)"$/\1/p' ${srcdir}/src/version.h`
17changequote([, ])dnl 17changequote([, ])dnl
18AC_SUBST(VERSION)dnl 18AC_SUBST(VERSION)dnl
19AC_SUBST(DATE)dnl 19AC_SUBST(DATE)dnl
20AC_SUBST(LSMDATE)dnl
21AC_SUBST(LIBVERSION)dnl 20dnl AC_SUBST(LIBVERSION)dnl
21
22echo "" 22echo ""
23echo "configuring for rxvt $VERSION" 23echo "configuring for rxvt $VERSION"
24echo "" 24echo ""
25 25
26orig_CXXFLAGS="$CXXFLAGS" 26orig_CXXFLAGS="$CXXFLAGS"
27 27
28dnl# Checks for programs. 28dnl# Checks for programs.
29dnl AC_MAKE_SET
30
31AC_PROG_CC 29AC_PROG_CC
32AC_PROG_CXX 30AC_PROG_CXX
33AC_PROG_CPP 31AC_PROG_CPP
34AC_PROG_INSTALL 32AC_PROG_INSTALL
35 33
36AC_AIX 34AC_AIX
35AC_GNU_SOURCE
37AC_ISC_POSIX 36AC_ISC_POSIX
38AC_LANG(C++) 37AC_LANG(C++)
39 38
40dnl check wether we can link with gcc -lsupc++ 39dnl check wether we can link with gcc -lsupc++
41if test x$GCC = xyes && test x$GXX = xyes; then 40if test x$GCC = xyes && test x$GXX = xyes; then
62dnl# -------------------------------------------------------------------------- 61dnl# --------------------------------------------------------------------------
63dnl# Supply default CXXFLAGS, if not specified by `CXXFLAGS=flags ./configure' 62dnl# Supply default CXXFLAGS, if not specified by `CXXFLAGS=flags ./configure'
64dnl# 63dnl#
65if test -z "$orig_CXXFLAGS"; then 64if test -z "$orig_CXXFLAGS"; then
66 if test x$GCC = xyes && test "x$GXX" = xyes; then 65 if test x$GCC = xyes && test "x$GXX" = xyes; then
67 CXXFLAGS="-g -O3 -fno-threadsafe-statics -fno-enforce-eh-specs" 66 CXXFLAGS="-g -O3 -fno-rtti -fvisibility-inlines-hidden -fno-threadsafe-statics -fno-enforce-eh-specs"
68 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])], [], [CXXFLAGS="-g -O3"]) 67 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])], [], [CXXFLAGS="-g -O3"])
69 else 68 else
70 CXXFLAGS="-O" 69 CXXFLAGS="-O"
71 fi 70 fi
72 CFLAGS="$CXXFLAGS" 71 CFLAGS="$CXXFLAGS"
73fi 72fi
74
75AC_DEFINE(_GNU_SOURCE, 1, Use all glibc features.)
76 73
77case $host in 74case $host in
78 *-*-solaris* ) 75 *-*-solaris* )
79 AC_DEFINE(_XOPEN_SOURCE, 500, Needed to get declarations for msg_control and msg_controllen on Solaris) 76 AC_DEFINE(_XOPEN_SOURCE, 500, Needed to get declarations for msg_control and msg_controllen on Solaris)
80 ;; 77 ;;
81esac 78esac
82 79
83dnl if test x$GXX = xyes; then
84dnl CXXFLAGS="$CXXFLAGS" dnl I once had -fno-exceptions, but I am using them now...
85dnl fi
86
87dnl# FreeBSD needs to link libxpg4 80dnl# FreeBSD needs to link libxpg4
88AC_CHECK_FUNC(setlocale, [], [AC_CHECK_LIB(xpg4, setlocale, [LIBS="$LIBS -lxpg4"])]) 81AC_CHECK_FUNC(setlocale, [], [AC_CHECK_LIB(xpg4, setlocale, [LIBS="$LIBS -lxpg4"])])
89 82
90dnl# solaris needs to link libnsl and socket 83dnl# solaris needs to link libnsl and socket
91AC_CHECK_FUNC(gethostbyname, [], [AC_CHECK_LIB(nsl, gethostbyname, [LIBS="$LIBS -lnsl"])]) 84AC_CHECK_FUNC(gethostbyname, [], [AC_CHECK_LIB(nsl, gethostbyname, [LIBS="$LIBS -lnsl"])])
95dnl AC_ENABLE_STATIC(yes)dnl# libtool 88dnl AC_ENABLE_STATIC(yes)dnl# libtool
96dnl AC_PROG_LIBTOOL()dnl# libtool 89dnl AC_PROG_LIBTOOL()dnl# libtool
97 90
98support_frills=yes 91support_frills=yes
99support_inheritpixmap=yes 92support_inheritpixmap=yes
100support_tinting=yes
101support_fading=yes 93support_fading=yes
102support_keepscrolling=yes 94support_keepscrolling=yes
103support_selectionscrolling=yes 95support_selectionscrolling=yes
104support_mousewheel=yes 96support_mousewheel=yes
105support_mouseslipwheel=yes 97support_mouseslipwheel=yes
123 115
124dnl# -------------------------------------------------------------------------- 116dnl# --------------------------------------------------------------------------
125dnl# CHECKING COMMAND LINE OPTIONS 117dnl# CHECKING COMMAND LINE OPTIONS
126dnl# -------------------------------------------------------------------------- 118dnl# --------------------------------------------------------------------------
127 119
128if test "x$enable_shared" = xyes; then 120dnl if test "x$enable_shared" = xyes; then
129 AC_DEFINE(LIBRXVT, 1, Build shared library version - specify via configure only) 121dnl AC_DEFINE(LIBRXVT, 1, Build shared library version - specify via configure only)
130 INSTALL_LIBRXVT=yes 122dnl INSTALL_LIBRXVT=yes
131fi 123dnl fi
132AC_SUBST(INSTALL_LIBRXVT) 124dnl AC_SUBST(INSTALL_LIBRXVT)
133 125
134AC_ARG_ENABLE(everything, 126AC_ARG_ENABLE(everything,
135 [ --enable-everything enable standard non-multichoice features 127 [ --enable-everything enable standard non-multichoice features
136 NOTE: this option is order dependent 128 NOTE: this option is order dependent],
137 NOTE: automatically enabled with --enable-shared],
138 [ 129 [
139 if test x$enableval = xno; then 130 if test x$enableval = xno; then
140 support_frills=no 131 support_frills=no
141 support_inheritpixmap=no 132 support_inheritpixmap=no
142 support_tinting=no
143 support_fading=no 133 support_fading=no
144 support_keepscrolling=no 134 support_keepscrolling=no
145 support_selectionscrolling=no 135 support_selectionscrolling=no
146 support_lastlog=no 136 support_lastlog=no
147 support_mousewheel=no 137 support_mousewheel=no
167 codesets= 157 codesets=
168 fi 158 fi
169 if test x$enableval = xyes; then 159 if test x$enableval = xyes; then
170 support_frills=yes 160 support_frills=yes
171 support_inheritpixmap=yes 161 support_inheritpixmap=yes
172 support_tinting=yes
173 support_fading=yes 162 support_fading=yes
174 support_keepscrolling=yes 163 support_keepscrolling=yes
175 support_selectionscrolling=yes 164 support_selectionscrolling=yes
176 support_lastlog=yes 165 support_lastlog=yes
177 support_mousewheel=yes 166 support_mousewheel=yes
196 support_perl=yes 185 support_perl=yes
197 codesets=all 186 codesets=all
198 fi 187 fi
199 ]) 188 ])
200 189
190WARNINGS=no
191AC_ARG_ENABLE(warnings,
192 [ --enable-warnings turn on g++ warnings],
193 [if test x$enableval = xyes; then
194 WARNINGS=yes
195 fi])
196if test x$GXX = xyes; then
197 if test $WARNINGS = yes; then
198 save_CXXFLAGS="$CXXFLAGS"
199 CXXFLAGS="$CXXFLAGS -Wall -Wno-sign-compare -Wno-reorder -Wno-non-virtual-dtor"
200 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])], [], [CXXFLAGS="$save_CXXFLAGS"])
201 else
202 CXXFLAGS="$CXXFLAGS -w"
203 fi
204fi
205
201AC_ARG_ENABLE(unicode3, 206AC_ARG_ENABLE(unicode3,
202 [ --enable-unicode3 use 21 instead of 16 bits to represent unicode characters], 207 [ --enable-unicode3 use 21 instead of 16 bits to represent unicode characters],
203 [if test x$enableval = xyes -o x$enableval = xno; then 208 [if test x$enableval = xyes -o x$enableval = xno; then
204 support_unicode3=$enableval 209 support_unicode3=$enableval
205 fi]) 210 fi])
244 [ --enable-transparency enable transparent backgrounds], 249 [ --enable-transparency enable transparent backgrounds],
245 [if test x$enableval = xyes -o x$enableval = xno; then 250 [if test x$enableval = xyes -o x$enableval = xno; then
246 support_inheritpixmap=$enableval 251 support_inheritpixmap=$enableval
247 fi]) 252 fi])
248 253
249AC_ARG_ENABLE(tinting,
250 [ --enable-tinting enable tinting of transparent bg],
251 [if test x$enableval = xyes -o x$enableval = xno; then
252 support_tinting=$enableval
253 fi])
254
255AC_ARG_ENABLE(fading, 254AC_ARG_ENABLE(fading,
256 [ --enable-fading enable colors fading when off focus], 255 [ --enable-fading enable colors fading when off focus],
257 [if test x$enableval = xyes -o x$enableval = xno; then 256 [if test x$enableval = xyes -o x$enableval = xno; then
258 support_fading=$enableval 257 support_fading=$enableval
259 fi]) 258 fi])
274 [ --enable-xterm-scroll enable Xterm style scrollbar], 273 [ --enable-xterm-scroll enable Xterm style scrollbar],
275 [if test x$enableval = xyes -o x$enableval = xno; then 274 [if test x$enableval = xyes -o x$enableval = xno; then
276 support_scroll_xterm=$enableval 275 support_scroll_xterm=$enableval
277 fi]) 276 fi])
278 277
278AC_ARG_ENABLE(plain-scroll,
279 [ --enable-plain-scroll enable plain style scrollbar],
280 [if test x$enableval = xyes -o x$enableval = xno; then
281 support_scroll_plain=$enableval
282 fi])
283
279AC_ARG_ENABLE(perl, 284AC_ARG_ENABLE(perl,
280 [ --enable-perl enable embedded perl interpreter], 285 [ --enable-perl enable embedded perl interpreter],
281 [if test x$enableval = xyes -o x$enableval = xno; then 286 [if test x$enableval = xyes -o x$enableval = xno; then
282 support_perl=$enableval 287 support_perl=$enableval
283 fi]) 288 fi])
284 289
285AC_ARG_ENABLE(plain-scroll,
286 [ --enable-plain-scroll enable plain style scrollbar],
287 [if test x$enableval = xyes -o x$enableval = xno; then
288 support_scroll_plain=$enableval
289 fi])
290
291AC_ARG_WITH(codesets, 290AC_ARG_WITH(codesets,
292 [ --with-codesets=NAME,.. compile in additional codesets (jp,jp_ext,kr,zh,zh_ext,all)], 291 [ --with-codesets=CS,... compile in additional codesets (jp,jp_ext,kr,zh,zh_ext,all)],
293 [codesets="$withval"]) 292 [codesets="$withval"])
294 293
295AC_ARG_ENABLE(xim, 294AC_ARG_ENABLE(xim,
296 [ --enable-xim XIM (X Input Method) protocol support], 295 [ --enable-xim XIM (X Input Method) protocol support],
297 [if test x$enableval = xyes -o x$enableval = xno; then 296 [if test x$enableval = xyes -o x$enableval = xno; then
322 support_8bitctrls=$enableval 321 support_8bitctrls=$enableval
323 fi]) 322 fi])
324 323
325RESFALLBACK=Rxvt 324RESFALLBACK=Rxvt
326AC_ARG_ENABLE(fallback, 325AC_ARG_ENABLE(fallback,
327 [ --enable-fallback(=CLASS) fall back on CLASS resources in addition to URxvt ones (default: Rxvt)], 326 [ --enable-fallback@<:@=CLASS@:>@ fall back on CLASS resources in addition to URxvt ones (default: Rxvt)],
328 [ 327 [
329 test x$enableval = xyes && enableval=Rxvt 328 test x$enableval = xyes && enableval=Rxvt
330 test x$enableval = xno && enableval= 329 test x$enableval = xno && enableval=
331 RESFALLBACK="$enableval" 330 RESFALLBACK="$enableval"
332 ]) 331 ])
391 [if test x$enableval = xyes -o x$enableval = xno; then 390 [if test x$enableval = xyes -o x$enableval = xno; then
392 support_mousewheel=$enableval 391 support_mousewheel=$enableval
393 fi]) 392 fi])
394 393
395AC_ARG_ENABLE(slipwheeling, 394AC_ARG_ENABLE(slipwheeling,
396 [ --enable-slipwheeling enable slip wheel scrolling (requires previous)], 395 [ --enable-slipwheeling enable slip wheel scrolling (requires --enable-mousewheel)],
397 [if test x$enableval = xyes -o x$enableval = xno; then 396 [if test x$enableval = xyes -o x$enableval = xno; then
398 support_mouseslipwheel=$enableval 397 support_mouseslipwheel=$enableval
399 fi]) 398 fi])
400 399
401AC_ARG_ENABLE(smart-resize, 400AC_ARG_ENABLE(smart-resize,
428 AC_DEFINE_UNQUOTED(RXVT_TERMINFO, "$withval", Set TERMINFO value to the value given by configure) terminfo="$withval" 427 AC_DEFINE_UNQUOTED(RXVT_TERMINFO, "$withval", Set TERMINFO value to the value given by configure) terminfo="$withval"
429 fi]) 428 fi])
430 429
431dnl# -------------------------------------------------------------------------- 430dnl# --------------------------------------------------------------------------
432 431
432LIBEV_M4_AVOID_LIBRT=1
433m4_include([libev/libev.m4])
434
435dnl# --------------------------------------------------------------------------
436
433AC_PATH_PROG(TIC, tic) 437AC_PATH_PROG(TIC, tic, :)
434
435dnl# need a neat way to detect SVR4 or its features
436dnl# in src/command.c we use these functions:
437dnl# grantpt(), unlockpt(), ptsname(), which are defined in <sys/ptms.h>
438dnl# - but are these also defined for other systems?
439
440dnl# hack to find if this is SVR4 -- who knows?
441dnl## AC_MSG_CHECKING(for SVR4)
442dnl## AC_EGREP_CPP(yes,
443dnl## [#if defined (SVR4) || defined (_SVR4) || defined (__svr4__)
444dnl## yes;
445dnl## #endif
446dnl## ], [AC_MSG_RESULT(yes); AC_DEFINE(PERHAPS_SVR4)], AC_MSG_RESULT(perhaps not?))
447 438
448AC_PATH_XTRA 439AC_PATH_XTRA
449 440
450AFTERIMAGE_CFLAGS= 441AFTERIMAGE_CFLAGS=
451AFTERIMAGE_LIBS= 442AFTERIMAGE_LIBS=
483fi 474fi
484 475
485dnl# -------------------------------------------------------------------------- 476dnl# --------------------------------------------------------------------------
486dnl# CHECKING FOR HEADER FILES 477dnl# CHECKING FOR HEADER FILES
487dnl# -------------------------------------------------------------------------- 478dnl# --------------------------------------------------------------------------
488AC_HEADER_SYS_WAIT
489AC_CHECK_HEADERS( \ 479AC_CHECK_HEADERS( \
490 assert.h \ 480 assert.h \
491 fcntl.h \ 481 fcntl.h \
492 stdarg.h \ 482 stdarg.h \
493 stdlib.h \ 483 stdlib.h \
504 wchar.h \ 494 wchar.h \
505 cwchar \ 495 cwchar \
506 clocale \ 496 clocale \
507) 497)
508 498
509AC_HEADER_TIME
510
511dnl# check to allow both <termios.h> and <sys/ioctl.h> 499dnl# check to allow both <termios.h> and <sys/ioctl.h>
512AC_CACHE_CHECK(whether termios.h and sys/ioctl.h may both be included, rxvt_cv_header_sysioctl, 500AC_CACHE_CHECK(whether termios.h and sys/ioctl.h may both be included, rxvt_cv_header_sysioctl,
513[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <stdio.h> 501[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <stdio.h>
514#include <sys/ioctl.h> 502#include <sys/ioctl.h>
515#ifdef HAVE_TERMIOS_H 503#ifdef HAVE_TERMIOS_H
534 [rxvt_xlib_illegal_access=yes],[rxvt_xlib_illegal_access=no] 522 [rxvt_xlib_illegal_access=yes],[rxvt_xlib_illegal_access=no]
535)]) 523)])
536if test x$rxvt_xlib_illegal_access = xyes; then 524if test x$rxvt_xlib_illegal_access = xyes; then
537 AC_DEFINE(XLIB_ILLEGAL_ACCESS, 1, Define ONLY iff Xlib.h supports it) 525 AC_DEFINE(XLIB_ILLEGAL_ACCESS, 1, Define ONLY iff Xlib.h supports it)
538fi 526fi
539
540AC_C_CONST
541AC_C_INLINE
542
543dnl> AC_HEADER_STDC dnl# skip this test, Sun always fails anyhow.
544 527
545dnl# -------------------------------------------------------------------------- 528dnl# --------------------------------------------------------------------------
546dnl# CHECKING FOR MISSING TYPEDEFS 529dnl# CHECKING FOR MISSING TYPEDEFS
547dnl# -------------------------------------------------------------------------- 530dnl# --------------------------------------------------------------------------
548dnl# Missing typedefs and replacements 531dnl# Missing typedefs and replacements
632AC_SUBST(rxvt_u_intp_define) 615AC_SUBST(rxvt_u_intp_define)
633 616
634dnl# -------------------------------------------------------------------------- 617dnl# --------------------------------------------------------------------------
635dnl# CHECKING FOR LIBRARY FUNCTIONS 618dnl# CHECKING FOR LIBRARY FUNCTIONS
636dnl# -------------------------------------------------------------------------- 619dnl# --------------------------------------------------------------------------
637AC_TYPE_SIGNAL 620AC_CHECK_FUNCS(unsetenv)
638dnl> AC_FUNC_VPRINTF
639
640AC_CHECK_FUNCS( \
641 unsetenv \
642 setutent \
643 on_exit \
644)
645 621
646UTMP_CHECK 622UTMP_CHECK
647 623
648dnl# -------------------------------------------------------------------------- 624dnl# --------------------------------------------------------------------------
649 625
650dnl# find ttys/ttytab
651AC_CACHE_CHECK(where ttys/ttytab is located, rxvt_cv_path_ttytab,
652[for ttys_file in dnl
653 /etc/ttys /etc/ttytab;
654do
655 if test -f "$ttys_file" ; then
656 rxvt_cv_path_ttytab=$ttys_file
657 break
658 fi
659done
660])
661if test x$rxvt_cv_path_ttytab != x; then
662 AC_DEFINE_UNQUOTED(TTYTAB_FILENAME, "$rxvt_cv_path_ttytab", Define location of ttys/ttytab)
663fi
664
665dnl# -------------------------------------------------------------------------- 626dnl# --------------------------------------------------------------------------
666dnl# -------------------------------------------------------------------------- 627dnl# --------------------------------------------------------------------------
667 628
668dnl# this is a really hack test for some basic Xlocale stuff 629dnl# this is a really hack test for some basic Xlocale stuff
669ac_save_LIBS=$LIBS 630save_LIBS=$LIBS
670ac_save_CFLAGS=$CFLAGS 631save_CFLAGS=$CFLAGS
671CFLAGS="$CFLAGS $X_CFLAGS" 632CFLAGS="$CFLAGS $X_CFLAGS"
672LIBS="$LIBS $X_LIBS $X_EXTRA_LIBS -lX11" 633LIBS="$LIBS $X_LIBS $X_EXTRA_LIBS -lX11"
673AC_CACHE_CHECK(for working Xlocale, rxvt_cv_func_xlocale,
674[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <X11/Xlib.h>
675#include <stdlib.h>
676main() {
677char *p;
678if ((p = XSetLocaleModifiers("@im=none")) != NULL && *p)
679exit (XSupportsLocale() ? 0 : 1);
680else
681exit (1);}]])],[dnl
682 rxvt_cv_func_xlocale=yes],[rxvt_cv_func_xlocale=no],[dnl
683 :])])
684if test x$support_xim = xyes; then 634if test x$support_xim = xyes; then
635 AC_CACHE_CHECK(for working Xlocale, rxvt_cv_func_xlocale,
636 [AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <X11/Xlib.h>
637 #include <stdlib.h>
638 main() {
639 char *p;
640 if ((p = XSetLocaleModifiers("@im=none")) != NULL && *p)
641 exit (XSupportsLocale() ? 0 : 1);
642 else
643 exit (1);}]])],[dnl
644 rxvt_cv_func_xlocale=yes],[rxvt_cv_func_xlocale=no],[dnl
645 :])])
685 if test x$rxvt_cv_func_xlocale = xyes; then 646 if test x$rxvt_cv_func_xlocale = xyes; then
686 AC_DEFINE(USE_XIM, 1, Define if you want to have XIM (X Input Method) protocol support - required for multibyte characters input) 647 AC_DEFINE(USE_XIM, 1, Define if you want to have XIM (X Input Method) protocol support - required for multibyte characters input)
648 AC_CACHE_CHECK(for broken XIM callback, rxvt_broken_ximcb,
649 [AC_COMPILE_IFELSE([
650 #include <X11/Xlib.h>
651
652 void im_destroy_cb (XIC unused1, XPointer client_data, XPointer unused3);
653
654 void f() {
655 XIMCallback cb;
656 cb.callback = im_destroy_cb;
657 }
658 ],rxvt_broken_ximcb=yes,rxvt_broken_ximcb=no)])
659
660 if test x$rxvt_broken_ximcb = xyes; then
661 AC_DEFINE(XIMCB_PROTO_BROKEN, 1, Define if your XIMCallback specifies XIC as first type.)
662 fi
687 fi 663 fi
688fi 664fi
689 665
690AC_CACHE_CHECK(for working X setlocale, rxvt_cv_func_xsetlocale, 666AC_CACHE_CHECK(for working X setlocale, rxvt_cv_func_xsetlocale,
691[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#define X_LOCALE 1 667[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#define X_LOCALE 1
692#include <X11/Xlocale.h>]], [[setlocale(LC_CTYPE, "");]])],[rxvt_cv_func_xsetlocale=yes],[rxvt_cv_func_xsetlocale=no])]) 668#include <X11/Xlocale.h>]], [[setlocale(LC_CTYPE, "");]])],[rxvt_cv_func_xsetlocale=yes],[rxvt_cv_func_xsetlocale=no])])
693if test x$rxvt_cv_func_xsetlocale = xyes; then 669if test x$rxvt_cv_func_xsetlocale = xyes; then
694 AC_DEFINE(HAVE_XSETLOCALE, 1, Define if setlocale (defined to Xsetlocale) works) 670 AC_DEFINE(HAVE_XSETLOCALE, 1, Define if setlocale (defined to Xsetlocale) works)
695fi 671fi
696LIBS=$ac_save_LIBS 672LIBS=$save_LIBS
697CFLAGS=$ac_save_CFLAGS 673CFLAGS=$save_CFLAGS
698 674
699AC_CACHE_CHECK(for working plain setlocale, rxvt_cv_func_setlocale, 675AC_CACHE_CHECK(for working plain setlocale, rxvt_cv_func_setlocale,
700[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <clocale>]], [[setlocale(LC_CTYPE, "");]])],[rxvt_cv_func_setlocale=yes],[rxvt_cv_func_setlocale=no])]) 676[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <clocale>]], [[setlocale(LC_CTYPE, "");]])],[rxvt_cv_func_setlocale=yes],[rxvt_cv_func_setlocale=no])])
701if test x$rxvt_cv_func_setlocale = xyes; then 677if test x$rxvt_cv_func_setlocale = xyes; then
702 AC_DEFINE(HAVE_SETLOCALE, 1, Define if plain old setlocale works) 678 AC_DEFINE(HAVE_SETLOCALE, 1, Define if plain old setlocale works)
708 AC_DEFINE(HAVE_NL_LANGINFO, 1, Define if nl_langinfo(CODESET) works) 684 AC_DEFINE(HAVE_NL_LANGINFO, 1, Define if nl_langinfo(CODESET) works)
709fi 685fi
710 686
711SCM_RIGHTS_CHECK 687SCM_RIGHTS_CHECK
712 688
713AC_CACHE_CHECK(for broken XIM callback, rxvt_broken_ximcb,
714[AC_COMPILE_IFELSE([
715#include <X11/Xlib.h>
716
717void im_destroy_cb (XIC unused1, XPointer client_data, XPointer unused3);
718
719void f() {
720 XIMCallback cb;
721 cb.callback = im_destroy_cb;
722}
723],rxvt_broken_ximcb=yes,rxvt_broken_ximcb=no)])
724
725if test x$rxvt_broken_ximcb = xyes; then
726 AC_DEFINE(XIMCB_PROTO_BROKEN, 1, Define if your XIMCallback specifies XIC as first type.)
727fi
728
729PTY_CHECK 689PTY_CHECK
730 690
731TTY_GROUP_CHECK 691TTY_GROUP_CHECK
732 692
733dnl# -------------------------------------------------------------------------- 693dnl# --------------------------------------------------------------------------
734dnl# now add and remove other stuff 694dnl# now add and remove other stuff
735dnl# -------------------------------------------------------------------------- 695dnl# --------------------------------------------------------------------------
736if test x$support_xft = xyes; then 696if test x$support_xft = xyes; then
737 AC_PATH_PROG(PKG_CONFIG, pkg-config, no) 697 AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
738 if test $PKG_CONFIG != no && $PKG_CONFIG --exists xft; then 698 if test $PKG_CONFIG != no && $PKG_CONFIG --exists xft; then
739 LIBS="$LIBS `$PKG_CONFIG xft --libs`" 699 X_LIBS="`$PKG_CONFIG xft --libs` $X_LIBS"
740 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG xft --cflags`" 700 CPPFLAGS="$CPPFLAGS `$PKG_CONFIG xft --cflags`"
741 else 701 else
742 AC_PATH_PROG(XFT_CONFIG, xft-config, no) 702 AC_PATH_PROG(XFT_CONFIG, xft-config, no)
743 if test $XFT_CONFIG != no; then 703 if test $XFT_CONFIG != no; then
744 LIBS="$LIBS `$XFT_CONFIG --libs`" 704 X_LIBS="`$XFT_CONFIG --libs` $X_LIBS"
745 CPPFLAGS="$CPPFLAGS `$XFT_CONFIG --cflags`" 705 CPPFLAGS="$CPPFLAGS `$XFT_CONFIG --cflags`"
746 fi 706 fi
747 fi 707 fi
748 708
709 save_LIBS="$LIBS"
710 LIBS="$LIBS $X_LIBS"
749 AC_CHECK_HEADERS(X11/Xft/Xft.h,,[support_xft=no]) 711 AC_CHECK_HEADERS(X11/Xft/Xft.h,,[support_xft=no])
750 AC_CHECK_LIB(Xft,XftDrawString32,,[support_xft=no]) 712 AC_CHECK_LIB(Xft,XftDrawString32,:,[support_xft=no])
713 LIBS="$save_LIBS"
751 714
752 if test x$support_xft = xyes; then 715 if test x$support_xft = xyes; then
753 AC_DEFINE(XFT, 1, Define to enable xft support) 716 AC_DEFINE(XFT, 1, Define to enable xft support)
754 fi 717 fi
755fi 718fi
763 AC_DEFINE(EIGHT_BIT_CONTROLS, 1, Define if you want 8 bit control sequences) 726 AC_DEFINE(EIGHT_BIT_CONTROLS, 1, Define if you want 8 bit control sequences)
764fi 727fi
765if test x$support_fading = xyes; then 728if test x$support_fading = xyes; then
766 AC_DEFINE(OFF_FOCUS_FADING, 1, Define if you want faded colors when focus is lost) 729 AC_DEFINE(OFF_FOCUS_FADING, 1, Define if you want faded colors when focus is lost)
767fi 730fi
768if test x$support_tinting = xyes; then
769 AC_DEFINE(TINTING, 1, Define if you want your background to be tinted)
770fi
771if test x$support_inheritpixmap = xyes; then 731if test x$support_inheritpixmap = xyes; then
772 AC_DEFINE(ENABLE_TRANSPARENCY, 1, Define if you want your background to use the parent window background) 732 AC_DEFINE(ENABLE_TRANSPARENCY, 1, Define if you want your background to use the parent window background)
773fi 733fi
774if test x$support_keepscrolling = xno; then 734if test x$support_keepscrolling = xno; then
775 AC_DEFINE(NO_SCROLLBAR_BUTTON_CONTINUAL_SCROLLING, 1, Define for continual scrolling when you keep the scrollbar button pressed) 735 AC_DEFINE(NO_SCROLLBAR_BUTTON_CONTINUAL_SCROLLING, 1, Define for continual scrolling when you keep the scrollbar button pressed)
776fi 736fi
777if test x$support_selectionscrolling = xyes; then 737if test x$support_selectionscrolling = xyes; then
778 AC_DEFINE(SELECTION_SCROLLING, 1, Define to allow scrolling when the selection moves to the top or bottom of the screen) 738 AC_DEFINE(SELECTION_SCROLLING, 1, Define to allow scrolling when the selection moves to the top or bottom of the screen)
779fi 739fi
740if test x$support_frills = xyes; then
741 AC_DEFINE(ENABLE_FRILLS, 1, Define if you want handling for rarely used but handy features)
742fi
780if test x$support_mousewheel = xyes; then 743if test x$support_mousewheel = xyes; then
781 AC_DEFINE(MOUSE_WHEEL, 1, Define to use wheel events (button4 and button5) to scroll) 744 AC_DEFINE(MOUSE_WHEEL, 1, Define to use wheel events (button4 and button5) to scroll)
782fi 745fi
783if test x$support_mouseslipwheel = xyes; then 746if test x$support_mouseslipwheel = xyes; then
784 AC_DEFINE(MOUSE_SLIP_WHEELING, 1, Define to have CTRL cause wheel events to accelerate scrolling. Release CTRL to halt scrolling) 747 AC_DEFINE(MOUSE_SLIP_WHEELING, 1, Define to have CTRL cause wheel events to accelerate scrolling. Release CTRL to halt scrolling)
785fi 748fi
786if test x$support_afterimage = xyes; then 749if test x$support_afterimage = xyes; then
787 AC_DEFINE(HAVE_AFTERIMAGE, 1, Define if you want to use libAfterImage for image processing) 750 AC_DEFINE(HAVE_AFTERIMAGE, 1, Define if you want to use libAfterImage for image processing)
788 AC_DEFINE(XPM_BACKGROUND, 1, Define if you want to have sexy-looking background pixmaps. Needs libAfterImage) 751 AC_DEFINE(BG_IMAGE_FROM_FILE, 1, Define if you want to have sexy-looking background pixmaps. Needs libAfterImage)
789fi 752fi
790 753
791dnl if test x$support_afterstep = xyes; then 754dnl if test x$support_afterstep = xyes; then
792dnl AC_DEFINE(AFTERSTEP_INTEGRATION, 1, Define if you want to integrate with AfterStep window manager) 755dnl AC_DEFINE(AFTERSTEP_INTEGRATION, 1, Define if you want to integrate with AfterStep window manager)
793dnl fi 756dnl fi
877AC_SUBST(PERLPRIVLIBEXP) 840AC_SUBST(PERLPRIVLIBEXP)
878AC_SUBST(PERL) 841AC_SUBST(PERL)
879AC_SUBST(IF_PERL) 842AC_SUBST(IF_PERL)
880AC_SUBST(PERL_O) 843AC_SUBST(PERL_O)
881 844
882if test x$support_perl = xyes; then
883 support_frills=yes
884fi
885
886if test x$support_frills = xyes; then
887 AC_DEFINE(ENABLE_FRILLS, 1, Define if you want handling for rarely used but handy features)
888fi
889
890AC_SUBST(CFLAGS) 845AC_SUBST(CFLAGS)
891AC_SUBST(CPPFLAGS) 846AC_SUBST(CPPFLAGS)
892AC_SUBST(LDFLAGS) 847AC_SUBST(LDFLAGS)
893AC_SUBST(X_CFLAGS) 848AC_SUBST(X_CFLAGS)
894 849
941 Install path: ${prefix}/bin 896 Install path: ${prefix}/bin
942 Compiler: $CXX 897 Compiler: $CXX
943 Compiler flags: $CXXFLAGS 898 Compiler flags: $CXXFLAGS
944 Linker: $LINKER" 899 Linker: $LINKER"
945 900
946if test x$support_afterimage = xyes; then
947 echo " AfterImage support: yes"
948fi
949
950dnl if test x$support_afterstep = xyes; then
951dnl echo " AfterStep integration: yes"
952dnl fi
953
954if test x$term != x; then 901if test x$term != x; then
955 echo " set TERM to: $term" 902 echo " set TERM to: $term"
956fi 903fi
957if test x$terminfo != x; then 904if test x$terminfo != x; then
958 echo " set TERMINFO to: $terminfo" 905 echo " set TERMINFO to: $terminfo"
963 echo " resource class fallback: $RESFALLBACK" 910 echo " resource class fallback: $RESFALLBACK"
964fi 911fi
965echo 912echo
966echo " embedded perl: $support_perl" 913echo " embedded perl: $support_perl"
967echo " libafterimage: $support_afterimage" 914echo " libafterimage: $support_afterimage"
915dnl echo " AfterStep integration: $support_afterstep"
968echo 916echo
969if test x$support_xim = xyes -a x$rxvt_cv_func_xlocale = xno; then 917if test x$support_xim = xyes -a x$rxvt_cv_func_xlocale = xno; then
970 echo ".----------------------------------------------------------------." 918 echo ".----------------------------------------------------------------."
971 echo ". WARNING: --enable-xim was specified however the locale support ." 919 echo ". WARNING: --enable-xim was specified however the locale support ."
972 echo ". functions could not be found. ." 920 echo ". functions could not be found. ."

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines