1*4c8945a0SNathan Whitehorndnl $Id: configure.in,v 1.57 2010/04/28 20:33:01 tom Exp $ 2*4c8945a0SNathan Whitehorndnl Process this file with autoconf to produce a configure script. 3*4c8945a0SNathan Whitehorndnl 4*4c8945a0SNathan WhitehornAC_PREREQ(2.13.20020210) 5*4c8945a0SNathan WhitehornAC_INIT(dialog.h) 6*4c8945a0SNathan WhitehornAC_CONFIG_HEADER(dlg_config.h:config.hin) 7*4c8945a0SNathan Whitehorn 8*4c8945a0SNathan WhitehornCF_VERSION_INFO(dialog) 9*4c8945a0SNathan WhitehornAC_ARG_PROGRAM 10*4c8945a0SNathan Whitehorn 11*4c8945a0SNathan WhitehornDESTDIR= 12*4c8945a0SNathan WhitehornAC_SUBST(DESTDIR) 13*4c8945a0SNathan Whitehorn 14*4c8945a0SNathan Whitehorndnl 15*4c8945a0SNathan Whitehorndnl Checks for programs. 16*4c8945a0SNathan Whitehorndnl 17*4c8945a0SNathan WhitehornAC_PROG_CC 18*4c8945a0SNathan WhitehornAC_PROG_CPP 19*4c8945a0SNathan WhitehornAC_PROG_GCC_TRADITIONAL 20*4c8945a0SNathan WhitehornAC_PROG_MAKE_SET 21*4c8945a0SNathan WhitehornAC_PROG_RANLIB 22*4c8945a0SNathan WhitehornAC_PROG_INSTALL 23*4c8945a0SNathan Whitehorn 24*4c8945a0SNathan Whitehorndnl needed for CF_WITH_LIBTOOL 25*4c8945a0SNathan WhitehornAC_CHECK_TOOL(AR, ar, ar) 26*4c8945a0SNathan Whitehorn 27*4c8945a0SNathan WhitehornAC_ISC_POSIX 28*4c8945a0SNathan WhitehornAC_C_CONST 29*4c8945a0SNathan Whitehorn 30*4c8945a0SNathan WhitehornCF_MAKEFLAGS 31*4c8945a0SNathan WhitehornCF_MAKE_TAGS 32*4c8945a0SNathan WhitehornCF_DISABLE_ECHO 33*4c8945a0SNathan WhitehornCF_PROG_EXT 34*4c8945a0SNathan WhitehornCF_PATHSEP 35*4c8945a0SNathan WhitehornCF_LIB_PREFIX 36*4c8945a0SNathan WhitehornCF_XOPEN_SOURCE 37*4c8945a0SNathan WhitehornCF_LARGEFILE 38*4c8945a0SNathan Whitehorn 39*4c8945a0SNathan WhitehornCF_WITH_WARNINGS 40*4c8945a0SNathan Whitehorn 41*4c8945a0SNathan Whitehorndnl 42*4c8945a0SNathan Whitehorndnl Checks for libraries. 43*4c8945a0SNathan Whitehorndnl 44*4c8945a0SNathan WhitehornEXTRAOBJS="" 45*4c8945a0SNathan WhitehornCF_BUNDLED_INTL(makefile,enable) 46*4c8945a0SNathan WhitehornCF_MATH_LIB(,sqrt(x)) 47*4c8945a0SNathan Whitehorn 48*4c8945a0SNathan WhitehornCF_WITH_NO_LEAKS 49*4c8945a0SNathan Whitehorn 50*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want --trace option], 51*4c8945a0SNathan Whitehorn trace, 52*4c8945a0SNathan Whitehorn [ --disable-trace do not support --trace option], 53*4c8945a0SNathan Whitehorn [EXTRAOBJS="$EXTRAOBJS trace\$o" 54*4c8945a0SNathan Whitehorn AC_DEFINE(HAVE_DLG_TRACE)],,yes) 55*4c8945a0SNathan Whitehorn 56*4c8945a0SNathan WhitehornLIBTOOL_MAKE="#" 57*4c8945a0SNathan WhitehornCF_WITH_LIBTOOL 58*4c8945a0SNathan Whitehornif test "$with_libtool" = "yes" ; then 59*4c8945a0SNathan Whitehorn OBJEXT="lo" 60*4c8945a0SNathan Whitehorn LIBTOOL_MAKE= 61*4c8945a0SNathan Whitehorn CF_WITH_LIBTOOL_OPTS 62*4c8945a0SNathan Whitehornfi 63*4c8945a0SNathan WhitehornAC_SUBST(LIBTOOL_MAKE) 64*4c8945a0SNathan Whitehorn 65*4c8945a0SNathan Whitehornuse_ncurses=no 66*4c8945a0SNathan WhitehornAC_ARG_WITH(ncurses, 67*4c8945a0SNathan Whitehorn [ --with-ncurses compile/link with ncurses library], 68*4c8945a0SNathan Whitehorn [use_ncurses=ncurses]) 69*4c8945a0SNathan WhitehornAC_ARG_WITH(ncursesw, 70*4c8945a0SNathan Whitehorn [ --with-ncursesw compile/link with wide-char ncurses library], 71*4c8945a0SNathan Whitehorn [use_ncurses=ncursesw]) 72*4c8945a0SNathan Whitehornif test $use_ncurses != no ; then 73*4c8945a0SNathan Whitehorn cf_wide_curses=yes 74*4c8945a0SNathan Whitehorn if test $use_ncurses = ncursesw ; then 75*4c8945a0SNathan Whitehorn CF_UTF8_LIB 76*4c8945a0SNathan Whitehorn fi 77*4c8945a0SNathan Whitehorn CF_NCURSES_CONFIG($use_ncurses) 78*4c8945a0SNathan Whitehornelse 79*4c8945a0SNathan Whitehorn cf_wide_curses=no 80*4c8945a0SNathan Whitehorn CF_CURSES_CONFIG 81*4c8945a0SNathan Whitehornfi 82*4c8945a0SNathan Whitehorn 83*4c8945a0SNathan Whitehorncf_all_widgets=yes 84*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want extra dialogs], 85*4c8945a0SNathan Whitehorn extras, 86*4c8945a0SNathan Whitehorn [ --disable-extras do not include extra dialogs], 87*4c8945a0SNathan Whitehorn [cf_all_widgets=yes],[cf_all_widgets=no],yes) 88*4c8945a0SNathan Whitehorn 89*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want config-file support], 90*4c8945a0SNathan Whitehorn rc-file, 91*4c8945a0SNathan Whitehorn [ --disable-rc-file do not include config-file support], 92*4c8945a0SNathan Whitehorn [EXTRAOBJS="$EXTRAOBJS rc\$o" 93*4c8945a0SNathan Whitehorn AC_DEFINE(HAVE_RC_FILE)],,$cf_all_widgets) 94*4c8945a0SNathan Whitehorn 95*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want Xdialog-style dialogs], 96*4c8945a0SNathan Whitehorn Xdialog, 97*4c8945a0SNathan Whitehorn [ --disable-Xdialog do not include Xdialog-style dialogs], 98*4c8945a0SNathan Whitehorn [EXTRAOBJS="$EXTRAOBJS calendar\$o fselect\$o timebox\$o" 99*4c8945a0SNathan Whitehorn AC_DEFINE(HAVE_XDIALOG)],,$cf_all_widgets) 100*4c8945a0SNathan Whitehorn 101*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want the form dialog], 102*4c8945a0SNathan Whitehorn form, 103*4c8945a0SNathan Whitehorn [ --disable-form do not include the form dialog], 104*4c8945a0SNathan Whitehorn [EXTRAOBJS="$EXTRAOBJS formbox\$o" 105*4c8945a0SNathan Whitehorn AC_DEFINE(HAVE_DLG_FORMBOX)],,$cf_all_widgets) 106*4c8945a0SNathan Whitehorn 107*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want the gauge dialog], 108*4c8945a0SNathan Whitehorn gauge, 109*4c8945a0SNathan Whitehorn [ --disable-gauge do not include the gauge dialogs], 110*4c8945a0SNathan Whitehorn [EXTRAOBJS="$EXTRAOBJS guage\$o pause\$o progressbox\$o" 111*4c8945a0SNathan Whitehorn AC_DEFINE(HAVE_DLG_GAUGE)],,$cf_all_widgets) 112*4c8945a0SNathan Whitehorn 113*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want the tailbox dialog], 114*4c8945a0SNathan Whitehorn tailbox, 115*4c8945a0SNathan Whitehorn [ --disable-tailbox do not include the tailbox dialog], 116*4c8945a0SNathan Whitehorn [EXTRAOBJS="$EXTRAOBJS tailbox\$o" 117*4c8945a0SNathan Whitehorn AC_DEFINE(HAVE_DLG_TAILBOX)],,$cf_all_widgets) 118*4c8945a0SNathan Whitehorn 119*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want the mixedform dialog], 120*4c8945a0SNathan Whitehorn mixedform, 121*4c8945a0SNathan Whitehorn [ --disable-mixedform do not include the mixedform dialog], 122*4c8945a0SNathan Whitehorn [EXTRAOBJS="$EXTRAOBJS mixedform\$o" 123*4c8945a0SNathan Whitehorn AC_DEFINE(HAVE_DLG_MIXEDFORM)],,$cf_all_widgets) 124*4c8945a0SNathan Whitehorn 125*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want the mixedgauge dialog], 126*4c8945a0SNathan Whitehorn mixedgauge, 127*4c8945a0SNathan Whitehorn [ --disable-mixedgauge do not include the mixedgauge dialog], 128*4c8945a0SNathan Whitehorn [EXTRAOBJS="$EXTRAOBJS mixedgauge\$o" 129*4c8945a0SNathan Whitehorn AC_DEFINE(HAVE_MIXEDGAUGE)],,$cf_all_widgets) 130*4c8945a0SNathan Whitehorn 131*4c8945a0SNathan WhitehornCF_ARG_MSG_ENABLE([if you want the wide-curses features], 132*4c8945a0SNathan Whitehorn widec, 133*4c8945a0SNathan Whitehorn [ --enable-widec enable wide-curses features], 134*4c8945a0SNathan Whitehorn [AC_DEFINE(USE_WIDE_CURSES)],,$cf_wide_curses) 135*4c8945a0SNathan Whitehorn 136*4c8945a0SNathan WhitehornAC_SUBST(EXTRAOBJS) 137*4c8945a0SNathan Whitehorn 138*4c8945a0SNathan Whitehorndnl 139*4c8945a0SNathan Whitehorndnl Checks for header files. 140*4c8945a0SNathan Whitehorndnl 141*4c8945a0SNathan WhitehornAC_HEADER_STDC 142*4c8945a0SNathan WhitehornAC_HEADER_TIME 143*4c8945a0SNathan WhitehornAC_HEADER_DIRENT 144*4c8945a0SNathan WhitehornAC_CHECK_HEADERS(search.h unctrl.h unistd.h) 145*4c8945a0SNathan WhitehornCF_CURSES_TERM_H 146*4c8945a0SNathan Whitehorn 147*4c8945a0SNathan Whitehorndnl 148*4c8945a0SNathan Whitehorndnl Checks for library functions. 149*4c8945a0SNathan Whitehorndnl 150*4c8945a0SNathan WhitehornAC_TYPE_SIGNAL 151*4c8945a0SNathan WhitehornAC_CHECK_FUNCS(\ 152*4c8945a0SNathan Whitehorn_nc_free_and_exit \ 153*4c8945a0SNathan Whitehornstrcasecmp \ 154*4c8945a0SNathan Whitehornstrftime \ 155*4c8945a0SNathan Whitehorntsearch \ 156*4c8945a0SNathan Whitehornwaitpid \ 157*4c8945a0SNathan Whitehorn) 158*4c8945a0SNathan Whitehorn 159*4c8945a0SNathan WhitehornCF_CURSES_FUNCS(\ 160*4c8945a0SNathan Whitehornflushinp \ 161*4c8945a0SNathan Whitehorngetbegx \ 162*4c8945a0SNathan Whitehorngetbegy \ 163*4c8945a0SNathan Whitehorngetbegyx \ 164*4c8945a0SNathan Whitehorngetcurx \ 165*4c8945a0SNathan Whitehorngetcury \ 166*4c8945a0SNathan Whitehorngetmaxx \ 167*4c8945a0SNathan Whitehorngetmaxy \ 168*4c8945a0SNathan Whitehorngetmaxyx \ 169*4c8945a0SNathan Whitehorngetparx \ 170*4c8945a0SNathan Whitehorngetpary \ 171*4c8945a0SNathan Whitehorngetparyx \ 172*4c8945a0SNathan Whitehornuse_default_colors \ 173*4c8945a0SNathan Whitehornwget_wch \ 174*4c8945a0SNathan Whitehorn) 175*4c8945a0SNathan Whitehorn 176*4c8945a0SNathan WhitehornAC_CHECK_FUNC(start_color,[AC_DEFINE(HAVE_COLOR)]) 177*4c8945a0SNathan WhitehornCF_CURSES_CHTYPE 178*4c8945a0SNathan WhitehornCF_FUNC_WAIT 179*4c8945a0SNathan WhitehornCF_MBSTATE_T 180*4c8945a0SNathan Whitehorn 181*4c8945a0SNathan WhitehornCF_HEADERS_SH(DLG,dlg_config.h) 182*4c8945a0SNathan Whitehorn 183*4c8945a0SNathan WhitehornAC_TRY_LINK([#include <locale.h>],[setlocale(LC_ALL, "")],[AC_DEFINE(HAVE_SETLOCALE)]) 184*4c8945a0SNathan Whitehorn 185*4c8945a0SNathan WhitehornCF_DISABLE_RPATH_HACK 186*4c8945a0SNathan Whitehorn 187*4c8945a0SNathan WhitehornAC_OUTPUT(dialog-config makefile $EXTRA_OUTPUT $SUB_MAKEFILE samples/install/makefile,,,sort -u) 188