--- rxvt-unicode/configure.ac 2006/01/28 21:25:47 1.32 +++ rxvt-unicode/configure.ac 2006/02/02 14:41:00 1.35 @@ -47,7 +47,7 @@ LIBS="$LIBS -lsupc++" LINKER="$CC" AC_LINK_IFELSE( - [AC_LANG_PROGRAM([struct test { }; void f() try { throw new test; } catch (...) { throw; }])], + [AC_LANG_PROGRAM([struct test { }; void f() try { throw new test; } catch (...) { throw; }],[])], [AC_MSG_RESULT(ok)], [ AC_MSG_RESULT([no, making everything bigger and slower]) @@ -59,14 +59,13 @@ fi AC_SUBST(LINKER,[$LINKER]) -AC_LANG(C++) dnl# -------------------------------------------------------------------------- dnl# Supply default CXXFLAGS, if not specified by `CXXFLAGS=flags ./configure' dnl# if test -z "$orig_CXXFLAGS"; then if test x$GCC = xyes && test "x$GXX" = xyes; then CXXFLAGS="-g -O3 -fno-threadsafe-statics -fno-enforce-eh-specs" - AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], [], [CXXFLAGS="-g -O3"]) + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])], [], [CXXFLAGS="-g -O3"]) else CXXFLAGS="-O" fi @@ -276,12 +275,6 @@ support_scroll_plain=$enableval fi]) -dnl AC_ARG_ENABLE(half-shadow, -dnl [ --enable-half-shadow use half width/height shadow on rxvt scrollbar], -dnl [if test x$enableval = xyes; then -dnl AC_DEFINE(HALFSHADOW, 1, Define if you want the depth of scrollbars and menus to be less) -dnl fi]) - AC_ARG_WITH(codesets, [ --with-codesets=NAME,.. compile in additional codesets (jp,jp_ext,kr,zh,zh_ext,all)], [codesets="$withval"]) @@ -540,6 +533,20 @@ LIBS=$ac_save_LIBS CFLAGS=$ac_save_CFLAGS +AC_CACHE_CHECK([for XLIB_ILLEGAL_ACCESS], rxvt_xlib_illegal_access, +[AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([ +#define XLIB_ILLEGAL_ACCESS +#include + ],[ + Display *dpy; + dpy->xdefaults = (char *)0; + ])], + [rxvt_xlib_illegal_access=yes],[rxvt_xlib_illegal_access=no] +)]) +if test x$rxvt_xlib_illegal_access = xyes; then + AC_DEFINE(XLIB_ILLEGAL_ACCESS, 1, Define ONLY iff Xlib.h supports it) +fi AC_C_CONST AC_C_INLINE @@ -885,16 +892,17 @@ AC_SUBST(IF_PERL) AC_SUBST(PERL_O) + AC_TRY_LINK([ +#include +#include +#include +],[ + PerlInterpreter *perl = perl_alloc (); +],[rxvt_perl_link=yes],[rxvt_perl_link=no]) if test x$support_perl = xyes; then support_frills=yes fi -dnl> AC_CHECK_FUNCS(gettimeofday putenv select socket) - -CFLAGS=${CFLAGS--O} -LDFLAGS=${LDFLAGS--O} - -CPPFLAGS="$CPPFLAGS" AC_SUBST(DEBUG) AC_SUBST(DINCLUDE) AC_SUBST(CFLAGS) @@ -997,14 +1005,3 @@ echo "*** Optionally check src/feature.h for further, rarely used options ***" echo -echo ".----------------------------------------------------------------." -echo ". NOTE: some features are disabled by default, try ." -echo ". configure --help to get an idea of the optional features, ." -echo ". or read ./README.configure ." -echo ". ." -echo ". The script ./reconf gives a reasonable baseline, try it if ." -echo ". you do not want to read documentation and still want some ." -echo ". useful features. ." -echo ".----------------------------------------------------------------." -echo -