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.6 by ayin, Tue Jan 17 22:08:08 2006 UTC vs.
Revision 1.11 by root, Fri Jan 20 16:00:38 2006 UTC

30 30
31AC_PROG_CC 31AC_PROG_CC
32AC_PROG_CXX 32AC_PROG_CXX
33AC_PROG_CPP 33AC_PROG_CPP
34AC_PROG_INSTALL 34AC_PROG_INSTALL
35AC_PROG_AWK 35
36AC_AIX
37AC_ISC_POSIX
36 38
37AC_LANG(C) 39AC_LANG(C)
38 40
39dnl# -------------------------------------------------------------------------- 41dnl check wetehr we can link with gcc -lsupc++
40dnl# Supply default CFLAGS, if not specified by `CFLAGS=flags ./configure'
41dnl#
42if test -z "$orig_CXXFLAGS"; then
43 if test x$GCC = xyes && test "x$GXX" = xyes; then
44 CXXFLAGS="-g -O3"
45 else
46 CXXFLAGS="-O"
47 fi
48 CFLAGS="$CXXFLAGS"
49fi
50
51LINKER="$CXX" 42LINKER="$CXX"
52if test x$GCC = xyes && test x$GXX = xyes; then 43if test x$GCC = xyes && test x$GXX = xyes; then
53 AC_CHECK_LIB(supc++, main, [ 44 AC_CHECK_LIB(supc++, main, [
54 LINKER="$CC" 45 LINKER="$CC"
55 LIBS="$LIBS -lsupc++" 46 LIBS="$LIBS -lsupc++"
56 ]) 47 ])
57fi 48fi
58AC_SUBST(LINKER,[$LINKER]) 49AC_SUBST(LINKER,[$LINKER])
50
51AC_LANG(C++)
52dnl# --------------------------------------------------------------------------
53dnl# Supply default CXXLAGS, if not specified by `CXXLAGS=flags ./configure'
54dnl#
55if test -z "$orig_CXXFLAGS"; then
56 if test x$GCC = xyes && test "x$GXX" = xyes; then
57 CXXFLAGS="-g -O3 -fno-threadsafe-statics -fno-enforce-eh-specs"
58 AC_COMPILE_IFELSE([int i;], [], [CXXFLAGS="-g -O3"])
59 else
60 CXXFLAGS="-O"
61 fi
62 CFLAGS="$CXXFLAGS"
63fi
59 64
60AC_DEFINE(_GNU_SOURCE, 1, Use all glibc features.) 65AC_DEFINE(_GNU_SOURCE, 1, Use all glibc features.)
61 66
62case $host in 67case $host in
63 *-*-solaris* ) 68 *-*-solaris* )
68esac 73esac
69 74
70dnl if test x$GXX = xyes; then 75dnl if test x$GXX = xyes; then
71dnl CXXFLAGS="$CXXFLAGS" dnl I once had -fno-exceptions, but I am using them now... 76dnl CXXFLAGS="$CXXFLAGS" dnl I once had -fno-exceptions, but I am using them now...
72dnl fi 77dnl fi
73
74AC_LANG(C++)
75
76dnl# system hacks
77AC_AIX
78AC_ISC_POSIX
79 78
80dnl# FreeBSD needs to link libxpg4 79dnl# FreeBSD needs to link libxpg4
81AC_CHECK_FUNC(setlocale, [], [AC_CHECK_LIB(xpg4, setlocale, [LIBS="$LIBS -lxpg4"])]) 80AC_CHECK_FUNC(setlocale, [], [AC_CHECK_LIB(xpg4, setlocale, [LIBS="$LIBS -lxpg4"])])
82 81
83dnl# solaris needs to link libnsl and socket 82dnl# solaris needs to link libnsl and socket
478 AC_DEFINE_UNQUOTED(RXVT_TERMINFO, "$withval", Set TERMINFO value to the value given by configure) terminfo="$withval" 477 AC_DEFINE_UNQUOTED(RXVT_TERMINFO, "$withval", Set TERMINFO value to the value given by configure) terminfo="$withval"
479 fi]) 478 fi])
480 479
481dnl# -------------------------------------------------------------------------- 480dnl# --------------------------------------------------------------------------
482 481
483AC_DEFINE(PROTOTYPES, 1, Define if you need function prototypes)
484
485AC_PATH_PROG(MV, mv, mv) 482AC_PATH_PROG(MV, mv, mv)
486AC_PATH_PROG(RM, rm, rm) 483AC_PATH_PROG(RM, rm, rm)
487AC_PATH_PROG(CP, cp, cp) 484AC_PATH_PROG(CP, cp, cp)
488AC_PATH_PROG(LN, ln, ln) 485AC_PATH_PROG(LN, ln, ln)
489AC_PATH_PROG(SED, sed, sed) 486AC_PATH_PROG(SED, sed, sed)
490AC_PATH_PROG(ECHO, echo, echo) 487AC_PATH_PROG(ECHO, echo, echo)
491AC_PATH_PROG(CMP, cmp, cmp) 488AC_PATH_PROG(CMP, cmp, cmp)
492AC_PATH_PROG(TBL, tbl)
493AC_PATH_PROG(TIC, tic) 489AC_PATH_PROG(TIC, tic)
494 490
495dnl# need a neat way to detect SVR4 or its features 491dnl# need a neat way to detect SVR4 or its features
496dnl# in src/command.c we use these functions: 492dnl# in src/command.c we use these functions:
497dnl# grantpt(), unlockpt(), ptsname(), which are defined in <sys/ptms.h> 493dnl# grantpt(), unlockpt(), ptsname(), which are defined in <sys/ptms.h>
737 733
738dnl# -------------------------------------------- 734dnl# --------------------------------------------
739AC_CHECK_HEADER(utmp.h, 735AC_CHECK_HEADER(utmp.h,
740[AC_CACHE_CHECK([for struct utmp], rxvt_cv_struct_utmp, 736[AC_CACHE_CHECK([for struct utmp], rxvt_cv_struct_utmp,
741[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <sys/types.h> 737[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <sys/types.h>
742#include <stdint.h>
743#include <utmp.h>]], [[struct utmp ut;]])],[rxvt_cv_struct_utmp=yes],[rxvt_cv_struct_utmp=no])]) 738#include <utmp.h>]], [[struct utmp ut;]])],[rxvt_cv_struct_utmp=yes],[rxvt_cv_struct_utmp=no])])
744if test x$rxvt_cv_struct_utmp = xyes; then 739if test x$rxvt_cv_struct_utmp = xyes; then
745 AC_DEFINE(HAVE_STRUCT_UTMP, 1, Define if utmp.h has struct utmp) 740 AC_DEFINE(HAVE_STRUCT_UTMP, 1, Define if utmp.h has struct utmp)
746fi 741fi
747] 742]

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines