| 1 | dnl $XTermId: configure.in,v 1.244 2008/03/26 00:55:11 tom Exp $ |
|---|
| 2 | dnl |
|---|
| 3 | dnl --------------------------------------------------------------------------- |
|---|
| 4 | dnl |
|---|
| 5 | dnl Copyright 1997-2007,2008 by Thomas E. Dickey |
|---|
| 6 | dnl |
|---|
| 7 | dnl All Rights Reserved |
|---|
| 8 | dnl |
|---|
| 9 | dnl Permission to use, copy, modify, and distribute this software and its |
|---|
| 10 | dnl documentation for any purpose and without fee is hereby granted, |
|---|
| 11 | dnl provided that the above copyright notice appear in all copies and that |
|---|
| 12 | dnl both that copyright notice and this permission notice appear in |
|---|
| 13 | dnl supporting documentation, and that the name of the above listed |
|---|
| 14 | dnl copyright holder(s) not be used in advertising or publicity pertaining |
|---|
| 15 | dnl to distribution of the software without specific, written prior |
|---|
| 16 | dnl permission. |
|---|
| 17 | dnl |
|---|
| 18 | dnl THE ABOVE LISTED COPYRIGHT HOLDER(S) DISCLAIM ALL WARRANTIES WITH REGARD |
|---|
| 19 | dnl TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY |
|---|
| 20 | dnl AND FITNESS, IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE |
|---|
| 21 | dnl LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES |
|---|
| 22 | dnl WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN |
|---|
| 23 | dnl ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF |
|---|
| 24 | dnl OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
|---|
| 25 | dnl |
|---|
| 26 | dnl --------------------------------------------------------------------------- |
|---|
| 27 | dnl Process this file with autoconf to produce a configure script. |
|---|
| 28 | dnl |
|---|
| 29 | AC_PREREQ(2.13.20030927) |
|---|
| 30 | AC_INIT(charproc.c) |
|---|
| 31 | AC_CONFIG_HEADER(xtermcfg.h:xtermcfg.hin) |
|---|
| 32 | CF_CHECK_CACHE |
|---|
| 33 | |
|---|
| 34 | ### checks for alternative programs |
|---|
| 35 | |
|---|
| 36 | dnl Only add to this case statement when a system has a compiler that is not |
|---|
| 37 | dnl detected by AC_PROG_CC. |
|---|
| 38 | case "$host_os" in |
|---|
| 39 | openedition) : ${CFLAGS="-O2 -Wc,dll -Wl,EDIT=NO"} |
|---|
| 40 | : ${CPPFLAGS="-D_ALL_SOURCE"} |
|---|
| 41 | : ${LIBS="/usr/lib/Xaw.x /usr/lib/SM.x /usr/lib/ICE.x /usr/lib/X11.x"} |
|---|
| 42 | : ${CC=c89};; |
|---|
| 43 | darwin*) |
|---|
| 44 | : ${LDFLAGS}="${LDFLAGS} -Wl,-bind_at_load";; |
|---|
| 45 | esac |
|---|
| 46 | |
|---|
| 47 | AC_PROG_CC |
|---|
| 48 | AC_PROG_CPP |
|---|
| 49 | AC_PROG_GCC_TRADITIONAL |
|---|
| 50 | AC_PROG_AWK |
|---|
| 51 | AC_PROG_INSTALL |
|---|
| 52 | AC_PROG_LN_S |
|---|
| 53 | AC_ARG_PROGRAM |
|---|
| 54 | AC_CHECK_PROGS(LINT, tdlint lint alint) |
|---|
| 55 | |
|---|
| 56 | ### checks for UNIX variants that set C preprocessor variables |
|---|
| 57 | AC_AIX |
|---|
| 58 | AC_ISC_POSIX |
|---|
| 59 | |
|---|
| 60 | ### checks for compiler characteristics |
|---|
| 61 | CF_ANSI_CC_CHECK |
|---|
| 62 | AC_C_CONST |
|---|
| 63 | CF_PROG_EXT |
|---|
| 64 | CF_XOPEN_SOURCE |
|---|
| 65 | CF_SIGWINCH |
|---|
| 66 | |
|---|
| 67 | ### checks for header files |
|---|
| 68 | AC_CHECK_HEADERS( \ |
|---|
| 69 | ncurses/term.h \ |
|---|
| 70 | stdlib.h \ |
|---|
| 71 | sys/ttydefaults.h \ |
|---|
| 72 | term.h \ |
|---|
| 73 | termios.h \ |
|---|
| 74 | unistd.h \ |
|---|
| 75 | wchar.h \ |
|---|
| 76 | ) |
|---|
| 77 | AC_HEADER_TIME |
|---|
| 78 | AM_LANGINFO_CODESET |
|---|
| 79 | |
|---|
| 80 | ### checks for typedefs |
|---|
| 81 | CF_SIG_ATOMIC_T |
|---|
| 82 | CF_SIZE_T |
|---|
| 83 | AC_CHECK_TYPE(time_t, long) |
|---|
| 84 | AC_TYPE_MODE_T |
|---|
| 85 | AC_TYPE_PID_T |
|---|
| 86 | AC_TYPE_UID_T |
|---|
| 87 | AC_TYPE_OFF_T |
|---|
| 88 | |
|---|
| 89 | ### checks for library functions |
|---|
| 90 | AC_CHECK_FUNCS( \ |
|---|
| 91 | bcopy \ |
|---|
| 92 | gethostname \ |
|---|
| 93 | getlogin \ |
|---|
| 94 | memmove \ |
|---|
| 95 | putenv \ |
|---|
| 96 | sched_yield \ |
|---|
| 97 | strerror \ |
|---|
| 98 | strftime \ |
|---|
| 99 | tcgetattr \ |
|---|
| 100 | waitpid \ |
|---|
| 101 | wcswidth \ |
|---|
| 102 | wcwidth ) |
|---|
| 103 | CF_FUNC_MEMMOVE |
|---|
| 104 | CF_UTMP |
|---|
| 105 | CF_STRUCT_LASTLOG |
|---|
| 106 | CF_POSIX_SAVED_IDS |
|---|
| 107 | |
|---|
| 108 | CF_HELP_MESSAGE(Compile/Install Options:) |
|---|
| 109 | CF_FUNC_TGETENT |
|---|
| 110 | |
|---|
| 111 | AC_MSG_CHECKING(for directory to install resource files) |
|---|
| 112 | CF_WITH_PATH(app-defaults, |
|---|
| 113 | [ --with-app-defaults=DIR directory in which to install resource files], |
|---|
| 114 | [appsdir],[EPREFIX/lib/X11/app-defaults], |
|---|
| 115 | ['\$(exec_prefix)/lib/X11/app-defaults']) |
|---|
| 116 | AC_MSG_RESULT($appsdir) |
|---|
| 117 | AC_SUBST(appsdir) |
|---|
| 118 | |
|---|
| 119 | no_appsdir= |
|---|
| 120 | test "$appsdir" = no && no_appsdir="#" |
|---|
| 121 | AC_SUBST(no_appsdir) |
|---|
| 122 | |
|---|
| 123 | AC_MSG_CHECKING(for directory to install icons) |
|---|
| 124 | CF_WITH_PATH(icondir, |
|---|
| 125 | [ --with-icondir=DIR directory in which to install icons], |
|---|
| 126 | [icondir],[EPREFIX/share/pixmaps], |
|---|
| 127 | ['\$(exec_prefix)/share/pixmaps']) |
|---|
| 128 | AC_MSG_RESULT($icondir) |
|---|
| 129 | AC_SUBST(icondir) |
|---|
| 130 | |
|---|
| 131 | no_icondir= |
|---|
| 132 | test "$icondir" = no && no_icondir="#" |
|---|
| 133 | AC_SUBST(no_icondir) |
|---|
| 134 | |
|---|
| 135 | # Comment-out the install-desktop rule if the desktop-utils are not found. |
|---|
| 136 | AC_MSG_CHECKING(if you want to install desktop files) |
|---|
| 137 | CF_ARG_OPTION(desktop, |
|---|
| 138 | [ --disable-desktop disable install of xterm desktop files], |
|---|
| 139 | [enable_desktop=$enableval], |
|---|
| 140 | [enable_desktop=$enableval],yes) |
|---|
| 141 | AC_MSG_RESULT($enable_desktop) |
|---|
| 142 | |
|---|
| 143 | desktop_utils= |
|---|
| 144 | if test "$enable_desktop" = yes ; then |
|---|
| 145 | AC_CHECK_PROG(desktop_utils,desktop-file-install,yes,no) |
|---|
| 146 | fi |
|---|
| 147 | |
|---|
| 148 | test "$desktop_utils" = yes && desktop_utils= || desktop_utils="#" |
|---|
| 149 | AC_SUBST(DESKTOP_FLAGS) |
|---|
| 150 | |
|---|
| 151 | # inherit SINSTALL_OPTS from environment to allow packager to customize it. |
|---|
| 152 | |
|---|
| 153 | AC_MSG_CHECKING(for install-permissions reference) |
|---|
| 154 | AC_ARG_WITH(reference, |
|---|
| 155 | [ --with-reference=XXX program to use as permissions-reference], |
|---|
| 156 | [with_reference=$withval], |
|---|
| 157 | [with_reference=xterm]) |
|---|
| 158 | AC_MSG_RESULT($with_reference) |
|---|
| 159 | |
|---|
| 160 | with_full_paths=yes |
|---|
| 161 | CF_PATH_PROG(XTERM_PATH,$with_reference) |
|---|
| 162 | |
|---|
| 163 | # If any of --program-prefix, --program-suffix or --program-transform-name is |
|---|
| 164 | # given, accept an option tell the makefile to create a symbolic link, e.g., |
|---|
| 165 | # to "xterm" on install. |
|---|
| 166 | XTERM_SYMLINK=NONE |
|---|
| 167 | AC_SUBST(XTERM_SYMLINK) |
|---|
| 168 | if test "$program_transform_name" != "'s,,,'" ; then |
|---|
| 169 | cf_name=`echo "$program_transform_name" | sed -e '[s,\\$\\$,$,g]'` |
|---|
| 170 | cf_name=`echo xterm |sed -e "$cf_name"` |
|---|
| 171 | AC_MSG_CHECKING(for symbolic link to create to $cf_name) |
|---|
| 172 | AC_ARG_WITH(xterm-symlink, |
|---|
| 173 | [ --with-xterm-symlink=XXX make symbolic link to installed xterm], |
|---|
| 174 | [with_symlink=$withval], |
|---|
| 175 | [with_symlink=xterm]) |
|---|
| 176 | AC_MSG_RESULT($with_symlink) |
|---|
| 177 | test "$with_symlink" = yes && with_symlink=xterm |
|---|
| 178 | test -n "$with_symlink" && \ |
|---|
| 179 | test "$with_symlink" != no && \ |
|---|
| 180 | test "$with_symlink" != $cf_name && \ |
|---|
| 181 | XTERM_SYMLINK="$with_symlink" |
|---|
| 182 | fi |
|---|
| 183 | |
|---|
| 184 | AC_MSG_CHECKING(if you want to disable setuid) |
|---|
| 185 | CF_ARG_DISABLE(setuid, |
|---|
| 186 | [ --disable-setuid disable setuid in xterm, do not install setuid/setgid], |
|---|
| 187 | [disable_setuid=yes], |
|---|
| 188 | [disable_setuid=no], |
|---|
| 189 | no) |
|---|
| 190 | AC_MSG_RESULT($disable_setuid) |
|---|
| 191 | |
|---|
| 192 | AC_MSG_CHECKING(if you want to disable setgid) |
|---|
| 193 | CF_ARG_DISABLE(setgid, |
|---|
| 194 | [ --disable-setgid disable setgid in xterm, do not install setuid/setgid], |
|---|
| 195 | [disable_setgid=yes], |
|---|
| 196 | [disable_setgid=no], |
|---|
| 197 | no) |
|---|
| 198 | AC_MSG_RESULT($disable_setgid) |
|---|
| 199 | |
|---|
| 200 | AC_MSG_CHECKING(if you want to run xterm setuid to a given user) |
|---|
| 201 | AC_ARG_WITH(setuid, |
|---|
| 202 | [ --with-setuid=XXX use the given setuid user], |
|---|
| 203 | [use_given_setuid=$withval], |
|---|
| 204 | [use_given_setuid=no]) |
|---|
| 205 | AC_MSG_RESULT($use_given_setuid) |
|---|
| 206 | |
|---|
| 207 | if test "$use_given_setuid" != no ; then |
|---|
| 208 | if test "$use_given_setuid" = yes ; then |
|---|
| 209 | cf_cv_given_setuid=root |
|---|
| 210 | else |
|---|
| 211 | cf_cv_given_setuid=$use_given_setuid |
|---|
| 212 | fi |
|---|
| 213 | SINSTALL_OPTS="$SINSTALL_OPTS u+s -u $cf_cv_given_setuid" |
|---|
| 214 | fi |
|---|
| 215 | |
|---|
| 216 | AC_MSG_CHECKING(if you want to run xterm setgid to match utmp/utmpx file) |
|---|
| 217 | AC_ARG_WITH(utmp-setgid, |
|---|
| 218 | [ --with-utmp-setgid=XXX use setgid to match utmp/utmpx file], |
|---|
| 219 | [use_utmp_setgid=$withval], |
|---|
| 220 | [use_utmp_setgid=no]) |
|---|
| 221 | AC_MSG_RESULT($use_utmp_setgid) |
|---|
| 222 | |
|---|
| 223 | if test "$use_utmp_setgid" != no ; then |
|---|
| 224 | if test "$use_utmp_setgid" = yes ; then |
|---|
| 225 | CF_UTMP_GROUP |
|---|
| 226 | else |
|---|
| 227 | cf_cv_utmp_group=$use_utmp_setgid |
|---|
| 228 | fi |
|---|
| 229 | if test "$cf_cv_posix_saved_ids" != yes ; then |
|---|
| 230 | AC_MSG_ERROR(Your system does not support POSIX saved-ids) |
|---|
| 231 | fi |
|---|
| 232 | AC_DEFINE(USE_UTMP_SETGID) |
|---|
| 233 | SINSTALL_OPTS="$SINSTALL_OPTS g+s -g $cf_cv_utmp_group" |
|---|
| 234 | fi |
|---|
| 235 | |
|---|
| 236 | AC_SUBST(SINSTALL_OPTS) |
|---|
| 237 | |
|---|
| 238 | AC_MSG_CHECKING(if you want to link with utempter) |
|---|
| 239 | AC_ARG_WITH(utempter, |
|---|
| 240 | [ --with-utempter use utempter library for access to utmp], |
|---|
| 241 | [use_utempter=$withval], |
|---|
| 242 | [use_utempter=no]) |
|---|
| 243 | AC_MSG_RESULT($use_utempter) |
|---|
| 244 | |
|---|
| 245 | if test "$use_utempter" = yes ; then |
|---|
| 246 | CF_UTEMPTER |
|---|
| 247 | test "$cf_cv_have_utempter" != yes && use_utempter=no |
|---|
| 248 | else |
|---|
| 249 | use_utempter=no |
|---|
| 250 | fi |
|---|
| 251 | |
|---|
| 252 | # Some configurations permit (or require) either setuid or setgid mode. |
|---|
| 253 | # Let the user decide. |
|---|
| 254 | if test "$use_utempter" = yes ; then |
|---|
| 255 | if test "${enable_setuid+set}" != set ; then |
|---|
| 256 | disable_setuid=yes |
|---|
| 257 | CF_VERBOSE([No --disable-setuid option given, force to yes]) |
|---|
| 258 | fi |
|---|
| 259 | fi |
|---|
| 260 | |
|---|
| 261 | ### checks for external data |
|---|
| 262 | CF_ERRNO |
|---|
| 263 | CF_TTY_GROUP |
|---|
| 264 | |
|---|
| 265 | ### checks for system services and user specified options |
|---|
| 266 | |
|---|
| 267 | CF_POSIX_WAIT |
|---|
| 268 | CF_SYSV |
|---|
| 269 | CF_SVR4 |
|---|
| 270 | CF_X_TOOLKIT |
|---|
| 271 | |
|---|
| 272 | AC_CHECK_HEADERS( \ |
|---|
| 273 | X11/DECkeysym.h \ |
|---|
| 274 | X11/Sunkeysym.h \ |
|---|
| 275 | X11/XF86keysym.h \ |
|---|
| 276 | X11/Xpoll.h \ |
|---|
| 277 | ) |
|---|
| 278 | |
|---|
| 279 | CF_X_ATHENA |
|---|
| 280 | CF_TYPE_FD_MASK |
|---|
| 281 | CF_TERMIO_C_ISPEED |
|---|
| 282 | |
|---|
| 283 | LIBS="$LIBS $X_EXTRA_LIBS" |
|---|
| 284 | |
|---|
| 285 | # Check for openpty() in -lutil if the UNIX98-style pty functions are not |
|---|
| 286 | # available. E.g. for GNU libc 2.0. |
|---|
| 287 | case $host_os in #(vi |
|---|
| 288 | freebsd*|netbsd*) # 2004/8/15 - revisit this if/when grantpt is known to work. |
|---|
| 289 | AC_CHECK_LIB(util,openpty) |
|---|
| 290 | ;; |
|---|
| 291 | *) |
|---|
| 292 | AC_CHECK_FUNCS(grantpt, [], AC_CHECK_LIB(util,openpty)) |
|---|
| 293 | ;; |
|---|
| 294 | esac |
|---|
| 295 | |
|---|
| 296 | CF_XKB_BELL_EXT |
|---|
| 297 | AC_CHECK_FUNCS(Xutf8LookupString, [],[ |
|---|
| 298 | EXTRAHDRS="$EXTRAHDRS xutf8.h" |
|---|
| 299 | EXTRASRCS="$EXTRASRCS xutf8.c" |
|---|
| 300 | EXTRAOBJS="$EXTRAOBJS xutf8.o" |
|---|
| 301 | ]) |
|---|
| 302 | |
|---|
| 303 | CF_WITH_IMAKE_CFLAGS($(MAIN_DEFINES) $(VENDORMANDEFS)) |
|---|
| 304 | |
|---|
| 305 | CF_HELP_MESSAGE(Terminal Configuration:) |
|---|
| 306 | |
|---|
| 307 | AC_MSG_CHECKING(for default terminal-id) |
|---|
| 308 | AC_ARG_WITH(terminal-id, |
|---|
| 309 | [ --with-terminal-id=V set default decTerminalID (default: vt100)], |
|---|
| 310 | [default_termid=$withval], |
|---|
| 311 | [default_termid=vt100]) |
|---|
| 312 | AC_MSG_RESULT($default_termid) |
|---|
| 313 | case $default_termid in |
|---|
| 314 | vt*) default_termid=`echo $default_termid | sed -e 's/^..//'` |
|---|
| 315 | ;; |
|---|
| 316 | esac |
|---|
| 317 | AC_DEFINE_UNQUOTED(DFT_DECID,"$default_termid") |
|---|
| 318 | |
|---|
| 319 | AC_MSG_CHECKING(for default terminal-type) |
|---|
| 320 | AC_ARG_WITH(terminal-type, |
|---|
| 321 | [ --with-terminal-type=T set default $TERM (default: xterm)], |
|---|
| 322 | [default_TERM=$withval], |
|---|
| 323 | [default_TERM=xterm]) |
|---|
| 324 | AC_MSG_RESULT($default_TERM) |
|---|
| 325 | AC_DEFINE_UNQUOTED(DFT_TERMTYPE,"$default_TERM") |
|---|
| 326 | |
|---|
| 327 | AC_MSG_CHECKING(for private terminfo-directory) |
|---|
| 328 | AC_ARG_WITH(own-terminfo, |
|---|
| 329 | [ --with-own-terminfo=P set default $TERMINFO (default: from environment)], |
|---|
| 330 | [TERMINFO_DIR=$withval], |
|---|
| 331 | [TERMINFO_DIR=${TERMINFO-none}]) |
|---|
| 332 | AC_MSG_RESULT($TERMINFO_DIR) |
|---|
| 333 | if test "$TERMINFO_DIR" = yes ; then |
|---|
| 334 | AC_MSG_WARN(no value given) |
|---|
| 335 | elif test "$TERMINFO_DIR" != none ; then |
|---|
| 336 | if test -d $TERMINFO_DIR ; then |
|---|
| 337 | AC_DEFINE_UNQUOTED(OWN_TERMINFO_DIR,"$TERMINFO_DIR") |
|---|
| 338 | else |
|---|
| 339 | AC_MSG_WARN(not a directory) |
|---|
| 340 | fi |
|---|
| 341 | elif test "$prefix" != NONE ; then |
|---|
| 342 | TERMINFO_DIR='${prefix}/lib/terminfo' |
|---|
| 343 | elif test -d /usr/lib/terminfo ; then |
|---|
| 344 | TERMINFO_DIR=/usr/lib/terminfo |
|---|
| 345 | else |
|---|
| 346 | TERMINFO_DIR= |
|---|
| 347 | fi |
|---|
| 348 | SET_TERMINFO= |
|---|
| 349 | if test -n "$TERMINFO_DIR" ; then |
|---|
| 350 | TERMINFO_DIR='$(DESTDIR)'$TERMINFO_DIR |
|---|
| 351 | SET_TERMINFO='TERMINFO=$(TERMINFO_DIR)' |
|---|
| 352 | fi |
|---|
| 353 | AC_SUBST(TERMINFO_DIR) |
|---|
| 354 | AC_SUBST(SET_TERMINFO) |
|---|
| 355 | |
|---|
| 356 | ############################################################################### |
|---|
| 357 | CF_HELP_MESSAGE(Optional Features:) |
|---|
| 358 | |
|---|
| 359 | AC_MSG_CHECKING(if you want active-icons) |
|---|
| 360 | CF_ARG_DISABLE(active-icon, |
|---|
| 361 | [ --disable-active-icon disable X11R6.3 active-icon feature], |
|---|
| 362 | [enable_active_icon=no], |
|---|
| 363 | [enable_active_icon=yes]) |
|---|
| 364 | AC_MSG_RESULT($enable_active_icon) |
|---|
| 365 | if test "$enable_active_icon" = no ; then |
|---|
| 366 | AC_DEFINE(NO_ACTIVE_ICON) |
|---|
| 367 | fi |
|---|
| 368 | |
|---|
| 369 | AC_MSG_CHECKING(if you want ANSI color) |
|---|
| 370 | CF_ARG_DISABLE(ansi-color, |
|---|
| 371 | [ --disable-ansi-color disable ANSI color], |
|---|
| 372 | [enable_ansi_color=no], |
|---|
| 373 | [enable_ansi_color=yes]) |
|---|
| 374 | AC_MSG_RESULT($enable_ansi_color) |
|---|
| 375 | test "$enable_ansi_color" = no && AC_DEFINE(OPT_ISO_COLORS,0) |
|---|
| 376 | |
|---|
| 377 | if test "$enable_ansi_color" = yes ; then |
|---|
| 378 | |
|---|
| 379 | AC_MSG_CHECKING(if you want 16 colors like aixterm) |
|---|
| 380 | CF_ARG_DISABLE(16-color, |
|---|
| 381 | [ --disable-16-color disable 16-color support], |
|---|
| 382 | [enable_16_color=no], |
|---|
| 383 | [enable_16_color=yes]) |
|---|
| 384 | AC_MSG_RESULT($enable_16_color) |
|---|
| 385 | test "$enable_16_color" = no && AC_DEFINE(OPT_AIX_COLORS,0) |
|---|
| 386 | |
|---|
| 387 | AC_MSG_CHECKING(if you want 256 colors) |
|---|
| 388 | CF_ARG_ENABLE(256-color, |
|---|
| 389 | [ --enable-256-color enable 256-color support], |
|---|
| 390 | [enable_256_color=yes], |
|---|
| 391 | [enable_256_color=no]) |
|---|
| 392 | AC_MSG_RESULT($enable_256_color) |
|---|
| 393 | if test "$enable_256_color" = yes ; then |
|---|
| 394 | CHARPROC_DEPS="$CHARPROC_DEPS 256colres.h" |
|---|
| 395 | EXTRAHDRS="$EXTRAHDRS 256colres.h" |
|---|
| 396 | AC_DEFINE(OPT_256_COLORS,1) |
|---|
| 397 | else |
|---|
| 398 | AC_MSG_CHECKING(if you want 88 colors) |
|---|
| 399 | CF_ARG_ENABLE(88-color, |
|---|
| 400 | [ --enable-88-color enable 88-color support], |
|---|
| 401 | [enable_88_color=yes], |
|---|
| 402 | [enable_88_color=no]) |
|---|
| 403 | AC_MSG_RESULT($enable_88_color) |
|---|
| 404 | if test "$enable_88_color" = yes ; then |
|---|
| 405 | CHARPROC_DEPS="$CHARPROC_DEPS 88colres.h" |
|---|
| 406 | EXTRAHDRS="$EXTRAHDRS 88colres.h" |
|---|
| 407 | AC_DEFINE(OPT_88_COLORS,1) |
|---|
| 408 | fi |
|---|
| 409 | fi |
|---|
| 410 | |
|---|
| 411 | fi |
|---|
| 412 | |
|---|
| 413 | AC_MSG_CHECKING(if you want blinking cursor) |
|---|
| 414 | CF_ARG_DISABLE(blink-cursor, |
|---|
| 415 | [ --disable-blink-cursor disable support for blinking cursor], |
|---|
| 416 | [enable_blink_curs=no], |
|---|
| 417 | [enable_blink_curs=yes]) |
|---|
| 418 | AC_MSG_RESULT($enable_blink_curs) |
|---|
| 419 | test "$enable_blink_curs" = no && AC_DEFINE(OPT_BLINK_CURS,0) |
|---|
| 420 | |
|---|
| 421 | AC_MSG_CHECKING(if you want to ignore Linux's broken palette-strings) |
|---|
| 422 | |
|---|
| 423 | case $host_os in #(vi |
|---|
| 424 | linux*) |
|---|
| 425 | assume_broken_osc=yes ;; #(vi |
|---|
| 426 | *) |
|---|
| 427 | assume_broken_osc=no ;; |
|---|
| 428 | esac |
|---|
| 429 | |
|---|
| 430 | CF_ARG_OPTION(broken-osc, |
|---|
| 431 | [ --enable-broken-osc allow broken Linux OSC-strings], |
|---|
| 432 | [enable_broken_osc=$enableval], |
|---|
| 433 | [enable_broken_osc=$enableval], |
|---|
| 434 | [$assume_broken_osc]) |
|---|
| 435 | AC_MSG_RESULT($enable_broken_osc) |
|---|
| 436 | if test "$enable_broken_osc" = yes ; then |
|---|
| 437 | AC_DEFINE(OPT_BROKEN_OSC,1) |
|---|
| 438 | else |
|---|
| 439 | AC_DEFINE(OPT_BROKEN_OSC,0) |
|---|
| 440 | fi |
|---|
| 441 | |
|---|
| 442 | AC_MSG_CHECKING(if you want to allow broken string-terminators) |
|---|
| 443 | CF_ARG_ENABLE(broken-st, |
|---|
| 444 | [ --enable-broken-st allow broken string-terminators], |
|---|
| 445 | [enable_broken_st=yes], |
|---|
| 446 | [enable_broken_st=no]) |
|---|
| 447 | AC_MSG_RESULT($enable_broken_st) |
|---|
| 448 | test "$enable_broken_st" = no && AC_DEFINE(OPT_BROKEN_ST,0) |
|---|
| 449 | |
|---|
| 450 | AC_MSG_CHECKING(if you want printable 128-159) |
|---|
| 451 | CF_ARG_DISABLE(c1-print, |
|---|
| 452 | [ --disable-c1-print disallow -k8 option for printable 128-159], |
|---|
| 453 | [enable_c1_print=no], |
|---|
| 454 | [enable_c1_print=yes]) |
|---|
| 455 | AC_MSG_RESULT($enable_c1_print) |
|---|
| 456 | test "$enable_c1_print" = no && AC_DEFINE(OPT_C1_PRINT,0) |
|---|
| 457 | |
|---|
| 458 | if test "$enable_ansi_color" = yes ; then |
|---|
| 459 | |
|---|
| 460 | AC_MSG_CHECKING(if you want bold colors mapped like IBM PC) |
|---|
| 461 | CF_ARG_DISABLE(bold-color, |
|---|
| 462 | [ --disable-bold-color disable PC-style mapping of bold colors], |
|---|
| 463 | [enable_pc_color=no], |
|---|
| 464 | [enable_pc_color=yes]) |
|---|
| 465 | AC_MSG_RESULT($enable_pc_color) |
|---|
| 466 | test "$enable_pc_color" = no && AC_DEFINE(OPT_PC_COLORS,0) |
|---|
| 467 | |
|---|
| 468 | AC_MSG_CHECKING(if you want separate color-classes) |
|---|
| 469 | CF_ARG_DISABLE(color-class, |
|---|
| 470 | [ --disable-color-class disable separate color class resources], |
|---|
| 471 | [enable_color_class=no], |
|---|
| 472 | [enable_color_class=yes]) |
|---|
| 473 | AC_MSG_RESULT($enable_color_class) |
|---|
| 474 | test "$enable_color_class" = no && AC_DEFINE(OPT_COLOR_CLASS,FALSE) |
|---|
| 475 | |
|---|
| 476 | AC_MSG_CHECKING(if you want color-mode enabled by default) |
|---|
| 477 | CF_ARG_DISABLE(color-mode, |
|---|
| 478 | [ --disable-color-mode disable default colorMode resource], |
|---|
| 479 | [default_colormode=no], |
|---|
| 480 | [default_colormode=yes]) |
|---|
| 481 | AC_MSG_RESULT($default_colormode) |
|---|
| 482 | test "$default_colormode" = no && AC_DEFINE(DFT_COLORMODE,FALSE) |
|---|
| 483 | |
|---|
| 484 | fi |
|---|
| 485 | |
|---|
| 486 | AC_MSG_CHECKING(if you want support for color highlighting) |
|---|
| 487 | CF_ARG_DISABLE(highlighting, |
|---|
| 488 | [ --disable-highlighting disable support for color highlighting], |
|---|
| 489 | [default_highlight=no], |
|---|
| 490 | [default_highlight=yes]) |
|---|
| 491 | AC_MSG_RESULT($default_highlight) |
|---|
| 492 | test "$default_highlight" = no && AC_DEFINE(OPT_HIGHLIGHT_COLOR,0) |
|---|
| 493 | |
|---|
| 494 | AC_MSG_CHECKING(if you want support for doublesize characters) |
|---|
| 495 | CF_ARG_DISABLE(doublechars, |
|---|
| 496 | [ --disable-doublechars disable support for double-size chars], |
|---|
| 497 | [enable_doublechars=no], |
|---|
| 498 | [enable_doublechars=yes]) |
|---|
| 499 | AC_MSG_RESULT($enable_doublechars) |
|---|
| 500 | test "$enable_doublechars" = no && AC_DEFINE(OPT_DEC_CHRSET,0) |
|---|
| 501 | |
|---|
| 502 | AC_MSG_CHECKING(if you want fallback-support for box characters) |
|---|
| 503 | CF_ARG_DISABLE(boxchars, |
|---|
| 504 | [ --disable-boxchars disable fallback-support for box chars], |
|---|
| 505 | [enable_boxchars=no], |
|---|
| 506 | [enable_boxchars=yes]) |
|---|
| 507 | AC_MSG_RESULT($enable_boxchars) |
|---|
| 508 | test "$enable_boxchars" = no && AC_DEFINE(OPT_BOX_CHARS,0) |
|---|
| 509 | |
|---|
| 510 | AC_MSG_CHECKING(if you want to allow spawning new xterms) |
|---|
| 511 | CF_ARG_ENABLE(exec-xterm, |
|---|
| 512 | [ --enable-exec-xterm enable "spawn-new-terminal" action], |
|---|
| 513 | [enable_exec_xterm=yes], |
|---|
| 514 | [enable_exec_xterm=no]) |
|---|
| 515 | AC_MSG_RESULT($enable_exec_xterm) |
|---|
| 516 | if test "$enable_exec_xterm" = yes ; then |
|---|
| 517 | CF_PROCFS_CWD |
|---|
| 518 | if test "$cf_cv_procfs_cwd" = no ; then |
|---|
| 519 | AC_MSG_WARN(no suitable proc filesystem found) |
|---|
| 520 | else |
|---|
| 521 | AC_DEFINE_UNQUOTED(PROCFS_ROOT,"$cf_cv_procfs_cwd") |
|---|
| 522 | AC_DEFINE(OPT_EXEC_XTERM) |
|---|
| 523 | fi |
|---|
| 524 | fi |
|---|
| 525 | |
|---|
| 526 | AC_MSG_CHECKING(if you want to use FreeType library) |
|---|
| 527 | CF_ARG_DISABLE(freetype, |
|---|
| 528 | [ --disable-freetype disable freetype library-support], |
|---|
| 529 | [enable_freetype=no], |
|---|
| 530 | [enable_freetype=yes]) |
|---|
| 531 | AC_MSG_RESULT($enable_freetype) |
|---|
| 532 | if test "$enable_freetype" = yes ; then |
|---|
| 533 | CF_X_FREETYPE |
|---|
| 534 | else |
|---|
| 535 | CPPFLAGS=`echo "$CPPFLAGS" | sed -e s/-DXRENDERFONT//` |
|---|
| 536 | fi |
|---|
| 537 | |
|---|
| 538 | AC_MSG_CHECKING(if you want support for HP-style function keys) |
|---|
| 539 | CF_ARG_ENABLE(hp-fkeys, |
|---|
| 540 | [ --enable-hp-fkeys enable support for HP-style function keys], |
|---|
| 541 | [enable_hp_fkeys=yes], |
|---|
| 542 | [enable_hp_fkeys=no]) |
|---|
| 543 | AC_MSG_RESULT($enable_hp_fkeys) |
|---|
| 544 | if test "$enable_hp_fkeys" = yes ; then |
|---|
| 545 | AC_DEFINE(OPT_HP_FUNC_KEYS,1) |
|---|
| 546 | fi |
|---|
| 547 | |
|---|
| 548 | AC_MSG_CHECKING(if you want support for SCO-style function keys) |
|---|
| 549 | CF_ARG_ENABLE(sco-fkeys, |
|---|
| 550 | [ --enable-sco-fkeys enable support for SCO-style function keys], |
|---|
| 551 | [enable_sco_fkeys=yes], |
|---|
| 552 | [enable_sco_fkeys=no]) |
|---|
| 553 | AC_MSG_RESULT($enable_sco_fkeys) |
|---|
| 554 | if test "$enable_sco_fkeys" = yes ; then |
|---|
| 555 | AC_DEFINE(OPT_SCO_FUNC_KEYS,1) |
|---|
| 556 | fi |
|---|
| 557 | |
|---|
| 558 | AC_MSG_CHECKING(if you want support for Sun-style function keys) |
|---|
| 559 | CF_ARG_DISABLE(sun-fkeys, |
|---|
| 560 | [ --disable-sun-fkeys disable support for Sun-style function keys], |
|---|
| 561 | [enable_sun_fkeys=no], |
|---|
| 562 | [enable_sun_fkeys=yes]) |
|---|
| 563 | AC_MSG_RESULT($enable_sun_fkeys) |
|---|
| 564 | if test "$enable_sun_fkeys" = no ; then |
|---|
| 565 | AC_DEFINE(OPT_SUN_FUNC_KEYS,0) |
|---|
| 566 | fi |
|---|
| 567 | |
|---|
| 568 | AC_MSG_CHECKING(if you want support for internationalization) |
|---|
| 569 | CF_ARG_DISABLE(i18n, |
|---|
| 570 | [ --disable-i18n disable internationalization], |
|---|
| 571 | [enable_i18n=no], |
|---|
| 572 | [enable_i18n=yes]) |
|---|
| 573 | AC_MSG_RESULT($enable_i18n) |
|---|
| 574 | if test "$enable_i18n" = no ; then |
|---|
| 575 | AC_DEFINE(OPT_I18N_SUPPORT,0) |
|---|
| 576 | fi |
|---|
| 577 | |
|---|
| 578 | AC_MSG_CHECKING(if you want support for initial-erase setup) |
|---|
| 579 | CF_ARG_DISABLE(initial-erase, |
|---|
| 580 | [ --disable-initial-erase disable setup for stty erase], |
|---|
| 581 | [enable_ie=no], |
|---|
| 582 | [enable_ie=yes]) |
|---|
| 583 | AC_MSG_RESULT($enable_ie) |
|---|
| 584 | if test "$enable_ie" = no ; then |
|---|
| 585 | AC_DEFINE(OPT_INITIAL_ERASE,0) |
|---|
| 586 | fi |
|---|
| 587 | |
|---|
| 588 | AC_MSG_CHECKING(if you want support for input-method) |
|---|
| 589 | CF_ARG_DISABLE(input-method, |
|---|
| 590 | [ --disable-input-method disable input-method], |
|---|
| 591 | [enable_ximp=no], |
|---|
| 592 | [enable_ximp=yes]) |
|---|
| 593 | AC_MSG_RESULT($enable_ximp) |
|---|
| 594 | CF_INPUT_METHOD |
|---|
| 595 | test "$cf_cv_input_method" = no && enable_ximp=no |
|---|
| 596 | if test "$enable_ximp" = no ; then |
|---|
| 597 | AC_DEFINE(OPT_INPUT_METHOD,0) |
|---|
| 598 | fi |
|---|
| 599 | |
|---|
| 600 | AC_MSG_CHECKING(if you want support for load-vt-fonts) |
|---|
| 601 | CF_ARG_ENABLE(load-vt-fonts, |
|---|
| 602 | [ --enable-load-vt-fonts enable load-vt-fonts() action], |
|---|
| 603 | [enable_load_vt_fonts=yes], |
|---|
| 604 | [enable_load_vt_fonts=no]) |
|---|
| 605 | AC_MSG_RESULT($enable_load_vt_fonts) |
|---|
| 606 | if test "$enable_load_vt_fonts" = yes ; then |
|---|
| 607 | AC_DEFINE(OPT_LOAD_VTFONTS,1) |
|---|
| 608 | fi |
|---|
| 609 | |
|---|
| 610 | AC_MSG_CHECKING(if you want support for logging) |
|---|
| 611 | CF_ARG_ENABLE(logging, |
|---|
| 612 | [ --enable-logging enable logging], |
|---|
| 613 | [enable_logging=yes], |
|---|
| 614 | [enable_logging=no]) |
|---|
| 615 | AC_MSG_RESULT($enable_logging) |
|---|
| 616 | if test "$enable_logging" = yes ; then |
|---|
| 617 | AC_DEFINE(ALLOWLOGGING) |
|---|
| 618 | AC_MSG_CHECKING(if you want to allow logging via a pipe) |
|---|
| 619 | CF_ARG_ENABLE(logfile-exec, |
|---|
| 620 | [ --enable-logfile-exec enable exec'd logfile filter], |
|---|
| 621 | [enable_log_exec=yes], |
|---|
| 622 | [enable_log_exec=no]) |
|---|
| 623 | AC_MSG_RESULT($enable_log_exec) |
|---|
| 624 | if test "$enable_log_exec" = yes ; then |
|---|
| 625 | AC_DEFINE(ALLOWLOGFILEEXEC) |
|---|
| 626 | fi |
|---|
| 627 | fi |
|---|
| 628 | |
|---|
| 629 | AC_MSG_CHECKING(if you want support for iconify/maximize translations) |
|---|
| 630 | CF_ARG_DISABLE(maximize, |
|---|
| 631 | [ --disable-maximize disable actions for iconify/deiconify/maximize/restore], |
|---|
| 632 | [enable_maximize=no], |
|---|
| 633 | [enable_maximize=yes]) |
|---|
| 634 | AC_MSG_RESULT($enable_maximize) |
|---|
| 635 | test "$enable_maximize" = no && AC_DEFINE(OPT_MAXIMIZE,0) |
|---|
| 636 | |
|---|
| 637 | AC_MSG_CHECKING(if you want NumLock to override keyboard tables) |
|---|
| 638 | CF_ARG_DISABLE(num-lock, |
|---|
| 639 | [ --disable-num-lock disable NumLock keypad support], |
|---|
| 640 | [enable_numlock=no], |
|---|
| 641 | [enable_numlock=yes]) |
|---|
| 642 | AC_MSG_RESULT($enable_numlock) |
|---|
| 643 | test "$enable_numlock" = no && AC_DEFINE(OPT_NUM_LOCK,0) |
|---|
| 644 | |
|---|
| 645 | AC_MSG_CHECKING(if you want support for get/set of base64 selection data) |
|---|
| 646 | |
|---|
| 647 | CF_ARG_ENABLE(paste64, |
|---|
| 648 | [ --enable-paste64 enable get/set base64 selection data], |
|---|
| 649 | [enable_paste64=yes], |
|---|
| 650 | [enable_paste64=no]) |
|---|
| 651 | AC_MSG_RESULT($enable_paste64) |
|---|
| 652 | if test "$enable_paste64" = yes ; then |
|---|
| 653 | AC_DEFINE(OPT_PASTE64,1) |
|---|
| 654 | else |
|---|
| 655 | AC_DEFINE(OPT_PASTE64,0) |
|---|
| 656 | fi |
|---|
| 657 | |
|---|
| 658 | AC_MSG_CHECKING(if you want support for pty-handshaking) |
|---|
| 659 | |
|---|
| 660 | CF_ARG_DISABLE(pty-handshake, |
|---|
| 661 | [ --disable-pty-handshake disable pty-handshake support], |
|---|
| 662 | [enable_pty_handshake=no], |
|---|
| 663 | [enable_pty_handshake=yes]) |
|---|
| 664 | AC_MSG_RESULT($enable_pty_handshake) |
|---|
| 665 | if test "$enable_pty_handshake" = yes ; then |
|---|
| 666 | AC_DEFINE(OPT_PTY_HANDSHAKE,1) |
|---|
| 667 | else |
|---|
| 668 | AC_DEFINE(OPT_PTY_HANDSHAKE,0) |
|---|
| 669 | fi |
|---|
| 670 | |
|---|
| 671 | AC_MSG_CHECKING(if you want support for mouse in readline applications) |
|---|
| 672 | CF_ARG_ENABLE(readline-mouse, |
|---|
| 673 | [ --enable-readline-mouse enable support for mouse in readline applications], |
|---|
| 674 | [enable_readline_mouse=yes], |
|---|
| 675 | [enable_readline_mouse=no]) |
|---|
| 676 | AC_MSG_RESULT($enable_readline_mouse) |
|---|
| 677 | if test "$enable_readline_mouse" = yes ; then |
|---|
| 678 | AC_DEFINE(OPT_READLINE,1) |
|---|
| 679 | fi |
|---|
| 680 | |
|---|
| 681 | AC_MSG_CHECKING(if you want support for regular-expression selections) |
|---|
| 682 | CF_ARG_DISABLE(regex, |
|---|
| 683 | [ --disable-regex disable regular-expression selections], |
|---|
| 684 | [enable_regex=no], |
|---|
| 685 | [enable_regex=yes]) |
|---|
| 686 | AC_MSG_RESULT($enable_regex) |
|---|
| 687 | if test "$enable_regex" = yes ; then |
|---|
| 688 | CF_WITH_PCRE |
|---|
| 689 | if test "$with_pcre" = no ; then |
|---|
| 690 | CF_REGEX |
|---|
| 691 | if test "X$cf_cv_regex" != "Xregex.h" ; then |
|---|
| 692 | AC_MSG_ERROR(Only POSIX or PCRE regular expressions are supported) |
|---|
| 693 | fi |
|---|
| 694 | fi |
|---|
| 695 | AC_DEFINE(OPT_SELECT_REGEX) |
|---|
| 696 | fi |
|---|
| 697 | |
|---|
| 698 | AC_MSG_CHECKING(if you want support for right-scrollbar) |
|---|
| 699 | CF_ARG_DISABLE(rightbar, |
|---|
| 700 | [ --disable-rightbar disable right-scrollbar support], |
|---|
| 701 | [enable_rightbar=no], |
|---|
| 702 | [enable_rightbar=yes]) |
|---|
| 703 | AC_MSG_RESULT($enable_rightbar) |
|---|
| 704 | if test "$enable_rightbar" = yes ; then |
|---|
| 705 | AC_DEFINE(SCROLLBAR_RIGHT) |
|---|
| 706 | fi |
|---|
| 707 | |
|---|
| 708 | AC_MSG_CHECKING(if you want check for redundant name-change) |
|---|
| 709 | CF_ARG_DISABLE(samename, |
|---|
| 710 | [ --disable-samename disable check for redundant name-change], |
|---|
| 711 | [enable_samename=no], |
|---|
| 712 | [enable_samename=yes]) |
|---|
| 713 | AC_MSG_RESULT($enable_samename) |
|---|
| 714 | test "$enable_samename" = no && AC_DEFINE(OPT_SAME_NAME,0) |
|---|
| 715 | |
|---|
| 716 | AC_MSG_CHECKING(if you want support for session management) |
|---|
| 717 | CF_ARG_DISABLE(session-mgt, |
|---|
| 718 | [ --disable-session-mgt disable support for session management], |
|---|
| 719 | [enable_session_mgt=no], |
|---|
| 720 | [enable_session_mgt=yes]) |
|---|
| 721 | AC_MSG_RESULT($enable_session_mgt) |
|---|
| 722 | test "$enable_session_mgt" = no && AC_DEFINE(OPT_SESSION_MGT,0) |
|---|
| 723 | |
|---|
| 724 | AC_MSG_CHECKING(if you want to use termcap function-keys) |
|---|
| 725 | CF_ARG_DISABLE(tcap-fkeys, |
|---|
| 726 | [ --disable-tcap-fkeys disable termcap function-keys support], |
|---|
| 727 | [enable_tcap_fkeys=no], |
|---|
| 728 | [enable_tcap_fkeys=yes]) |
|---|
| 729 | AC_MSG_RESULT($enable_tcap_fkeys) |
|---|
| 730 | test "$enable_tcap_fkeys" = yes && AC_DEFINE(OPT_TCAP_FKEYS,1) |
|---|
| 731 | |
|---|
| 732 | AC_MSG_CHECKING(if you want to use termcap-query/report) |
|---|
| 733 | CF_ARG_ENABLE(tcap-query, |
|---|
| 734 | [ --enable-tcap-query compile-in termcap-query support], |
|---|
| 735 | [enable_tcap_query=yes], |
|---|
| 736 | [enable_tcap_query=no]) |
|---|
| 737 | AC_MSG_RESULT($enable_tcap_query) |
|---|
| 738 | test "$enable_tcap_query" = yes && AC_DEFINE(OPT_TCAP_QUERY,1) |
|---|
| 739 | |
|---|
| 740 | AC_MSG_CHECKING(if you want support for tek4014) |
|---|
| 741 | CF_ARG_DISABLE(tek4014, |
|---|
| 742 | [ --disable-tek4014 disable tek4014 emulation], |
|---|
| 743 | [enable_tek4014=no], |
|---|
| 744 | [enable_tek4014=yes]) |
|---|
| 745 | AC_MSG_RESULT($enable_tek4014) |
|---|
| 746 | if test "$enable_tek4014" = no ; then |
|---|
| 747 | AC_DEFINE(OPT_TEK4014,0) |
|---|
| 748 | else |
|---|
| 749 | EXTRAHDRS="$EXTRAHDRS Tekparse.h" |
|---|
| 750 | EXTRASRCS="$EXTRASRCS TekPrsTbl.c Tekproc.c" |
|---|
| 751 | EXTRAOBJS="$EXTRAOBJS TekPrsTbl.o Tekproc.o" |
|---|
| 752 | fi |
|---|
| 753 | |
|---|
| 754 | AC_MSG_CHECKING(if you want pulldown menus with a toolbar) |
|---|
| 755 | CF_ARG_ENABLE(toolbar, |
|---|
| 756 | [ --enable-toolbar compile-in toolbar for pulldown menus], |
|---|
| 757 | [enable_toolbar=yes], |
|---|
| 758 | [enable_toolbar=no]) |
|---|
| 759 | AC_MSG_RESULT($enable_toolbar) |
|---|
| 760 | if test "$enable_toolbar" = yes ; then |
|---|
| 761 | AC_DEFINE(OPT_TOOLBAR,1) |
|---|
| 762 | fi |
|---|
| 763 | |
|---|
| 764 | AC_MSG_CHECKING(if you want VT52 emulation) |
|---|
| 765 | CF_ARG_DISABLE(vt52, |
|---|
| 766 | [ --disable-vt52 disable VT52 emulation], |
|---|
| 767 | [enable_vt52=no], |
|---|
| 768 | [enable_vt52=yes]) |
|---|
| 769 | AC_MSG_RESULT($enable_vt52) |
|---|
| 770 | test "$enable_vt52" = no && AC_DEFINE(OPT_VT52_MODE,0) |
|---|
| 771 | |
|---|
| 772 | AC_MSG_CHECKING(if you want to use mini-luit/Latin9 built-in support) |
|---|
| 773 | CF_ARG_ENABLE(mini-luit, |
|---|
| 774 | [ --enable-mini-luit enable mini-luit (built-in Latin9 support)], |
|---|
| 775 | [enable_mini_luit=yes], |
|---|
| 776 | [enable_mini_luit=no]) |
|---|
| 777 | AC_MSG_RESULT($enable_mini_luit) |
|---|
| 778 | if test "$enable_mini_luit" = yes ; then |
|---|
| 779 | AC_DEFINE(OPT_MINI_LUIT,1) |
|---|
| 780 | fi |
|---|
| 781 | |
|---|
| 782 | AC_MSG_CHECKING(if you want to use luit) |
|---|
| 783 | CF_ARG_ENABLE(luit, |
|---|
| 784 | [ --enable-luit enable luit filter (Unicode translation)], |
|---|
| 785 | [enable_luit=yes], |
|---|
| 786 | [enable_luit=$enable_mini_luit]) |
|---|
| 787 | AC_MSG_RESULT($enable_luit) |
|---|
| 788 | if test "$enable_luit" = yes ; then |
|---|
| 789 | AC_DEFINE(OPT_LUIT_PROG,1) |
|---|
| 790 | CF_PATH_PROG(LUIT,luit) |
|---|
| 791 | fi |
|---|
| 792 | |
|---|
| 793 | AC_MSG_CHECKING(if you want wide-character support) |
|---|
| 794 | CF_ARG_OPTION(wide-chars, |
|---|
| 795 | [ --enable-wide-chars enable wide-character support], |
|---|
| 796 | [enable_wchar=yes], |
|---|
| 797 | [enable_wchar=$enable_luit], |
|---|
| 798 | [$enable_luit]) |
|---|
| 799 | AC_MSG_RESULT($enable_wchar) |
|---|
| 800 | if test "$enable_wchar" = yes ; then |
|---|
| 801 | AC_DEFINE(OPT_WIDE_CHARS,1) |
|---|
| 802 | EXTRAHDRS="$EXTRAHDRS charclass.h precompose.h wcwidth.h" |
|---|
| 803 | EXTRASRCS="$EXTRASRCS charclass.c precompose.c wcwidth.c" |
|---|
| 804 | EXTRAOBJS="$EXTRAOBJS charclass.o precompose.o wcwidth.o" |
|---|
| 805 | fi |
|---|
| 806 | |
|---|
| 807 | AC_MSG_CHECKING(if you want dynamic-abbreviation support) |
|---|
| 808 | CF_ARG_ENABLE(dabbrev, |
|---|
| 809 | [ --enable-dabbrev enable dynamic-abbreviation support], |
|---|
| 810 | [enable_dabbrev=yes], |
|---|
| 811 | [enable_dabbrev=no]) |
|---|
| 812 | AC_MSG_RESULT($enable_dabbrev) |
|---|
| 813 | if test "$enable_dabbrev" = yes ; then |
|---|
| 814 | AC_DEFINE(OPT_DABBREV,1) |
|---|
| 815 | fi |
|---|
| 816 | |
|---|
| 817 | AC_MSG_CHECKING(if you want DECterm Locator support) |
|---|
| 818 | CF_ARG_ENABLE(dec-locator, |
|---|
| 819 | [ --enable-dec-locator enable DECterm Locator support], |
|---|
| 820 | [enable_dec_locator=yes], |
|---|
| 821 | [enable_dec_locator=no]) |
|---|
| 822 | AC_MSG_RESULT($enable_dec_locator) |
|---|
| 823 | if test "$enable_dec_locator" = yes ; then |
|---|
| 824 | AC_DEFINE(OPT_DEC_LOCATOR,1) |
|---|
| 825 | fi |
|---|
| 826 | |
|---|
| 827 | AC_MSG_CHECKING(if you want VT420 rectangle support) |
|---|
| 828 | CF_ARG_DISABLE(rectangles, |
|---|
| 829 | [ --disable-rectangles disable VT420 rectangle support], |
|---|
| 830 | [enable_rectangles=no], |
|---|
| 831 | [enable_rectangles=yes]) |
|---|
| 832 | AC_MSG_RESULT($enable_rectangles) |
|---|
| 833 | if test "$enable_rectangles" = yes ; then |
|---|
| 834 | AC_DEFINE(OPT_DEC_RECTOPS,1) |
|---|
| 835 | fi |
|---|
| 836 | |
|---|
| 837 | AC_MSG_CHECKING(if you want -ziconbeep option) |
|---|
| 838 | CF_ARG_DISABLE(ziconbeep, |
|---|
| 839 | [ --disable-ziconbeep disable -ziconbeep option], |
|---|
| 840 | [enable_ziconbeep=no], |
|---|
| 841 | [enable_ziconbeep=yes]) |
|---|
| 842 | AC_MSG_RESULT($enable_ziconbeep) |
|---|
| 843 | test "$enable_ziconbeep" = no && AC_DEFINE(OPT_ZICONBEEP,0) |
|---|
| 844 | |
|---|
| 845 | ############################################################################### |
|---|
| 846 | CF_HELP_MESSAGE(Testing/development Options:) |
|---|
| 847 | |
|---|
| 848 | AC_MSG_CHECKING(if you want debugging traces) |
|---|
| 849 | CF_ARG_ENABLE(trace, |
|---|
| 850 | [ --enable-trace test: set to enable debugging traces], |
|---|
| 851 | [enable_trace=yes], |
|---|
| 852 | [enable_trace=no]) |
|---|
| 853 | AC_MSG_RESULT($enable_trace) |
|---|
| 854 | if test "$enable_trace" = yes ; then |
|---|
| 855 | AC_DEFINE(OPT_TRACE) |
|---|
| 856 | EXTRASRCS="$EXTRASRCS trace.c" |
|---|
| 857 | EXTRAOBJS="$EXTRAOBJS trace.o" |
|---|
| 858 | fi |
|---|
| 859 | |
|---|
| 860 | AC_MSG_CHECKING(if you want to test memory leaks) |
|---|
| 861 | CF_ARG_DISABLE(leaks, |
|---|
| 862 | [ --disable-leaks test: set to test memory leaks], |
|---|
| 863 | [disable_leaks=yes], |
|---|
| 864 | [disable_leaks=no]) |
|---|
| 865 | AC_MSG_RESULT($disable_leaks) |
|---|
| 866 | if test "$disable_leaks" = yes ; then |
|---|
| 867 | AC_DEFINE(NO_LEAKS) |
|---|
| 868 | fi |
|---|
| 869 | |
|---|
| 870 | CF_DISABLE_ECHO |
|---|
| 871 | |
|---|
| 872 | AC_MSG_CHECKING(if you want magic cookie emulation) |
|---|
| 873 | CF_ARG_ENABLE(xmc-glitch, |
|---|
| 874 | [ --enable-xmc-glitch test: enable xmc magic-cookie emulation], |
|---|
| 875 | [enable_xmc=yes], |
|---|
| 876 | [enable_xmc=no]) |
|---|
| 877 | AC_MSG_RESULT($enable_xmc) |
|---|
| 878 | if test "$enable_xmc" = yes ; then |
|---|
| 879 | AC_DEFINE(OPT_XMC_GLITCH,1) |
|---|
| 880 | EXTRASRCS="$EXTRASRCS testxmc.c" |
|---|
| 881 | EXTRAOBJS="$EXTRAOBJS testxmc.o" |
|---|
| 882 | fi |
|---|
| 883 | |
|---|
| 884 | dnl FIXME - extra test needed to make tcap-fkeys work on HPUX |
|---|
| 885 | AC_CHECK_FUNCS(tigetstr) |
|---|
| 886 | |
|---|
| 887 | if test -n "$GCC" ; then |
|---|
| 888 | AC_MSG_CHECKING(if you want to turn on gcc warnings) |
|---|
| 889 | CF_ARG_ENABLE(warnings, |
|---|
| 890 | [ --enable-warnings test: turn on GCC compiler warnings], |
|---|
| 891 | [with_warnings=yes], |
|---|
| 892 | [with_warnings=no]) |
|---|
| 893 | AC_MSG_RESULT($with_warnings) |
|---|
| 894 | if test "$with_warnings" = yes |
|---|
| 895 | then |
|---|
| 896 | CF_GCC_ATTRIBUTES |
|---|
| 897 | CF_GCC_WARNINGS(Wdeclaration-after-statement Wextra Wno-unknown-pragmas Wswitch-enum) |
|---|
| 898 | fi |
|---|
| 899 | fi |
|---|
| 900 | |
|---|
| 901 | AC_SUBST(EXTRA_CFLAGS) |
|---|
| 902 | AC_SUBST(CHARPROC_DEPS) |
|---|
| 903 | AC_SUBST(EXTRAHDRS) |
|---|
| 904 | AC_SUBST(EXTRASRCS) |
|---|
| 905 | AC_SUBST(EXTRAOBJS) |
|---|
| 906 | |
|---|
| 907 | test "$disable_setuid" = yes && AC_DEFINE(DISABLE_SETUID) |
|---|
| 908 | test "$disable_setgid" = yes && AC_DEFINE(DISABLE_SETGID) |
|---|
| 909 | |
|---|
| 910 | if test $disable_setuid = yes ; then |
|---|
| 911 | MAY_SETUID="#" |
|---|
| 912 | NOT_SETUID= |
|---|
| 913 | elif test $disable_setgid = yes ; then |
|---|
| 914 | MAY_SETUID="#" |
|---|
| 915 | NOT_SETUID= |
|---|
| 916 | else |
|---|
| 917 | MAY_SETUID= |
|---|
| 918 | NOT_SETUID="#" |
|---|
| 919 | fi |
|---|
| 920 | |
|---|
| 921 | AC_SUBST(MAY_SETUID) |
|---|
| 922 | AC_SUBST(NOT_SETUID) |
|---|
| 923 | |
|---|
| 924 | ### remove from CPPFLAGS the optional features we define in xtermcfg.h |
|---|
| 925 | ### or other conflicting symbols that may be defined via imake: |
|---|
| 926 | for cf_def in \ |
|---|
| 927 | __STDC__ \ |
|---|
| 928 | ALLOWLOGGING \ |
|---|
| 929 | ALLOWLOGFILEEXEC \ |
|---|
| 930 | OPT_LUIT_PROG \ |
|---|
| 931 | OPT_WIDE_CHARS \ |
|---|
| 932 | SCROLLBAR_RIGHT \ |
|---|
| 933 | USE_TTY_GROUP \ |
|---|
| 934 | USE_UTEMPTER \ |
|---|
| 935 | XRENDERFONT |
|---|
| 936 | do |
|---|
| 937 | CPPFLAGS=`echo "$CPPFLAGS" | sed -e s/-D$cf_def//` |
|---|
| 938 | done |
|---|
| 939 | |
|---|
| 940 | ### output Makefile and xtermcfg.h |
|---|
| 941 | AC_OUTPUT(Makefile) |
|---|