Hex Artifact Content
Not logged in

Artifact 0fd9b9796fdc31fd58a8b3702a95e447a804f7ff:


0000: 23 20 2d 2a 2d 20 61 75 74 6f 63 6f 6e 66 20 2d  # -*- autoconf -
0010: 2a 2d 0a 23 20 46 49 4c 45 3a 20 22 2f 64 69 73  *-.# FILE: "/dis
0020: 6b 61 2f 68 6f 6d 65 2f 6a 6f 7a 65 2f 73 72 63  ka/home/joze/src
0030: 2f 74 63 6c 72 65 61 64 6c 69 6e 65 2f 63 6f 6e  /tclreadline/con
0040: 66 69 67 75 72 65 2e 69 6e 22 0a 23 20 4c 41 53  figure.in".# LAS
0050: 54 20 4d 4f 44 49 46 49 43 41 54 49 4f 4e 3a 20  T MODIFICATION: 
0060: 22 57 65 64 20 53 65 70 20 20 38 20 31 38 3a 31  "Wed Sep  8 18:1
0070: 38 3a 30 32 20 31 39 39 39 20 28 6a 6f 7a 65 29  8:02 1999 (joze)
0080: 22 0a 23 20 28 43 29 20 31 39 39 38 2c 20 31 39  ".# (C) 1998, 19
0090: 39 39 20 62 79 20 4a 6f 68 61 6e 6e 65 73 20 5a  99 by Johannes Z
00a0: 65 6c 6c 6e 65 72 2c 20 3c 6a 6f 68 61 6e 6e 65  ellner, <johanne
00b0: 73 40 7a 65 6c 6c 6e 65 72 2e 6f 72 67 3e 0a 23  s@zellner.org>.#
00c0: 20 24 49 64 24 0a 23 20 2d 2d 2d 0a 23 0a 23 20   $Id$.# ---.#.# 
00d0: 74 63 6c 72 65 61 64 6c 69 6e 65 20 2d 2d 20 67  tclreadline -- g
00e0: 6e 75 20 72 65 61 64 6c 69 6e 65 20 66 6f 72 20  nu readline for 
00f0: 74 63 6c 0a 23 20 43 6f 70 79 72 69 67 68 74 20  tcl.# Copyright 
0100: 28 43 29 20 31 39 39 39 20 20 4a 6f 68 61 6e 6e  (C) 1999  Johann
0110: 65 73 20 5a 65 6c 6c 6e 65 72 0a 23 0a 23 20 54  es Zellner.#.# T
0120: 68 69 73 20 70 72 6f 67 72 61 6d 20 69 73 20 66  his program is f
0130: 72 65 65 20 73 6f 66 74 77 61 72 65 3b 20 79 6f  ree software; yo
0140: 75 20 63 61 6e 20 72 65 64 69 73 74 72 69 62 75  u can redistribu
0150: 74 65 20 69 74 20 61 6e 64 2f 6f 72 0a 23 20 6d  te it and/or.# m
0160: 6f 64 69 66 79 20 69 74 20 75 6e 64 65 72 20 74  odify it under t
0170: 68 65 20 74 65 72 6d 73 20 6f 66 20 74 68 65 20  he terms of the 
0180: 47 4e 55 20 47 65 6e 65 72 61 6c 20 50 75 62 6c  GNU General Publ
0190: 69 63 20 4c 69 63 65 6e 73 65 0a 23 20 61 73 20  ic License.# as 
01a0: 70 75 62 6c 69 73 68 65 64 20 62 79 20 74 68 65  published by the
01b0: 20 46 72 65 65 20 53 6f 66 74 77 61 72 65 20 46   Free Software F
01c0: 6f 75 6e 64 61 74 69 6f 6e 3b 20 65 69 74 68 65  oundation; eithe
01d0: 72 20 76 65 72 73 69 6f 6e 20 32 0a 23 20 6f 66  r version 2.# of
01e0: 20 74 68 65 20 4c 69 63 65 6e 73 65 2c 20 6f 72   the License, or
01f0: 20 28 61 74 20 79 6f 75 72 20 6f 70 74 69 6f 6e   (at your option
0200: 29 20 61 6e 79 20 6c 61 74 65 72 20 76 65 72 73  ) any later vers
0210: 69 6f 6e 2e 0a 23 0a 23 20 54 68 69 73 20 70 72  ion..#.# This pr
0220: 6f 67 72 61 6d 20 69 73 20 64 69 73 74 72 69 62  ogram is distrib
0230: 75 74 65 64 20 69 6e 20 74 68 65 20 68 6f 70 65  uted in the hope
0240: 20 74 68 61 74 20 69 74 20 77 69 6c 6c 20 62 65   that it will be
0250: 20 75 73 65 66 75 6c 2c 0a 23 20 62 75 74 20 57   useful,.# but W
0260: 49 54 48 4f 55 54 20 41 4e 59 20 57 41 52 52 41  ITHOUT ANY WARRA
0270: 4e 54 59 3b 20 77 69 74 68 6f 75 74 20 65 76 65  NTY; without eve
0280: 6e 20 74 68 65 20 69 6d 70 6c 69 65 64 20 77 61  n the implied wa
0290: 72 72 61 6e 74 79 20 6f 66 0a 23 20 4d 45 52 43  rranty of.# MERC
02a0: 48 41 4e 54 41 42 49 4c 49 54 59 20 6f 72 20 46  HANTABILITY or F
02b0: 49 54 4e 45 53 53 20 46 4f 52 20 41 20 50 41 52  ITNESS FOR A PAR
02c0: 54 49 43 55 4c 41 52 20 50 55 52 50 4f 53 45 2e  TICULAR PURPOSE.
02d0: 20 20 53 65 65 20 74 68 65 0a 23 20 47 4e 55 20    See the.# GNU 
02e0: 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c  General Public L
02f0: 69 63 65 6e 73 65 20 66 6f 72 20 6d 6f 72 65 20  icense for more 
0300: 64 65 74 61 69 6c 73 2e 0a 23 0a 23 20 59 6f 75  details..#.# You
0310: 20 73 68 6f 75 6c 64 20 68 61 76 65 20 72 65 63   should have rec
0320: 65 69 76 65 64 20 61 20 63 6f 70 79 20 6f 66 20  eived a copy of 
0330: 74 68 65 20 47 4e 55 20 47 65 6e 65 72 61 6c 20  the GNU General 
0340: 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 0a 23  Public License.#
0350: 20 61 6c 6f 6e 67 20 77 69 74 68 20 74 68 69 73   along with this
0360: 20 70 72 6f 67 72 61 6d 3b 20 69 66 20 6e 6f 74   program; if not
0370: 2c 20 77 72 69 74 65 20 74 6f 20 74 68 65 20 46  , write to the F
0380: 72 65 65 20 53 6f 66 74 77 61 72 65 0a 23 20 46  ree Software.# F
0390: 6f 75 6e 64 61 74 69 6f 6e 2c 20 49 6e 63 2e 2c  oundation, Inc.,
03a0: 20 35 39 20 54 65 6d 70 6c 65 20 50 6c 61 63 65   59 Temple Place
03b0: 20 2d 20 53 75 69 74 65 20 33 33 30 2c 20 42 6f   - Suite 330, Bo
03c0: 73 74 6f 6e 2c 20 4d 41 20 20 30 32 31 31 31 2d  ston, MA  02111-
03d0: 31 33 30 37 2c 20 55 53 41 2e 0a 23 0a 23 20 6a  1307, USA..#.# j
03e0: 6f 68 61 6e 6e 65 73 40 7a 65 6c 6c 6e 65 72 2e  ohannes@zellner.
03f0: 6f 72 67 0a 23 20 68 74 74 70 3a 2f 2f 77 77 77  org.# http://www
0400: 2e 7a 65 6c 6c 6e 65 72 2e 6f 72 67 2f 74 63 6c  .zellner.org/tcl
0410: 72 65 61 64 6c 69 6e 65 2f 0a 23 0a 23 20 3d 3d  readline/.#.# ==
0420: 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d  ================
0430: 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d  ================
0440: 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d  ================
0450: 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d  ================
0460: 20 2a 2f 20 20 0a 0a 64 6e 6c 09 54 68 69 73 20   */  ..dnl.This 
0470: 66 69 6c 65 20 69 73 20 61 6e 20 69 6e 70 75 74  file is an input
0480: 20 66 69 6c 65 20 75 73 65 64 20 62 79 20 74 68   file used by th
0490: 65 20 47 4e 55 20 22 61 75 74 6f 63 6f 6e 66 22  e GNU "autoconf"
04a0: 20 70 72 6f 67 72 61 6d 20 74 6f 0a 64 6e 6c 09   program to.dnl.
04b0: 67 65 6e 65 72 61 74 65 20 74 68 65 20 66 69 6c  generate the fil
04c0: 65 20 22 63 6f 6e 66 69 67 75 72 65 22 2c 20 77  e "configure", w
04d0: 68 69 63 68 20 69 73 20 72 75 6e 20 64 75 72 69  hich is run duri
04e0: 6e 67 20 54 6b 20 69 6e 73 74 61 6c 6c 61 74 69  ng Tk installati
04f0: 6f 6e 0a 64 6e 6c 09 74 6f 20 63 6f 6e 66 69 67  on.dnl.to config
0500: 75 72 65 20 74 68 65 20 73 79 73 74 65 6d 20 66  ure the system f
0510: 6f 72 20 74 68 65 20 6c 6f 63 61 6c 20 65 6e 76  or the local env
0520: 69 72 6f 6e 6d 65 6e 74 2e 0a 0a 41 43 5f 52 45  ironment...AC_RE
0530: 56 49 53 49 4f 4e 28 24 52 65 76 69 73 69 6f 6e  VISION($Revision
0540: 24 29 0a 0a 41 43 5f 49 4e 49 54 28 74 63 6c 72  $)..AC_INIT(tclr
0550: 65 61 64 6c 69 6e 65 2e 63 29 0a 0a 54 43 4c 52  eadline.c)..TCLR
0560: 45 41 44 4c 49 4e 45 5f 4d 41 4a 4f 52 5f 56 45  EADLINE_MAJOR_VE
0570: 52 53 49 4f 4e 3d 30 0a 54 43 4c 52 45 41 44 4c  RSION=0.TCLREADL
0580: 49 4e 45 5f 4d 49 4e 4f 52 5f 56 45 52 53 49 4f  INE_MINOR_VERSIO
0590: 4e 3d 39 0a 54 43 4c 52 45 41 44 4c 49 4e 45 5f  N=9.TCLREADLINE_
05a0: 50 41 54 43 48 4c 45 56 45 4c 3d 33 0a 54 43 4c  PATCHLEVEL=3.TCL
05b0: 52 45 41 44 4c 49 4e 45 5f 56 45 52 53 49 4f 4e  READLINE_VERSION
05c0: 3d 24 54 43 4c 52 45 41 44 4c 49 4e 45 5f 4d 41  =$TCLREADLINE_MA
05d0: 4a 4f 52 5f 56 45 52 53 49 4f 4e 2e 24 54 43 4c  JOR_VERSION.$TCL
05e0: 52 45 41 44 4c 49 4e 45 5f 4d 49 4e 4f 52 5f 56  READLINE_MINOR_V
05f0: 45 52 53 49 4f 4e 0a 54 43 4c 52 45 41 44 4c 49  ERSION.TCLREADLI
0600: 4e 45 5f 50 41 54 43 48 4c 45 56 45 4c 5f 53 54  NE_PATCHLEVEL_ST
0610: 52 3d 24 7b 54 43 4c 52 45 41 44 4c 49 4e 45 5f  R=${TCLREADLINE_
0620: 56 45 52 53 49 4f 4e 7d 2e 24 7b 54 43 4c 52 45  VERSION}.${TCLRE
0630: 41 44 4c 49 4e 45 5f 50 41 54 43 48 4c 45 56 45  ADLINE_PATCHLEVE
0640: 4c 7d 0a 56 45 52 53 49 4f 4e 3d 24 54 43 4c 52  L}.VERSION=$TCLR
0650: 45 41 44 4c 49 4e 45 5f 56 45 52 53 49 4f 4e 0a  EADLINE_VERSION.
0660: 0a 0a 41 43 5f 50 52 45 52 45 51 28 32 2e 31 33  ..AC_PREREQ(2.13
0670: 29 0a 41 43 5f 43 4f 4e 46 49 47 5f 41 55 58 5f  ).AC_CONFIG_AUX_
0680: 44 49 52 28 2e 2f 61 75 78 29 0a 41 43 5f 43 41  DIR(./aux).AC_CA
0690: 4e 4f 4e 49 43 41 4c 5f 48 4f 53 54 0a 0a 0a 54  NONICAL_HOST...T
06a0: 43 4c 52 45 41 44 4c 49 4e 45 5f 4c 50 41 54 48  CLREADLINE_LPATH
06b0: 3d 60 65 63 68 6f 20 24 4c 44 5f 4c 49 42 52 41  =`echo $LD_LIBRA
06c0: 52 59 5f 50 41 54 48 20 24 4c 44 5f 52 55 4e 5f  RY_PATH $LD_RUN_
06d0: 50 41 54 48 20 24 4c 50 41 54 48 20 7c 20 73 65  PATH $LPATH | se
06e0: 64 20 27 73 2f 3a 2f 20 2f 67 27 60 0a 54 43 4c  d 's/:/ /g'`.TCL
06f0: 52 45 41 44 4c 49 4e 45 5f 4c 50 41 54 48 3d 22  READLINE_LPATH="
0700: 24 54 43 4c 52 45 41 44 4c 49 4e 45 5f 4c 50 41  $TCLREADLINE_LPA
0710: 54 48 20 2f 6c 69 62 20 2f 75 73 72 2f 6c 69 62  TH /lib /usr/lib
0720: 20 2f 75 73 72 2f 6c 6f 63 61 6c 2f 6c 69 62 22   /usr/local/lib"
0730: 0a 0a 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ...#------------
0740: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0750: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0760: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0770: 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20 20 20 53 65 65  --------.#   See
0780: 20 69 66 20 74 68 65 72 65 20 77 61 73 20 61 20   if there was a 
0790: 63 6f 6d 6d 61 6e 64 2d 6c 69 6e 65 20 6f 70 74  command-line opt
07a0: 69 6f 6e 20 66 6f 72 20 77 68 65 72 65 20 54 63  ion for where Tc
07b0: 6c 20 69 73 3b 20 20 69 66 0a 23 20 20 20 6e 6f  l is;  if.#   no
07c0: 74 2c 20 73 65 61 72 63 68 20 66 6f 72 20 54 63  t, search for Tc
07d0: 6c 2e 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  l..#------------
07e0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
07f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0800: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0810: 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 41 43 5f 41 52 47  --------..AC_ARG
0820: 5f 57 49 54 48 28 0a 20 20 20 20 74 63 6c 2c 0a  _WITH(.    tcl,.
0830: 20 20 20 20 5b 20 20 2d 2d 77 69 74 68 2d 74 63      [  --with-tc
0840: 6c 3d 44 49 52 20 20 20 20 20 20 20 20 20 20 77  l=DIR          w
0850: 68 65 72 65 20 74 6f 20 6c 6f 6f 6b 20 66 6f 72  here to look for
0860: 20 74 63 6c 43 6f 6e 66 69 67 2e 73 68 5d 2c 0a   tclConfig.sh],.
0870: 20 20 20 20 74 63 6c 5f 73 65 61 72 63 68 3d 24      tcl_search=$
0880: 77 69 74 68 76 61 6c 2c 0a 20 20 20 20 74 63 6c  withval,.    tcl
0890: 5f 73 65 61 72 63 68 3d 22 22 0a 29 0a 0a 41 43  _search="".)..AC
08a0: 5f 4d 53 47 5f 43 48 45 43 4b 49 4e 47 28 5b 77  _MSG_CHECKING([w
08b0: 68 69 63 68 20 74 63 6c 43 6f 6e 66 69 67 2e 73  hich tclConfig.s
08c0: 68 20 74 6f 20 75 73 65 5d 29 0a 54 43 4c 5f 4c  h to use]).TCL_L
08d0: 49 42 5f 44 49 52 3d 22 22 0a 66 6f 72 20 64 69  IB_DIR="".for di
08e0: 72 20 69 6e 20 24 74 63 6c 5f 73 65 61 72 63 68  r in $tcl_search
08f0: 20 2f 75 73 72 2f 6c 69 62 20 2f 75 73 72 2f 6c   /usr/lib /usr/l
0900: 6f 63 61 6c 2f 6c 69 62 20 24 65 78 65 63 5f 70  ocal/lib $exec_p
0910: 72 65 66 69 78 2f 6c 69 62 20 2f 75 73 72 2f 6c  refix/lib /usr/l
0920: 6f 63 61 6c 2f 6c 69 62 2f 75 6e 69 78 20 2f 6f  ocal/lib/unix /o
0930: 70 74 2f 74 63 6c 2f 6c 69 62 3b 20 64 6f 0a 20  pt/tcl/lib; do. 
0940: 20 20 20 69 66 20 74 65 73 74 20 2d 72 20 24 64     if test -r $d
0950: 69 72 2f 74 63 6c 43 6f 6e 66 69 67 2e 73 68 3b  ir/tclConfig.sh;
0960: 20 74 68 65 6e 0a 20 20 20 20 20 20 20 20 54 43   then.        TC
0970: 4c 5f 4c 49 42 5f 44 49 52 3d 24 64 69 72 0a 20  L_LIB_DIR=$dir. 
0980: 20 20 20 20 20 20 20 62 72 65 61 6b 0a 20 20 20         break.   
0990: 20 66 69 0a 64 6f 6e 65 0a 0a 69 66 20 74 65 73   fi.done..if tes
09a0: 74 20 2d 7a 20 22 24 54 43 4c 5f 4c 49 42 5f 44  t -z "$TCL_LIB_D
09b0: 49 52 22 3b 20 74 68 65 6e 0a 20 20 20 20 41 43  IR"; then.    AC
09c0: 5f 4d 53 47 5f 45 52 52 4f 52 28 43 61 6e 27 74  _MSG_ERROR(Can't
09d0: 20 66 69 6e 64 20 54 63 6c 20 6c 69 62 72 61 72   find Tcl librar
09e0: 69 65 73 2e 20 20 55 73 65 20 2d 2d 77 69 74 68  ies.  Use --with
09f0: 2d 74 63 6c 20 74 6f 20 73 70 65 63 69 66 79 20  -tcl to specify 
0a00: 74 68 65 20 64 69 72 65 63 74 6f 72 79 20 63 6f  the directory co
0a10: 6e 74 61 69 6e 69 6e 67 20 74 63 6c 43 6f 6e 66  ntaining tclConf
0a20: 69 67 2e 73 68 20 6f 6e 20 79 6f 75 72 20 73 79  ig.sh on your sy
0a30: 73 74 65 6d 2e 29 0a 65 6c 73 65 0a 20 20 20 20  stem.).else.    
0a40: 2e 20 24 54 43 4c 5f 4c 49 42 5f 44 49 52 2f 74  . $TCL_LIB_DIR/t
0a50: 63 6c 43 6f 6e 66 69 67 2e 73 68 0a 20 20 20 20  clConfig.sh.    
0a60: 41 43 5f 4d 53 47 5f 52 45 53 55 4c 54 28 24 54  AC_MSG_RESULT($T
0a70: 43 4c 5f 4c 49 42 5f 44 49 52 2f 74 63 6c 43 6f  CL_LIB_DIR/tclCo
0a80: 6e 66 69 67 2e 73 68 29 0a 20 20 20 20 41 43 5f  nfig.sh).    AC_
0a90: 4d 53 47 5f 43 48 45 43 4b 49 4e 47 28 5b 66 6f  MSG_CHECKING([fo
0aa0: 72 20 79 6f 75 72 20 74 63 6c 20 76 65 72 73 69  r your tcl versi
0ab0: 6f 6e 5d 29 0a 20 20 20 20 41 43 5f 4d 53 47 5f  on]).    AC_MSG_
0ac0: 52 45 53 55 4c 54 28 5b 24 54 43 4c 5f 56 45 52  RESULT([$TCL_VER
0ad0: 53 49 4f 4e 2c 20 70 61 74 63 68 6c 65 76 65 6c  SION, patchlevel
0ae0: 20 24 54 43 4c 5f 50 41 54 43 48 5f 4c 45 56 45   $TCL_PATCH_LEVE
0af0: 4c 5d 29 0a 66 69 0a 0a 23 2d 2d 2d 2d 2d 2d 2d  L]).fi..#-------
0b00: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0b10: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0b20: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0b30: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20  -------------.# 
0b40: 20 20 52 65 61 64 20 69 6e 20 63 6f 6e 66 69 67    Read in config
0b50: 75 72 61 74 69 6f 6e 20 69 6e 66 6f 72 6d 61 74  uration informat
0b60: 69 6f 6e 20 67 65 6e 65 72 61 74 65 64 20 62 79  ion generated by
0b70: 20 54 63 6c 20 66 6f 72 20 73 68 61 72 65 64 0a   Tcl for shared.
0b80: 23 20 20 20 6c 69 62 72 61 72 69 65 73 2c 20 61  #   libraries, a
0b90: 6e 64 20 61 72 72 61 6e 67 65 20 66 6f 72 20 69  nd arrange for i
0ba0: 74 20 74 6f 20 62 65 20 73 75 62 73 74 69 74 75  t to be substitu
0bb0: 74 65 64 20 69 6e 74 6f 20 6f 75 72 0a 23 20 20  ted into our.#  
0bc0: 20 4d 61 6b 65 66 69 6c 65 2e 0a 23 2d 2d 2d 2d   Makefile..#----
0bd0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0be0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0bf0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0c00: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0c10: 0a 0a 0a 53 48 4c 49 42 5f 43 46 4c 41 47 53 3d  ...SHLIB_CFLAGS=
0c20: 24 54 43 4c 5f 53 48 4c 49 42 5f 43 46 4c 41 47  $TCL_SHLIB_CFLAG
0c30: 53 0a 53 48 4c 49 42 5f 4c 44 3d 24 54 43 4c 5f  S.SHLIB_LD=$TCL_
0c40: 53 48 4c 49 42 5f 4c 44 0a 69 66 20 74 65 73 74  SHLIB_LD.if test
0c50: 20 24 54 43 4c 5f 53 48 4c 49 42 5f 53 55 46 46   $TCL_SHLIB_SUFF
0c60: 49 58 20 3d 20 22 22 3b 20 74 68 65 6e 0a 20 20  IX = ""; then.  
0c70: 20 20 41 43 5f 4d 53 47 5f 45 52 52 4f 52 28 54    AC_MSG_ERROR(T
0c80: 43 4c 5f 53 48 4c 49 42 5f 53 55 46 46 49 58 20  CL_SHLIB_SUFFIX 
0c90: 6e 6f 74 20 64 65 66 69 6e 65 64 20 2d 2d 20 73  not defined -- s
0ca0: 68 6f 75 6c 64 20 62 65 20 73 6f 6d 65 74 68 69  hould be somethi
0cb0: 6e 67 20 6c 69 6b 65 20 2e 73 6f 20 6f 72 20 2e  ng like .so or .
0cc0: 73 6c 20 6f 6e 20 75 6e 69 78 2e 29 0a 65 6c 73  sl on unix.).els
0cd0: 65 0a 20 20 20 20 53 48 4c 49 42 5f 53 55 46 46  e.    SHLIB_SUFF
0ce0: 49 58 3d 24 54 43 4c 5f 53 48 4c 49 42 5f 53 55  IX=$TCL_SHLIB_SU
0cf0: 46 46 49 58 0a 66 69 0a 44 4c 5f 4c 49 42 53 3d  FFIX.fi.DL_LIBS=
0d00: 24 54 43 4c 5f 44 4c 5f 4c 49 42 53 0a 4c 44 5f  $TCL_DL_LIBS.LD_
0d10: 46 4c 41 47 53 3d 24 54 43 4c 5f 4c 44 5f 46 4c  FLAGS=$TCL_LD_FL
0d20: 41 47 53 0a 53 48 4c 49 42 5f 4c 44 5f 4c 49 42  AGS.SHLIB_LD_LIB
0d30: 53 3d 24 54 43 4c 5f 53 48 4c 49 42 5f 4c 44 5f  S=$TCL_SHLIB_LD_
0d40: 4c 49 42 53 0a 54 43 4c 52 45 41 44 4c 49 4e 45  LIBS.TCLREADLINE
0d50: 5f 50 41 43 4b 41 47 45 5f 50 41 54 48 3d 24 54  _PACKAGE_PATH=$T
0d60: 43 4c 5f 50 41 43 4b 41 47 45 5f 50 41 54 48 0a  CL_PACKAGE_PATH.
0d70: 0a 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ..#-------------
0d80: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0d90: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0da0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0db0: 2d 2d 2d 2d 2d 2d 2d 0a 23 20 20 20 43 68 65 63  -------.#   Chec
0dc0: 6b 2c 20 69 66 20 74 63 6c 5f 76 65 72 73 69 6f  k, if tcl_versio
0dd0: 6e 20 69 73 20 3e 20 38 2e 30 0a 23 2d 2d 2d 2d  n is > 8.0.#----
0de0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0df0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0e00: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0e10: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0e20: 0a 69 66 20 74 65 73 74 20 24 54 43 4c 5f 4d 41  .if test $TCL_MA
0e30: 4a 4f 52 5f 56 45 52 53 49 4f 4e 20 2d 6c 74 20  JOR_VERSION -lt 
0e40: 38 3b 20 74 68 65 6e 0a 20 20 20 20 41 43 5f 4d  8; then.    AC_M
0e50: 53 47 5f 45 52 52 4f 52 28 6e 65 65 64 20 74 63  SG_ERROR(need tc
0e60: 6c 20 38 2e 30 20 6f 72 20 68 69 67 68 65 72 2e  l 8.0 or higher.
0e70: 29 0a 66 69 0a 0a 0a 0a 23 20 2d 2d 2d 2d 2d 2d  ).fi....# ------
0e80: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0e90: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0ea0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0eb0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0ec0: 2d 0a 23 20 20 20 53 65 74 20 75 70 20 61 20 6e  -.#   Set up a n
0ed0: 65 77 20 64 65 66 61 75 6c 74 20 2d 2d 70 72 65  ew default --pre
0ee0: 66 69 78 2e 0a 23 20 2d 2d 2d 2d 2d 2d 2d 2d 2d  fix..# ---------
0ef0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0f00: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0f10: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
0f20: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a  --------------..
0f30: 23 20 74 68 69 73 20 69 73 20 74 68 65 20 64 65  # this is the de
0f40: 66 61 75 6c 74 20 61 6e 79 77 61 79 3a 0a 23 20  fault anyway:.# 
0f50: 41 43 5f 50 52 45 46 49 58 5f 44 45 46 41 55 4c  AC_PREFIX_DEFAUL
0f60: 54 28 2f 75 73 72 2f 6c 6f 63 61 6c 29 0a 0a 69  T(/usr/local)..i
0f70: 66 20 74 65 73 74 20 22 24 7b 70 72 65 66 69 78  f test "${prefix
0f80: 7d 22 20 3d 20 22 4e 4f 4e 45 22 3b 20 74 68 65  }" = "NONE"; the
0f90: 6e 0a 20 20 20 20 70 72 65 66 69 78 3d 24 54 43  n.    prefix=$TC
0fa0: 4c 5f 50 52 45 46 49 58 0a 66 69 0a 69 66 20 74  L_PREFIX.fi.if t
0fb0: 65 73 74 20 22 24 7b 65 78 65 63 5f 70 72 65 66  est "${exec_pref
0fc0: 69 78 7d 22 20 3d 20 22 4e 4f 4e 45 22 3b 20 74  ix}" = "NONE"; t
0fd0: 68 65 6e 0a 20 20 20 20 65 78 65 63 5f 70 72 65  hen.    exec_pre
0fe0: 66 69 78 3d 24 54 43 4c 5f 45 58 45 43 5f 50 52  fix=$TCL_EXEC_PR
0ff0: 45 46 49 58 0a 65 6c 73 65 0a 20 20 20 20 54 43  EFIX.else.    TC
1000: 4c 52 45 41 44 4c 49 4e 45 5f 50 41 43 4b 41 47  LREADLINE_PACKAG
1010: 45 5f 50 41 54 48 3d 24 7b 65 78 65 63 5f 70 72  E_PATH=${exec_pr
1020: 65 66 69 78 7d 2f 6c 69 62 0a 66 69 0a 0a 54 43  efix}/lib.fi..TC
1030: 4c 52 45 41 44 4c 49 4e 45 5f 4c 49 42 52 41 52  LREADLINE_LIBRAR
1040: 59 3d 24 7b 65 78 65 63 5f 70 72 65 66 69 78 7d  Y=${exec_prefix}
1050: 2f 6c 69 62 2f 74 63 6c 72 65 61 64 6c 69 6e 65  /lib/tclreadline
1060: 24 54 43 4c 52 45 41 44 4c 49 4e 45 5f 56 45 52  $TCLREADLINE_VER
1070: 53 49 4f 4e 0a 0a 0a 23 20 2d 2d 2d 2d 2d 2d 2d  SION...# -------
1080: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1090: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
10a0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
10b0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
10c0: 0a 23 20 20 20 43 68 65 63 6b 20 66 6f 72 20 73  .#   Check for s
10d0: 6f 6d 65 20 70 72 6f 67 72 61 6d 73 20 68 65 72  ome programs her
10e0: 65 2e 0a 23 20 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  e..# -----------
10f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1100: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1110: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1120: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 41 43  ------------..AC
1130: 5f 50 52 4f 47 5f 49 4e 53 54 41 4c 4c 0a 41 43  _PROG_INSTALL.AC
1140: 5f 50 52 4f 47 5f 52 41 4e 4c 49 42 0a 41 43 5f  _PROG_RANLIB.AC_
1150: 50 52 4f 47 5f 4c 4e 5f 53 0a 0a 0a 0a 23 20 2d  PROG_LN_S....# -
1160: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1170: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1180: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1190: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
11a0: 2d 2d 2d 2d 2d 2d 0a 23 20 20 20 50 72 65 66 65  ------.#   Prefe
11b0: 72 20 74 68 65 20 63 6f 6d 70 69 6c 65 72 2c 20  r the compiler, 
11c0: 77 68 69 63 68 20 77 61 73 20 75 73 65 64 0a 23  which was used.#
11d0: 20 20 20 74 6f 20 62 75 69 6c 64 20 74 63 6c 2e     to build tcl.
11e0: 0a 23 20 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  .# -------------
11f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1200: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1210: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1220: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 0a 41 43 5f  ----------...AC_
1230: 41 52 47 5f 45 4e 41 42 4c 45 28 67 63 63 2c 20  ARG_ENABLE(gcc, 
1240: 5b 20 20 2d 2d 65 6e 61 62 6c 65 2d 67 63 63 20  [  --enable-gcc 
1250: 20 20 20 20 20 20 20 20 20 20 20 61 6c 6c 6f 77             allow
1260: 20 75 73 65 20 6f 66 20 67 63 63 20 69 66 20 61   use of gcc if a
1270: 76 61 69 6c 61 62 6c 65 5d 2c 0a 20 20 20 20 5b  vailable],.    [
1280: 67 63 63 5f 6f 6b 3d 24 65 6e 61 62 6c 65 76 61  gcc_ok=$enableva
1290: 6c 5d 2c 20 5b 67 63 63 5f 6f 6b 3d 6e 6f 5d 29  l], [gcc_ok=no])
12a0: 0a 69 66 20 74 65 73 74 20 22 24 67 63 63 5f 6f  .if test "$gcc_o
12b0: 6b 22 20 3d 20 22 79 65 73 22 3b 20 74 68 65 6e  k" = "yes"; then
12c0: 0a 20 20 20 20 41 43 5f 50 52 4f 47 5f 43 43 0a  .    AC_PROG_CC.
12d0: 65 6c 73 65 0a 20 20 20 20 43 43 3d 24 54 43 4c  else.    CC=$TCL
12e0: 5f 43 43 0a 20 20 20 20 41 43 5f 53 55 42 53 54  _CC.    AC_SUBST
12f0: 28 43 43 29 0a 66 69 0a 0a 0a 0a 0a 23 20 2d 2d  (CC).fi.....# --
1300: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1310: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1320: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1330: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1340: 2d 2d 2d 2d 2d 0a 23 20 20 20 63 68 65 63 6b 69  -----.#   checki
1350: 6e 67 20 66 6f 72 20 74 68 65 20 70 72 65 70 72  ng for the prepr
1360: 6f 63 65 73 73 6f 72 2e 0a 23 20 20 20 46 49 58  ocessor..#   FIX
1370: 4d 45 3a 20 64 6f 20 77 65 20 6e 65 65 64 20 74  ME: do we need t
1380: 68 69 73 20 3f 0a 23 20 2d 2d 2d 2d 2d 2d 2d 2d  his ?.# --------
1390: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
13a0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
13b0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
13c0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a  ---------------.
13d0: 0a 41 43 5f 50 52 4f 47 5f 43 50 50 0a 0a 0a 0a  .AC_PROG_CPP....
13e0: 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  #---------------
13f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1400: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1410: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1420: 2d 2d 2d 2d 2d 0a 23 20 20 20 49 66 20 74 68 69  -----.#   If thi
1430: 73 20 69 73 20 67 63 63 2c 20 61 64 64 20 73 6f  s is gcc, add so
1440: 6d 65 20 65 78 74 72 61 20 63 6f 6d 70 69 6c 65  me extra compile
1450: 20 66 6c 61 67 73 2e 0a 23 2d 2d 2d 2d 2d 2d 2d   flags..#-------
1460: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1470: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1480: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1490: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 41  -------------..A
14a0: 43 5f 4d 53 47 5f 43 48 45 43 4b 49 4e 47 28 5b  C_MSG_CHECKING([
14b0: 77 68 65 74 68 65 72 20 43 20 63 6f 6d 70 69 6c  whether C compil
14c0: 65 72 20 69 73 20 67 63 63 5d 29 0a 41 43 5f 43  er is gcc]).AC_C
14d0: 41 43 48 45 5f 56 41 4c 28 74 63 6c 72 65 61 64  ACHE_VAL(tclread
14e0: 6c 69 6e 65 5f 63 76 5f 70 72 6f 67 5f 67 63 63  line_cv_prog_gcc
14f0: 2c 0a 20 20 20 20 41 43 5f 45 47 52 45 50 5f 43  ,.    AC_EGREP_C
1500: 50 50 28 5f 63 63 5f 69 73 5f 67 63 63 5f 2c 20  PP(_cc_is_gcc_, 
1510: 5b 0a 23 69 66 64 65 66 20 5f 5f 47 4e 55 43 5f  [.#ifdef __GNUC_
1520: 5f 0a 5f 63 63 5f 69 73 5f 67 63 63 5f 0a 23 65  _._cc_is_gcc_.#e
1530: 6e 64 69 66 0a 5d 2c 20 20 20 20 20 20 5b 74 63  ndif.],      [tc
1540: 6c 72 65 61 64 6c 69 6e 65 5f 63 76 5f 70 72 6f  lreadline_cv_pro
1550: 67 5f 67 63 63 3d 79 65 73 5d 2c 20 5b 74 63 6c  g_gcc=yes], [tcl
1560: 72 65 61 64 6c 69 6e 65 5f 63 76 5f 70 72 6f 67  readline_cv_prog
1570: 5f 67 63 63 3d 6e 6f 5d 29 29 0a 41 43 5f 4d 53  _gcc=no])).AC_MS
1580: 47 5f 52 45 53 55 4c 54 28 5b 24 74 63 6c 72 65  G_RESULT([$tclre
1590: 61 64 6c 69 6e 65 5f 63 76 5f 70 72 6f 67 5f 67  adline_cv_prog_g
15a0: 63 63 5d 29 0a 0a 69 66 20 74 65 73 74 20 2d 7a  cc])..if test -z
15b0: 20 22 24 43 46 4c 41 47 53 22 20 3b 20 74 68 65   "$CFLAGS" ; the
15c0: 6e 0a 20 20 20 20 43 46 4c 41 47 53 3d 24 54 43  n.    CFLAGS=$TC
15d0: 4c 5f 43 46 4c 41 47 53 5f 4f 50 54 49 4d 49 5a  L_CFLAGS_OPTIMIZ
15e0: 45 0a 66 69 0a 69 66 20 74 65 73 74 20 22 24 74  E.fi.if test "$t
15f0: 63 6c 72 65 61 64 6c 69 6e 65 5f 63 76 5f 70 72  clreadline_cv_pr
1600: 6f 67 5f 67 63 63 22 20 3d 20 22 79 65 73 22 20  og_gcc" = "yes" 
1610: 3b 20 74 68 65 6e 0a 20 20 20 20 43 46 4c 41 47  ; then.    CFLAG
1620: 53 3d 22 24 43 46 4c 41 47 53 20 2d 57 73 68 61  S="$CFLAGS -Wsha
1630: 64 6f 77 20 2d 57 74 72 61 64 69 74 69 6f 6e 61  dow -Wtraditiona
1640: 6c 20 2d 57 61 6c 6c 22 0a 66 69 0a 0a 41 43 5f  l -Wall".fi..AC_
1650: 4d 53 47 5f 43 48 45 43 4b 49 4e 47 28 5b 64 65  MSG_CHECKING([de
1660: 66 61 75 6c 74 20 63 6f 6d 70 69 6c 65 72 20 66  fault compiler f
1670: 6c 61 67 73 5d 29 0a 41 43 5f 41 52 47 5f 57 49  lags]).AC_ARG_WI
1680: 54 48 28 63 66 6c 61 67 73 2c 20 5b 20 20 2d 2d  TH(cflags, [  --
1690: 77 69 74 68 2d 63 66 6c 61 67 73 3d 46 4c 41 47  with-cflags=FLAG
16a0: 53 20 20 20 20 20 73 65 74 20 63 6f 6d 70 69 6c  S     set compil
16b0: 65 72 20 66 6c 61 67 73 20 74 6f 20 46 4c 41 47  er flags to FLAG
16c0: 53 5d 2c 0a 20 20 20 20 5b 43 46 4c 41 47 53 3d  S],.    [CFLAGS=
16d0: 22 24 77 69 74 68 5f 63 66 6c 61 67 73 22 5d 29  "$with_cflags"])
16e0: 0a 0a 41 43 5f 4d 53 47 5f 52 45 53 55 4c 54 28  ..AC_MSG_RESULT(
16f0: 5b 24 43 46 4c 41 47 53 5d 29 0a 0a 69 66 20 74  [$CFLAGS])..if t
1700: 65 73 74 20 22 24 54 43 4c 5f 43 43 22 20 21 3d  est "$TCL_CC" !=
1710: 20 22 24 43 43 22 20 3b 20 74 68 65 6e 0a 20 20   "$CC" ; then.  
1720: 20 20 65 63 68 6f 20 22 22 0a 20 20 20 20 65 63    echo "".    ec
1730: 68 6f 20 22 57 41 52 4e 49 4e 47 3a 20 20 43 6f  ho "WARNING:  Co
1740: 6d 70 69 6c 65 72 20 69 73 20 24 43 43 20 62 75  mpiler is $CC bu
1750: 74 20 54 63 6c 20 77 61 73 20 63 6f 6d 70 69 6c  t Tcl was compil
1760: 65 64 20 77 69 74 68 20 24 54 43 4c 5f 43 43 22  ed with $TCL_CC"
1770: 0a 20 20 20 20 65 63 68 6f 20 22 22 0a 66 69 0a  .    echo "".fi.
1780: 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  .#--------------
1790: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
17a0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
17b0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
17c0: 2d 2d 2d 2d 2d 2d 0a 23 20 20 20 54 68 65 20 73  ------.#   The s
17d0: 74 61 74 65 6d 65 6e 74 73 20 62 65 6c 6f 77 20  tatements below 
17e0: 64 65 66 69 6e 65 20 61 20 63 6f 6c 6c 65 63 74  define a collect
17f0: 69 6f 6e 20 6f 66 20 73 79 6d 62 6f 6c 73 20 72  ion of symbols r
1800: 65 6c 61 74 65 64 20 74 6f 0a 23 20 20 20 62 75  elated to.#   bu
1810: 69 6c 64 69 6e 67 20 6c 69 62 74 63 6c 72 65 61  ilding libtclrea
1820: 64 6c 69 6e 65 20 61 73 20 61 20 73 68 61 72 65  dline as a share
1830: 64 20 6c 69 62 72 61 72 79 20 69 6e 73 74 65 61  d library instea
1840: 64 20 6f 66 20 61 20 73 74 61 74 69 63 20 6c 69  d of a static li
1850: 62 72 61 72 79 2e 0a 23 20 20 20 28 73 74 61 74  brary..#   (stat
1860: 69 63 20 69 73 20 6e 6f 74 20 69 6d 70 6c 65 6d  ic is not implem
1870: 65 6e 74 65 64 20 79 65 74 20 61 6e 79 77 61 79  ented yet anyway
1880: 29 2e 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  )..#------------
1890: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
18a0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
18b0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
18c0: 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 41 43 5f 41 52 47  --------..AC_ARG
18d0: 5f 45 4e 41 42 4c 45 28 73 68 61 72 65 64 2c 0a  _ENABLE(shared,.
18e0: 20 20 20 20 5b 20 20 2d 2d 64 69 73 61 62 6c 65      [  --disable
18f0: 2d 73 68 61 72 65 64 20 20 20 20 20 20 20 20 64  -shared        d
1900: 6f 6e 27 74 20 62 75 69 6c 64 20 6c 69 62 74 63  on't build libtc
1910: 6c 72 65 61 64 6c 69 6e 65 20 61 73 20 61 20 73  lreadline as a s
1920: 68 61 72 65 64 20 6c 69 62 72 61 72 79 0a 20 20  hared library.  
1930: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
1940: 20 20 20 20 20 20 20 20 28 6e 6f 74 20 69 6d 70          (not imp
1950: 6c 65 6d 65 6e 74 65 64 20 2d 2d 20 70 72 6f 62  lemented -- prob
1960: 61 62 6c 79 20 6e 65 76 65 72 29 2e 5d 2c 0a 20  ably never).],. 
1970: 20 20 20 5b 6f 6b 3d 24 65 6e 61 62 6c 65 76 61     [ok=$enableva
1980: 6c 5d 2c 20 5b 6f 6b 3d 79 65 73 5d 29 0a 69 66  l], [ok=yes]).if
1990: 20 74 65 73 74 20 22 24 6f 6b 22 20 3d 20 22 79   test "$ok" = "y
19a0: 65 73 22 3b 20 74 68 65 6e 0a 20 20 20 20 69 66  es"; then.    if
19b0: 20 74 65 73 74 20 24 7b 54 43 4c 5f 53 48 41 52   test ${TCL_SHAR
19c0: 45 44 5f 42 55 49 4c 44 7d 20 3d 20 30 3b 20 74  ED_BUILD} = 0; t
19d0: 68 65 6e 0a 20 20 20 20 20 20 20 20 41 43 5f 4d  hen.        AC_M
19e0: 53 47 5f 45 52 52 4f 52 28 54 63 6c 20 77 61 73  SG_ERROR(Tcl was
19f0: 20 6e 6f 74 20 62 75 69 6c 74 20 77 69 74 68 20   not built with 
1a00: 2d 2d 65 6e 61 62 6c 65 2d 73 68 61 72 65 64 2c  --enable-shared,
1a10: 20 73 6f 20 79 6f 75 20 63 61 6e 27 74 20 75 73   so you can't us
1a20: 65 20 73 68 61 72 65 64 20 6c 69 62 72 61 72 69  e shared librari
1a30: 65 73 2e 29 0a 20 20 20 20 66 69 0a 20 20 20 20  es.).    fi.    
1a40: 53 48 4c 49 42 5f 43 46 4c 41 47 53 3d 22 24 7b  SHLIB_CFLAGS="${
1a50: 53 48 4c 49 42 5f 43 46 4c 41 47 53 7d 22 0a 20  SHLIB_CFLAGS}". 
1a60: 20 20 20 65 76 61 6c 20 22 54 43 4c 52 45 41 44     eval "TCLREAD
1a70: 4c 49 4e 45 5f 4c 49 42 5f 46 49 4c 45 3d 6c 69  LINE_LIB_FILE=li
1a80: 62 74 63 6c 72 65 61 64 6c 69 6e 65 24 7b 56 45  btclreadline${VE
1a90: 52 53 49 4f 4e 7d 24 7b 53 48 4c 49 42 5f 53 55  RSION}${SHLIB_SU
1aa0: 46 46 49 58 7d 22 0a 20 20 20 20 54 43 4c 52 45  FFIX}".    TCLRE
1ab0: 41 44 4c 49 4e 45 5f 50 4b 47 5f 46 49 4c 45 3d  ADLINE_PKG_FILE=
1ac0: 22 5b 5b 66 69 6c 65 20 6a 6f 69 6e 20 5b 66 69  "[[file join [fi
1ad0: 6c 65 20 64 69 72 6e 61 6d 65 20 5c 24 64 69 72  le dirname \$dir
1ae0: 5d 20 24 7b 54 43 4c 52 45 41 44 4c 49 4e 45 5f  ] ${TCLREADLINE_
1af0: 4c 49 42 5f 46 49 4c 45 7d 5d 5d 22 0a 20 20 20  LIB_FILE}]]".   
1b00: 20 4d 41 4b 45 5f 4c 49 42 3d 22 5c 24 28 53 48   MAKE_LIB="\$(SH
1b10: 4c 49 42 5f 4c 44 29 20 2d 6f 20 24 7b 54 43 4c  LIB_LD) -o ${TCL
1b20: 52 45 41 44 4c 49 4e 45 5f 4c 49 42 5f 46 49 4c  READLINE_LIB_FIL
1b30: 45 7d 20 5c 24 28 4f 42 4a 53 29 20 24 7b 53 48  E} \$(OBJS) ${SH
1b40: 4c 49 42 5f 4c 44 5f 4c 49 42 53 7d 22 0a 20 20  LIB_LD_LIBS}".  
1b50: 20 20 52 41 4e 4c 49 42 3d 22 3a 22 0a 65 6c 73    RANLIB=":".els
1b60: 65 0a 20 20 20 20 41 43 5f 4d 53 47 5f 45 52 52  e.    AC_MSG_ERR
1b70: 4f 52 28 6e 6f 6e 2d 73 68 61 72 65 64 20 6e 6f  OR(non-shared no
1b80: 74 20 69 6d 70 6c 65 6d 65 6e 74 65 64 20 79 65  t implemented ye
1b90: 74 2e 20 28 70 72 6f 62 61 62 6c 79 20 6e 65 76  t. (probably nev
1ba0: 65 72 29 29 0a 20 20 20 20 53 48 4c 49 42 5f 43  er)).    SHLIB_C
1bb0: 46 4c 41 47 53 3d 22 22 0a 20 20 20 20 65 76 61  FLAGS="".    eva
1bc0: 6c 20 22 54 43 4c 52 45 41 44 4c 49 4e 45 5f 4c  l "TCLREADLINE_L
1bd0: 49 42 5f 46 49 4c 45 3d 6c 69 62 74 63 6c 72 65  IB_FILE=libtclre
1be0: 61 64 6c 69 6e 65 24 7b 56 45 52 53 49 4f 4e 7d  adline${VERSION}
1bf0: 2e 61 22 0a 20 20 20 20 54 43 4c 52 45 41 44 4c  .a".    TCLREADL
1c00: 49 4e 45 5f 50 4b 47 5f 46 49 4c 45 3d 22 22 0a  INE_PKG_FILE="".
1c10: 20 20 20 20 4d 41 4b 45 5f 4c 49 42 3d 22 61 72      MAKE_LIB="ar
1c20: 20 63 72 20 24 7b 54 43 4c 52 45 41 44 4c 49 4e   cr ${TCLREADLIN
1c30: 45 5f 4c 49 42 5f 46 49 4c 45 7d 20 5c 24 7b 4f  E_LIB_FILE} \${O
1c40: 42 4a 53 7d 22 0a 66 69 0a 0a 23 20 4e 6f 74 65  BJS}".fi..# Note
1c50: 3a 20 20 69 6e 20 74 68 65 20 66 6f 6c 6c 6f 77  :  in the follow
1c60: 69 6e 67 20 76 61 72 69 61 62 6c 65 2c 20 69 74  ing variable, it
1c70: 27 73 20 69 6d 70 6f 72 74 61 6e 74 20 74 6f 20  's important to 
1c80: 75 73 65 20 74 68 65 20 61 62 73 6f 6c 75 74 65  use the absolute
1c90: 0a 23 20 70 61 74 68 20 6e 61 6d 65 20 6f 66 20  .# path name of 
1ca0: 74 68 65 20 54 63 6c 20 64 69 72 65 63 74 6f 72  the Tcl director
1cb0: 79 20 72 61 74 68 65 72 20 74 68 61 6e 20 22 2e  y rather than ".
1cc0: 2e 22 3a 20 20 74 68 69 73 20 69 73 20 62 65 63  .":  this is bec
1cd0: 61 75 73 65 0a 23 20 41 49 58 20 72 65 6d 65 6d  ause.# AIX remem
1ce0: 62 65 72 73 20 74 68 69 73 20 70 61 74 68 20 61  bers this path a
1cf0: 6e 64 20 77 69 6c 6c 20 61 74 74 65 6d 70 74 20  nd will attempt 
1d00: 74 6f 20 75 73 65 20 69 74 20 61 74 20 72 75 6e  to use it at run
1d10: 2d 74 69 6d 65 20 74 6f 20 6c 6f 6f 6b 0a 23 20  -time to look.# 
1d20: 75 70 20 74 68 65 20 54 63 6c 20 6c 69 62 72 61  up the Tcl libra
1d30: 72 79 2e 0a 0a 69 66 20 74 65 73 74 20 22 24 7b  ry...if test "${
1d40: 54 43 4c 5f 4c 49 42 5f 56 45 52 53 49 4f 4e 53  TCL_LIB_VERSIONS
1d50: 5f 4f 4b 7d 22 20 3d 20 22 6f 6b 22 3b 20 74 68  _OK}" = "ok"; th
1d60: 65 6e 0a 20 20 20 20 54 43 4c 52 45 41 44 4c 49  en.    TCLREADLI
1d70: 4e 45 5f 42 55 49 4c 44 5f 4c 49 42 5f 53 50 45  NE_BUILD_LIB_SPE
1d80: 43 3d 22 2d 4c 60 70 77 64 60 20 2d 6c 74 63 6c  C="-L`pwd` -ltcl
1d90: 72 65 61 64 6c 69 6e 65 24 7b 56 45 52 53 49 4f  readline${VERSIO
1da0: 4e 7d 22 0a 20 20 20 20 54 43 4c 52 45 41 44 4c  N}".    TCLREADL
1db0: 49 4e 45 5f 4c 49 42 5f 53 50 45 43 3d 22 2d 4c  INE_LIB_SPEC="-L
1dc0: 24 7b 54 43 4c 52 45 41 44 4c 49 4e 45 5f 4c 49  ${TCLREADLINE_LI
1dd0: 42 52 41 52 59 7d 20 2d 6c 74 63 6c 72 65 61 64  BRARY} -ltclread
1de0: 6c 69 6e 65 24 7b 56 45 52 53 49 4f 4e 7d 22 0a  line${VERSION}".
1df0: 65 6c 73 65 0a 20 20 20 20 54 43 4c 52 45 41 44  else.    TCLREAD
1e00: 4c 49 4e 45 5f 42 55 49 4c 44 5f 4c 49 42 5f 53  LINE_BUILD_LIB_S
1e10: 50 45 43 3d 22 2d 4c 60 70 77 64 60 20 2d 6c 74  PEC="-L`pwd` -lt
1e20: 63 6c 72 65 61 64 6c 69 6e 65 60 65 63 68 6f 20  clreadline`echo 
1e30: 24 7b 56 45 52 53 49 4f 4e 7d 20 7c 20 74 72 20  ${VERSION} | tr 
1e40: 2d 64 20 2e 60 22 0a 20 20 20 20 54 43 4c 52 45  -d .`".    TCLRE
1e50: 41 44 4c 49 4e 45 5f 4c 49 42 5f 53 50 45 43 3d  ADLINE_LIB_SPEC=
1e60: 22 2d 4c 24 7b 54 43 4c 52 45 41 44 4c 49 4e 45  "-L${TCLREADLINE
1e70: 5f 4c 49 42 52 41 52 59 7d 20 2d 6c 74 63 6c 72  _LIBRARY} -ltclr
1e80: 65 61 64 6c 69 6e 65 60 65 63 68 6f 20 24 7b 56  eadline`echo ${V
1e90: 45 52 53 49 4f 4e 7d 20 7c 20 74 72 20 2d 64 20  ERSION} | tr -d 
1ea0: 2e 60 22 0a 66 69 0a 0a 0a 0a 0a 23 20 48 45 41  .`".fi.....# HEA
1eb0: 44 45 52 20 43 48 45 43 4b 53 0a 23 0a 41 43 5f  DER CHECKS.#.AC_
1ec0: 48 45 41 44 45 52 5f 53 54 44 43 0a 0a 0a 23 2d  HEADER_STDC...#-
1ed0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1ee0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1ef0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1f00: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1f10: 2d 2d 2d 0a 23 20 20 20 43 68 65 63 6b 20 66 6f  ---.#   Check fo
1f20: 72 20 74 63 6c 2e 68 0a 23 2d 2d 2d 2d 2d 2d 2d  r tcl.h.#-------
1f30: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1f40: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1f50: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
1f60: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 41  -------------..A
1f70: 43 5f 41 52 47 5f 57 49 54 48 28 74 63 6c 2d 69  C_ARG_WITH(tcl-i
1f80: 6e 63 6c 75 64 65 73 2c 0a 20 20 20 20 20 20 20  ncludes,.       
1f90: 20 20 20 20 20 5b 20 20 2d 2d 77 69 74 68 2d 74       [  --with-t
1fa0: 63 6c 2d 69 6e 63 6c 75 64 65 73 3d 44 49 52 20  cl-includes=DIR 
1fb0: 77 68 65 72 65 20 74 6f 20 6c 6f 6f 6b 20 66 6f  where to look fo
1fc0: 72 20 74 63 6c 2e 68 5d 2c 0a 20 20 20 20 20 20  r tcl.h],.      
1fd0: 20 20 20 20 20 20 74 63 6c 5f 69 6e 63 6c 75 64        tcl_includ
1fe0: 65 73 3d 24 77 69 74 68 76 61 6c 2c 20 74 63 6c  es=$withval, tcl
1ff0: 5f 69 6e 63 6c 75 64 65 73 3d 24 70 72 65 66 69  _includes=$prefi
2000: 78 2f 69 6e 63 6c 75 64 65 29 0a 0a 41 43 5f 4d  x/include)..AC_M
2010: 53 47 5f 43 48 45 43 4b 49 4e 47 28 5b 77 68 65  SG_CHECKING([whe
2020: 72 65 20 74 6f 20 6c 6f 6f 6b 20 66 6f 72 20 74  re to look for t
2030: 63 6c 2e 68 5d 29 0a 54 43 4c 5f 49 4e 43 4c 55  cl.h]).TCL_INCLU
2040: 44 45 5f 44 49 52 3d 22 22 0a 66 6f 72 20 64 69  DE_DIR="".for di
2050: 72 20 69 6e 20 24 74 63 6c 5f 69 6e 63 6c 75 64  r in $tcl_includ
2060: 65 73 20 24 70 72 65 66 69 78 2f 69 6e 63 6c 75  es $prefix/inclu
2070: 64 65 2f 20 2f 75 73 72 2f 69 6e 63 6c 75 64 65  de/ /usr/include
2080: 3b 20 64 6f 0a 20 20 20 20 69 66 20 74 65 73 74  ; do.    if test
2090: 20 2d 72 20 24 64 69 72 2f 74 63 6c 2e 68 3b 20   -r $dir/tcl.h; 
20a0: 74 68 65 6e 0a 20 20 20 20 20 20 20 20 54 43 4c  then.        TCL
20b0: 5f 49 4e 43 4c 55 44 45 5f 44 49 52 3d 24 64 69  _INCLUDE_DIR=$di
20c0: 72 0a 20 20 20 20 20 20 20 20 62 72 65 61 6b 0a  r.        break.
20d0: 20 20 20 20 66 69 0a 64 6f 6e 65 0a 0a 69 66 20      fi.done..if 
20e0: 74 65 73 74 20 2d 7a 20 22 24 54 43 4c 5f 49 4e  test -z "$TCL_IN
20f0: 43 4c 55 44 45 5f 44 49 52 22 3b 20 74 68 65 6e  CLUDE_DIR"; then
2100: 0a 20 20 20 20 41 43 5f 4d 53 47 5f 45 52 52 4f  .    AC_MSG_ERRO
2110: 52 28 5b 0a 20 20 43 61 6e 27 74 20 66 69 6e 64  R([.  Can't find
2120: 20 74 63 6c 2e 68 2e 20 20 55 73 65 20 2d 2d 77   tcl.h.  Use --w
2130: 69 74 68 2d 74 63 6c 2d 69 6e 63 6c 75 64 65 73  ith-tcl-includes
2140: 20 74 6f 20 73 70 65 63 69 66 79 20 74 68 65 20   to specify the 
2150: 64 69 72 65 63 74 6f 72 79 0a 20 20 63 6f 6e 74  directory.  cont
2160: 61 69 6e 69 6e 67 20 74 63 6c 2e 68 20 6f 6e 20  aining tcl.h on 
2170: 79 6f 75 72 20 73 79 73 74 65 6d 2e 5d 29 0a 65  your system.]).e
2180: 6c 73 65 0a 20 20 20 20 41 43 5f 4d 53 47 5f 52  lse.    AC_MSG_R
2190: 45 53 55 4c 54 28 24 54 43 4c 5f 49 4e 43 4c 55  ESULT($TCL_INCLU
21a0: 44 45 5f 44 49 52 2f 74 63 6c 2e 68 29 0a 66 69  DE_DIR/tcl.h).fi
21b0: 0a 0a 0a 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ....#-----------
21c0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
21d0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
21e0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
21f0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20 20 20 43 68  ---------.#   Ch
2200: 65 63 6b 20 66 6f 72 20 72 65 61 64 6c 69 6e 65  eck for readline
2210: 2e 68 0a 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  .h.#------------
2220: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2230: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2240: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2250: 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 41 43 5f 41 52 47  --------..AC_ARG
2260: 5f 57 49 54 48 28 72 65 61 64 6c 69 6e 65 2d 69  _WITH(readline-i
2270: 6e 63 6c 75 64 65 73 2c 0a 20 20 20 20 20 20 20  ncludes,.       
2280: 20 20 20 20 20 5b 20 20 2d 2d 77 69 74 68 2d 72       [  --with-r
2290: 65 61 64 6c 69 6e 65 2d 69 6e 63 6c 75 64 65 73  eadline-includes
22a0: 3d 44 49 52 0a 20 20 20 20 20 20 20 20 20 20 20  =DIR.           
22b0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72                 r
22c0: 65 61 64 6c 69 6e 65 20 69 6e 63 6c 75 64 65 20  eadline include 
22d0: 66 69 6c 65 73 20 69 6e 20 44 49 52 5d 2c 0a 20  files in DIR],. 
22e0: 20 20 20 20 20 20 20 20 20 20 20 72 6c 5f 69 6e             rl_in
22f0: 63 6c 75 64 65 73 3d 24 77 69 74 68 76 61 6c 2c  cludes=$withval,
2300: 20 72 6c 5f 69 6e 63 6c 75 64 65 73 3d 24 70 72   rl_includes=$pr
2310: 65 66 69 78 2f 69 6e 63 6c 75 64 65 29 0a 0a 41  efix/include)..A
2320: 43 5f 4d 53 47 5f 43 48 45 43 4b 49 4e 47 28 5b  C_MSG_CHECKING([
2330: 77 68 65 72 65 20 74 6f 20 6c 6f 6f 6b 20 66 6f  where to look fo
2340: 72 20 72 65 61 64 6c 69 6e 65 2e 68 5d 29 0a 52  r readline.h]).R
2350: 45 41 44 4c 49 4e 45 5f 49 4e 43 4c 55 44 45 5f  EADLINE_INCLUDE_
2360: 44 49 52 3d 22 22 0a 66 6f 72 20 64 69 72 20 69  DIR="".for dir i
2370: 6e 20 24 72 6c 5f 69 6e 63 6c 75 64 65 73 20 24  n $rl_includes $
2380: 70 72 65 66 69 78 2f 69 6e 63 6c 75 64 65 2f 72  prefix/include/r
2390: 65 61 64 6c 69 6e 65 20 2f 75 73 72 2f 69 6e 63  eadline /usr/inc
23a0: 6c 75 64 65 2f 72 65 61 64 6c 69 6e 65 20 2f 75  lude/readline /u
23b0: 73 72 2f 69 6e 63 6c 75 64 65 3b 20 64 6f 0a 20  sr/include; do. 
23c0: 20 20 20 69 66 20 74 65 73 74 20 2d 72 20 24 64     if test -r $d
23d0: 69 72 2f 72 65 61 64 6c 69 6e 65 2e 68 3b 20 74  ir/readline.h; t
23e0: 68 65 6e 0a 20 20 20 20 20 20 20 20 52 45 41 44  hen.        READ
23f0: 4c 49 4e 45 5f 49 4e 43 4c 55 44 45 5f 44 49 52  LINE_INCLUDE_DIR
2400: 3d 24 64 69 72 0a 20 20 20 20 20 20 20 20 62 72  =$dir.        br
2410: 65 61 6b 0a 20 20 20 20 66 69 0a 64 6f 6e 65 0a  eak.    fi.done.
2420: 0a 69 66 20 74 65 73 74 20 2d 7a 20 22 24 52 45  .if test -z "$RE
2430: 41 44 4c 49 4e 45 5f 49 4e 43 4c 55 44 45 5f 44  ADLINE_INCLUDE_D
2440: 49 52 22 3b 20 74 68 65 6e 0a 20 20 20 20 41 43  IR"; then.    AC
2450: 5f 4d 53 47 5f 45 52 52 4f 52 28 5b 0a 20 20 43  _MSG_ERROR([.  C
2460: 61 6e 27 74 20 66 69 6e 64 20 72 65 61 64 6c 69  an't find readli
2470: 6e 65 2e 68 2e 0a 20 20 55 73 65 20 2d 2d 77 69  ne.h..  Use --wi
2480: 74 68 2d 72 65 61 64 6c 69 6e 65 2d 69 6e 63 6c  th-readline-incl
2490: 75 64 65 73 20 74 6f 20 73 70 65 63 69 66 79 20  udes to specify 
24a0: 74 68 65 20 64 69 72 65 63 74 6f 72 79 0a 20 20  the directory.  
24b0: 63 6f 6e 74 61 69 6e 69 6e 67 20 72 65 61 64 6c  containing readl
24c0: 69 6e 65 2e 68 20 6f 6e 20 79 6f 75 72 20 73 79  ine.h on your sy
24d0: 73 74 65 6d 2e 5d 29 0a 65 6c 73 65 0a 20 20 20  stem.]).else.   
24e0: 20 41 43 5f 4d 53 47 5f 52 45 53 55 4c 54 28 24   AC_MSG_RESULT($
24f0: 52 45 41 44 4c 49 4e 45 5f 49 4e 43 4c 55 44 45  READLINE_INCLUDE
2500: 5f 44 49 52 2f 72 65 61 64 6c 69 6e 65 2e 68 29  _DIR/readline.h)
2510: 0a 66 69 0a 0a 0a 0a 23 2d 2d 2d 2d 2d 2d 2d 2d  .fi....#--------
2520: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2530: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2540: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2550: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 23 20 20  ------------.#  
2560: 20 43 68 65 63 6b 20 66 6f 72 20 6c 69 62 72 65   Check for libre
2570: 61 64 6c 69 6e 65 0a 23 2d 2d 2d 2d 2d 2d 2d 2d  adline.#--------
2580: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2590: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
25a0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
25b0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 41 43  ------------..AC
25c0: 5f 41 52 47 5f 57 49 54 48 28 72 65 61 64 6c 69  _ARG_WITH(readli
25d0: 6e 65 2d 6c 69 62 72 61 72 79 2c 0a 20 20 20 20  ne-library,.    
25e0: 20 20 20 20 20 20 20 20 5b 20 20 2d 2d 77 69 74          [  --wit
25f0: 68 2d 72 65 61 64 6c 69 6e 65 2d 6c 69 62 72 61  h-readline-libra
2600: 72 79 3d 44 49 52 0a 20 20 20 20 20 20 20 20 20  ry=DIR.         
2610: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
2620: 20 72 65 61 64 6c 69 6e 65 20 6c 69 62 72 61 72   readline librar
2630: 79 20 66 69 6c 65 73 20 69 6e 20 44 49 52 5d 2c  y files in DIR],
2640: 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 6c 5f  .            rl_
2650: 6c 69 62 72 61 72 79 3d 24 77 69 74 68 76 61 6c  library=$withval
2660: 2c 20 72 6c 5f 6c 69 62 72 61 72 79 3d 24 65 78  , rl_library=$ex
2670: 65 63 5f 70 72 65 66 69 78 2f 6c 69 62 29 0a 0a  ec_prefix/lib)..
2680: 41 43 5f 4d 53 47 5f 43 48 45 43 4b 49 4e 47 28  AC_MSG_CHECKING(
2690: 5b 77 68 65 72 65 20 74 6f 20 6c 6f 6f 6b 20 66  [where to look f
26a0: 6f 72 20 6c 69 62 72 65 61 64 6c 69 6e 65 24 53  or libreadline$S
26b0: 48 4c 49 42 5f 53 55 46 46 49 58 5d 29 0a 52 45  HLIB_SUFFIX]).RE
26c0: 41 44 4c 49 4e 45 5f 4c 49 42 5f 44 49 52 3d 22  ADLINE_LIB_DIR="
26d0: 22 0a 52 45 41 44 4c 49 4e 45 5f 56 45 52 53 49  ".READLINE_VERSI
26e0: 4f 4e 5f 53 55 46 46 49 58 3d 22 22 0a 66 6f 72  ON_SUFFIX="".for
26f0: 20 64 69 72 20 69 6e 20 24 72 6c 5f 6c 69 62 72   dir in $rl_libr
2700: 61 72 79 20 24 54 43 4c 52 45 41 44 4c 49 4e 45  ary $TCLREADLINE
2710: 5f 4c 50 41 54 48 20 24 70 72 65 66 69 78 2f 6c  _LPATH $prefix/l
2720: 69 62 2f 72 65 61 64 6c 69 6e 65 3b 20 64 6f 0a  ib/readline; do.
2730: 20 20 20 20 69 66 20 74 65 73 74 20 2d 72 20 24      if test -r $
2740: 64 69 72 2f 6c 69 62 72 65 61 64 6c 69 6e 65 24  dir/libreadline$
2750: 53 48 4c 49 42 5f 53 55 46 46 49 58 3b 20 74 68  SHLIB_SUFFIX; th
2760: 65 6e 0a 20 20 20 20 20 20 20 20 52 45 41 44 4c  en.        READL
2770: 49 4e 45 5f 4c 49 42 5f 44 49 52 3d 24 64 69 72  INE_LIB_DIR=$dir
2780: 0a 20 20 20 20 20 20 20 20 62 72 65 61 6b 0a 20  .        break. 
2790: 20 20 20 66 69 0a 20 20 20 20 69 66 20 74 65 73     fi.    if tes
27a0: 74 20 2d 72 20 24 64 69 72 2f 6c 69 62 72 65 61  t -r $dir/librea
27b0: 64 6c 69 6e 65 24 53 48 4c 49 42 5f 53 55 46 46  dline$SHLIB_SUFF
27c0: 49 58 2e 33 2e 30 3b 20 74 68 65 6e 0a 20 20 20  IX.3.0; then.   
27d0: 20 20 20 20 20 52 45 41 44 4c 49 4e 45 5f 56 45       READLINE_VE
27e0: 52 53 49 4f 4e 5f 53 55 46 46 49 58 3d 22 2e 33  RSION_SUFFIX=".3
27f0: 2e 30 22 0a 20 20 20 20 20 20 20 20 52 45 41 44  .0".        READ
2800: 4c 49 4e 45 5f 4c 49 42 5f 44 49 52 3d 24 64 69  LINE_LIB_DIR=$di
2810: 72 0a 20 20 20 20 20 20 20 20 62 72 65 61 6b 0a  r.        break.
2820: 20 20 20 20 66 69 0a 20 20 20 20 69 66 20 74 65      fi.    if te
2830: 73 74 20 2d 72 20 24 64 69 72 2f 6c 69 62 72 65  st -r $dir/libre
2840: 61 64 6c 69 6e 65 24 53 48 4c 49 42 5f 53 55 46  adline$SHLIB_SUF
2850: 46 49 58 2e 34 2e 30 3b 20 74 68 65 6e 0a 20 20  FIX.4.0; then.  
2860: 20 20 20 20 20 20 52 45 41 44 4c 49 4e 45 5f 56        READLINE_V
2870: 45 52 53 49 4f 4e 5f 53 55 46 46 49 58 3d 22 2e  ERSION_SUFFIX=".
2880: 34 2e 30 22 0a 20 20 20 20 20 20 20 20 52 45 41  4.0".        REA
2890: 44 4c 49 4e 45 5f 4c 49 42 5f 44 49 52 3d 24 64  DLINE_LIB_DIR=$d
28a0: 69 72 0a 20 20 20 20 20 20 20 20 62 72 65 61 6b  ir.        break
28b0: 0a 20 20 20 20 66 69 0a 64 6f 6e 65 0a 0a 69 66  .    fi.done..if
28c0: 20 74 65 73 74 20 2d 7a 20 22 24 52 45 41 44 4c   test -z "$READL
28d0: 49 4e 45 5f 4c 49 42 5f 44 49 52 22 3b 20 74 68  INE_LIB_DIR"; th
28e0: 65 6e 0a 20 20 20 20 41 43 5f 4d 53 47 5f 45 52  en.    AC_MSG_ER
28f0: 52 4f 52 28 5b 0a 20 20 43 61 6e 27 74 20 66 69  ROR([.  Can't fi
2900: 6e 64 20 6c 69 62 72 65 61 64 6c 69 6e 65 24 53  nd libreadline$S
2910: 48 4c 49 42 5f 53 55 46 46 49 58 2e 0a 20 20 55  HLIB_SUFFIX..  U
2920: 73 65 20 2d 2d 77 69 74 68 2d 72 65 61 64 6c 69  se --with-readli
2930: 6e 65 2d 6c 69 62 72 61 72 79 20 74 6f 20 73 70  ne-library to sp
2940: 65 63 69 66 79 20 74 68 65 20 64 69 72 65 63 74  ecify the direct
2950: 6f 72 79 0a 20 20 63 6f 6e 74 61 69 6e 69 6e 67  ory.  containing
2960: 20 6c 69 62 72 65 61 64 6c 69 6e 65 24 53 48 4c   libreadline$SHL
2970: 49 42 5f 53 55 46 46 49 58 20 6f 6e 20 79 6f 75  IB_SUFFIX on you
2980: 72 20 73 79 73 74 65 6d 2e 5d 29 0a 65 6c 73 65  r system.]).else
2990: 0a 20 20 20 20 41 43 5f 4d 53 47 5f 52 45 53 55  .    AC_MSG_RESU
29a0: 4c 54 28 24 7b 52 45 41 44 4c 49 4e 45 5f 4c 49  LT(${READLINE_LI
29b0: 42 5f 44 49 52 7d 2f 6c 69 62 72 65 61 64 6c 69  B_DIR}/libreadli
29c0: 6e 65 24 7b 53 48 4c 49 42 5f 53 55 46 46 49 58  ne${SHLIB_SUFFIX
29d0: 7d 24 7b 52 45 41 44 4c 49 4e 45 5f 56 45 52 53  }${READLINE_VERS
29e0: 49 4f 4e 5f 53 55 46 46 49 58 7d 29 0a 66 69 0a  ION_SUFFIX}).fi.
29f0: 0a 0a 0a 23 20 2d 2d 2d 0a 23 20 63 68 65 63 6b  ...# ---.# check
2a00: 2c 20 69 66 20 63 75 72 73 65 73 20 6f 72 20 74  , if curses or t
2a10: 65 72 6d 63 61 70 20 69 73 20 61 6c 72 65 61 64  ermcap is alread
2a20: 79 0a 23 20 6c 69 6e 6b 65 64 20 77 69 74 68 20  y.# linked with 
2a30: 6c 69 62 72 65 61 64 6c 69 6e 65 2e 20 28 6f 6e  libreadline. (on
2a40: 20 6e 65 77 65 72 20 4c 69 6e 75 78 0a 23 20 73   newer Linux.# s
2a50: 79 73 74 65 6d 73 20 69 74 20 69 73 2e 29 0a 23  ystems it is.).#
2a60: 20 2d 2d 2d 0a 0a 54 45 52 4d 5f 4c 49 42 3d 22   ---..TERM_LIB="
2a70: 22 0a 41 43 5f 43 48 45 43 4b 5f 4c 49 42 28 72  ".AC_CHECK_LIB(r
2a80: 65 61 64 6c 69 6e 65 2c 20 74 70 75 74 73 2c 20  eadline, tputs, 
2a90: 74 65 72 6d 63 61 70 73 3d 79 65 73 2c 20 74 65  termcaps=yes, te
2aa0: 72 6d 63 61 70 73 3d 6e 6f 29 0a 69 66 20 74 65  rmcaps=no).if te
2ab0: 73 74 20 22 24 74 65 72 6d 63 61 70 73 22 20 3d  st "$termcaps" =
2ac0: 20 22 6e 6f 22 3b 20 74 68 65 6e 0a 0a 20 20 20   "no"; then..   
2ad0: 20 23 20 2d 2d 2d 0a 20 20 20 20 23 20 6e 6f 70   # ---.    # nop
2ae0: 65 2e 20 74 70 75 74 73 28 29 20 69 73 20 75 6e  e. tputs() is un
2af0: 72 65 73 6f 6c 76 65 64 20 69 6e 20 6c 69 62 72  resolved in libr
2b00: 65 61 64 6c 69 6e 65 2c 20 73 6f 0a 20 20 20 20  eadline, so.    
2b10: 23 20 63 68 65 63 6b 20 69 66 20 77 65 20 77 61  # check if we wa
2b20: 6e 74 20 6c 69 62 63 75 72 73 65 73 20 6f 72 20  nt libcurses or 
2b30: 6c 69 62 74 65 72 6d 63 61 70 2e 0a 20 20 20 20  libtermcap..    
2b40: 23 20 2d 2d 2d 0a 0a 20 20 20 20 41 43 5f 41 52  # ---..    AC_AR
2b50: 47 5f 57 49 54 48 28 0a 20 20 20 20 20 20 20 20  G_WITH(.        
2b60: 74 65 72 6d 63 61 70 2c 20 0a 20 20 20 20 20 20  termcap, .      
2b70: 20 20 5b 20 20 2d 2d 77 69 74 68 2d 74 65 72 6d    [  --with-term
2b80: 63 61 70 20 20 20 20 20 20 20 20 20 20 75 73 65  cap          use
2b90: 20 74 65 72 6d 63 61 70 20 6c 69 62 72 61 72 79   termcap library
2ba0: 20 69 6e 73 74 65 61 64 20 6f 66 20 63 75 72 73   instead of curs
2bb0: 65 73 2e 5d 2c 0a 20 20 20 20 20 20 20 20 54 45  es.],.        TE
2bc0: 52 4d 5f 4c 49 42 3d 22 74 65 72 6d 63 61 70 22  RM_LIB="termcap"
2bd0: 2c 0a 20 20 20 20 20 20 20 20 54 45 52 4d 5f 4c  ,.        TERM_L
2be0: 49 42 3d 22 63 75 72 73 65 73 22 0a 20 20 20 20  IB="curses".    
2bf0: 29 0a 20 20 20 20 41 43 5f 43 48 45 43 4b 5f 4c  ).    AC_CHECK_L
2c00: 49 42 28 24 54 45 52 4d 5f 4c 49 42 2c 20 74 70  IB($TERM_LIB, tp
2c10: 75 74 73 2c 20 74 70 75 74 73 5f 6f 6b 3d 79 65  uts, tputs_ok=ye
2c20: 73 2c 20 74 70 75 74 73 5f 6f 6b 3d 6e 6f 29 0a  s, tputs_ok=no).
2c30: 20 20 20 20 69 66 20 74 65 73 74 20 22 24 74 70      if test "$tp
2c40: 75 74 73 5f 6f 6b 22 20 3d 20 22 6e 6f 22 3b 20  uts_ok" = "no"; 
2c50: 74 68 65 6e 0a 20 20 20 20 20 20 20 20 41 43 5f  then.        AC_
2c60: 4d 53 47 5f 45 52 52 4f 52 28 74 70 75 74 73 28  MSG_ERROR(tputs(
2c70: 29 20 6e 6f 74 20 66 6f 75 6e 64 20 69 6e 20 6c  ) not found in l
2c80: 69 62 24 54 45 52 4d 5f 4c 49 42 2e 29 0a 20 20  ib$TERM_LIB.).  
2c90: 20 20 65 6c 73 65 0a 20 20 20 20 20 20 20 20 54    else.        T
2ca0: 45 52 4d 5f 4c 49 42 3d 2d 6c 24 54 45 52 4d 5f  ERM_LIB=-l$TERM_
2cb0: 4c 49 42 0a 20 20 20 20 66 69 0a 66 69 0a 0a 0a  LIB.    fi.fi...
2cc0: 23 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  #---------------
2cd0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2ce0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2cf0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2d00: 2d 2d 2d 2d 2d 0a 23 20 20 20 43 68 65 63 6b 20  -----.#   Check 
2d10: 66 6f 72 20 61 70 70 72 6f 70 72 69 61 74 65 20  for appropriate 
2d20: 76 65 72 73 69 6f 6e 20 6f 66 20 67 6e 75 20 72  version of gnu r
2d30: 65 61 64 6c 69 6e 65 0a 23 20 20 20 28 6f 6c 64  eadline.#   (old
2d40: 65 72 20 76 65 72 73 69 6f 6e 73 20 6f 66 20 67  er versions of g
2d50: 6e 75 20 72 65 61 64 6c 69 6e 65 20 64 6f 6e 27  nu readline don'
2d60: 74 20 68 61 76 65 0a 23 20 20 20 20 72 6c 5f 63  t have.#    rl_c
2d70: 61 6c 6c 62 61 63 6b 5f 72 65 61 64 5f 63 68 61  allback_read_cha
2d80: 72 20 28 29 29 2e 0a 23 2d 2d 2d 2d 2d 2d 2d 2d  r ())..#--------
2d90: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2da0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2db0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d  ----------------
2dc0: 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 0a 0a 73 61  ------------..sa
2dd0: 76 65 3d 24 4c 49 42 53 0a 4c 49 42 53 3d 22 2d  ve=$LIBS.LIBS="-
2de0: 4c 24 52 45 41 44 4c 49 4e 45 5f 4c 49 42 5f 44  L$READLINE_LIB_D
2df0: 49 52 20 2d 6c 72 65 61 64 6c 69 6e 65 20 24 54  IR -lreadline $T
2e00: 45 52 4d 5f 4c 49 42 22 0a 61 6c 74 65 72 6e 61  ERM_LIB".alterna
2e10: 74 65 3d 6e 6f 0a 41 43 5f 43 48 45 43 4b 5f 46  te=no.AC_CHECK_F
2e20: 55 4e 43 28 0a 20 20 20 20 72 6c 5f 63 61 6c 6c  UNC(.    rl_call
2e30: 62 61 63 6b 5f 72 65 61 64 5f 63 68 61 72 2c 20  back_read_char, 
2e40: 61 6c 74 65 72 6e 61 74 65 3d 79 65 73 2c 20 61  alternate=yes, a
2e50: 6c 74 65 72 6e 61 74 65 3d 6e 6f 0a 29 0a 69 66  lternate=no.).if
2e60: 20 74 65 73 74 20 22 24 61 6c 74 65 72 6e 61 74   test "$alternat
2e70: 65 22 20 3d 20 22 6e 6f 22 3b 20 74 68 65 6e 0a  e" = "no"; then.
2e80: 20 20 20 20 41 43 5f 4d 53 47 5f 45 52 52 4f 52      AC_MSG_ERROR
2e90: 28 61 6c 74 65 72 6e 61 74 65 20 69 6e 74 65 72  (alternate inter
2ea0: 66 61 63 65 20 6e 6f 74 20 73 75 70 70 6f 72 74  face not support
2eb0: 65 64 20 62 79 20 74 68 69 73 20 72 65 61 64 6c  ed by this readl
2ec0: 69 6e 65 20 76 65 72 73 69 6f 6e 2e 29 0a 66 69  ine version.).fi
2ed0: 0a 0a 0a 41 43 5f 4d 53 47 5f 43 48 45 43 4b 49  ...AC_MSG_CHECKI
2ee0: 4e 47 28 5b 66 6f 72 20 74 68 65 20 72 65 61 64  NG([for the read
2ef0: 6c 69 6e 65 20 76 65 72 73 69 6f 6e 20 6e 75 6d  line version num
2f00: 62 65 72 5d 29 0a 41 43 5f 54 52 59 5f 52 55 4e  ber]).AC_TRY_RUN
2f10: 28 5b 0a 23 69 6e 63 6c 75 64 65 20 3c 73 74 64  ([.#include <std
2f20: 69 6f 2e 68 3e 0a 69 6e 74 20 6d 61 69 6e 20 28  io.h>.int main (
2f30: 29 20 7b 0a 20 20 20 20 46 49 4c 45 20 2a 66 70  ) {.    FILE *fp
2f40: 20 3d 20 66 6f 70 65 6e 20 28 22 63 6f 6e 66 74   = fopen ("conft
2f50: 65 73 74 76 65 72 73 69 6f 6e 22 2c 20 22 77 22  estversion", "w"
2f60: 29 3b 0a 20 20 20 20 65 78 74 65 72 6e 20 63 68  );.    extern ch
2f70: 61 72 20 2a 72 6c 5f 6c 69 62 72 61 72 79 5f 76  ar *rl_library_v
2f80: 65 72 73 69 6f 6e 3b 0a 20 20 20 20 66 70 72 69  ersion;.    fpri
2f90: 6e 74 66 20 28 66 70 2c 20 22 25 73 22 2c 20 72  ntf (fp, "%s", r
2fa0: 6c 5f 6c 69 62 72 61 72 79 5f 76 65 72 73 69 6f  l_library_versio
2fb0: 6e 29 3b 0a 20 20 20 20 63 6c 6f 73 65 20 28 66  n);.    close (f
2fc0: 70 29 3b 0a 20 20 20 20 72 65 74 75 72 6e 20 28  p);.    return (
2fd0: 30 29 3b 0a 7d 5d 2c 0a 20 20 20 20 52 45 41 44  0);.}],.    READ
2fe0: 4c 49 4e 45 5f 56 45 52 53 49 4f 4e 3d 60 63 61  LINE_VERSION=`ca
2ff0: 74 20 63 6f 6e 66 74 65 73 74 76 65 72 73 69 6f  t conftestversio
3000: 6e 60 0a 20 20 20 20 41 43 5f 4d 53 47 5f 52 45  n`.    AC_MSG_RE
3010: 53 55 4c 54 28 24 52 45 41 44 4c 49 4e 45 5f 56  SULT($READLINE_V
3020: 45 52 53 49 4f 4e 29 2c 0a 20 20 20 20 41 43 5f  ERSION),.    AC_
3030: 4d 53 47 5f 52 45 53 55 4c 54 28 66 61 69 6c 65  MSG_RESULT(faile
3040: 64 29 2c 0a 20 20 20 20 41 43 5f 4d 53 47 5f 52  d),.    AC_MSG_R
3050: 45 53 55 4c 54 28 6e 6f 20 63 72 6f 73 73 20 63  ESULT(no cross c
3060: 6f 6d 70 69 6c 69 6e 67 29 29 0a 0a 0a 4c 49 42  ompiling))...LIB
3070: 53 3d 24 4c 49 42 53 0a 0a 0a 0a 23 20 54 68 69  S=$LIBS....# Thi
3080: 73 20 69 73 20 61 20 74 65 73 74 0a 23 41 43 5f  s is a test.#AC_
3090: 43 5f 42 49 47 45 4e 44 49 41 4e 0a 0a 23 20 54  C_BIGENDIAN..# T
30a0: 4f 44 4f 3a 20 63 68 65 63 6b 20 66 6f 72 20 72  ODO: check for r
30b0: 65 61 64 6c 69 6e 65 20 76 65 72 73 69 6f 6e 0a  eadline version.
30c0: 23 20 28 6c 69 6e 6b 20 74 65 73 74 70 72 6f 67  # (link testprog
30d0: 72 61 6d 20 77 69 74 68 20 2d 6c 72 65 61 64 6c  ram with -lreadl
30e0: 69 6e 65 29 0a 0a 41 43 5f 53 55 42 53 54 28 54  ine)..AC_SUBST(T
30f0: 43 4c 52 45 41 44 4c 49 4e 45 5f 4d 41 4a 4f 52  CLREADLINE_MAJOR
3100: 5f 56 45 52 53 49 4f 4e 29 0a 41 43 5f 53 55 42  _VERSION).AC_SUB
3110: 53 54 28 54 43 4c 52 45 41 44 4c 49 4e 45 5f 4d  ST(TCLREADLINE_M
3120: 49 4e 4f 52 5f 56 45 52 53 49 4f 4e 29 0a 41 43  INOR_VERSION).AC
3130: 5f 53 55 42 53 54 28 54 43 4c 52 45 41 44 4c 49  _SUBST(TCLREADLI
3140: 4e 45 5f 56 45 52 53 49 4f 4e 29 0a 41 43 5f 53  NE_VERSION).AC_S
3150: 55 42 53 54 28 54 43 4c 52 45 41 44 4c 49 4e 45  UBST(TCLREADLINE
3160: 5f 50 41 54 43 48 4c 45 56 45 4c 29 0a 41 43 5f  _PATCHLEVEL).AC_
3170: 53 55 42 53 54 28 54 43 4c 52 45 41 44 4c 49 4e  SUBST(TCLREADLIN
3180: 45 5f 4c 49 42 52 41 52 59 29 0a 41 43 5f 53 55  E_LIBRARY).AC_SU
3190: 42 53 54 28 54 43 4c 52 45 41 44 4c 49 4e 45 5f  BST(TCLREADLINE_
31a0: 50 41 54 43 48 4c 45 56 45 4c 5f 53 54 52 29 0a  PATCHLEVEL_STR).
31b0: 0a 0a 41 43 5f 53 55 42 53 54 28 54 43 4c 5f 4c  ..AC_SUBST(TCL_L
31c0: 49 42 5f 44 49 52 29 0a 41 43 5f 53 55 42 53 54  IB_DIR).AC_SUBST
31d0: 28 54 43 4c 5f 49 4e 43 4c 55 44 45 5f 44 49 52  (TCL_INCLUDE_DIR
31e0: 29 0a 41 43 5f 53 55 42 53 54 28 52 45 41 44 4c  ).AC_SUBST(READL
31f0: 49 4e 45 5f 49 4e 43 4c 55 44 45 5f 44 49 52 29  INE_INCLUDE_DIR)
3200: 0a 0a 41 43 5f 53 55 42 53 54 28 43 46 4c 41 47  ..AC_SUBST(CFLAG
3210: 53 29 0a 41 43 5f 53 55 42 53 54 28 44 4c 5f 4c  S).AC_SUBST(DL_L
3220: 49 42 53 29 0a 41 43 5f 53 55 42 53 54 28 4c 44  IBS).AC_SUBST(LD
3230: 5f 46 4c 41 47 53 29 0a 41 43 5f 53 55 42 53 54  _FLAGS).AC_SUBST
3240: 28 52 41 4e 4c 49 42 29 0a 0a 41 43 5f 53 55 42  (RANLIB)..AC_SUB
3250: 53 54 28 4d 41 4b 45 5f 4c 49 42 29 0a 41 43 5f  ST(MAKE_LIB).AC_
3260: 53 55 42 53 54 28 53 48 4c 49 42 5f 43 46 4c 41  SUBST(SHLIB_CFLA
3270: 47 53 29 0a 0a 41 43 5f 53 55 42 53 54 28 53 48  GS)..AC_SUBST(SH
3280: 4c 49 42 5f 4c 44 29 0a 41 43 5f 53 55 42 53 54  LIB_LD).AC_SUBST
3290: 28 53 48 4c 49 42 5f 4c 44 5f 4c 49 42 53 29 0a  (SHLIB_LD_LIBS).
32a0: 0a 41 43 5f 53 55 42 53 54 28 53 48 4c 49 42 5f  .AC_SUBST(SHLIB_
32b0: 53 55 46 46 49 58 29 0a 0a 41 43 5f 53 55 42 53  SUFFIX)..AC_SUBS
32c0: 54 28 54 45 52 4d 5f 4c 49 42 29 0a 41 43 5f 53  T(TERM_LIB).AC_S
32d0: 55 42 53 54 28 52 45 41 44 4c 49 4e 45 5f 4c 49  UBST(READLINE_LI
32e0: 42 5f 44 49 52 29 0a 0a 41 43 5f 53 55 42 53 54  B_DIR)..AC_SUBST
32f0: 28 54 43 4c 52 45 41 44 4c 49 4e 45 5f 4c 49 42  (TCLREADLINE_LIB
3300: 5f 46 49 4c 45 29 0a 41 43 5f 53 55 42 53 54 28  _FILE).AC_SUBST(
3310: 54 43 4c 52 45 41 44 4c 49 4e 45 5f 42 55 49 4c  TCLREADLINE_BUIL
3320: 44 5f 4c 49 42 5f 53 50 45 43 29 0a 41 43 5f 53  D_LIB_SPEC).AC_S
3330: 55 42 53 54 28 54 43 4c 52 45 41 44 4c 49 4e 45  UBST(TCLREADLINE
3340: 5f 4c 49 42 5f 53 50 45 43 29 0a 0a 41 43 5f 53  _LIB_SPEC)..AC_S
3350: 55 42 53 54 28 54 43 4c 52 45 41 44 4c 49 4e 45  UBST(TCLREADLINE
3360: 5f 4c 49 42 5f 44 49 52 29 0a 41 43 5f 53 55 42  _LIB_DIR).AC_SUB
3370: 53 54 28 54 43 4c 52 45 41 44 4c 49 4e 45 5f 50  ST(TCLREADLINE_P
3380: 4b 47 5f 46 49 4c 45 29 0a 0a 41 43 5f 53 55 42  KG_FILE)..AC_SUB
3390: 53 54 28 54 43 4c 52 45 41 44 4c 49 4e 45 5f 50  ST(TCLREADLINE_P
33a0: 41 43 4b 41 47 45 5f 50 41 54 48 29 0a 0a 0a 41  ACKAGE_PATH)...A
33b0: 43 5f 4f 55 54 50 55 54 28 4d 61 6b 65 66 69 6c  C_OUTPUT(Makefil
33c0: 65 20 74 63 6c 72 65 61 64 6c 69 6e 65 2e 68 20  e tclreadline.h 
33d0: 74 63 6c 72 65 61 64 6c 69 6e 65 49 6e 69 74 2e  tclreadlineInit.
33e0: 74 63 6c 20 74 63 6c 72 65 61 64 6c 69 6e 65 53  tcl tclreadlineS
33f0: 65 74 75 70 2e 74 63 6c 20 74 63 6c 72 65 61 64  etup.tcl tclread
3400: 6c 69 6e 65 43 6f 6e 66 69 67 2e 73 68 20 74 63  lineConfig.sh tc
3410: 6c 72 65 61 64 6c 69 6e 65 2e 6e 20 70 6b 67 49  lreadline.n pkgI
3420: 6e 64 65 78 2e 74 63 6c 29 0a 0a 0a 23 54 43 4c  ndex.tcl)...#TCL
3430: 5f 43 43 3d 27 63 63 27 0a 23 54 43 4c 5f 43 46  _CC='cc'.#TCL_CF
3440: 4c 41 47 53 5f 44 45 42 55 47 3d 27 2d 67 27 0a  LAGS_DEBUG='-g'.
3450: 23 54 43 4c 5f 43 46 4c 41 47 53 5f 4f 50 54 49  #TCL_CFLAGS_OPTI
3460: 4d 49 5a 45 3d 27 2d 4f 27 0a 23 54 43 4c 5f 53  MIZE='-O'.#TCL_S
3470: 48 41 52 45 44 5f 42 55 49 4c 44 3d 31 0a 23 0a  HARED_BUILD=1.#.
3480: 23 54 43 4c 5f 50 52 45 46 49 58 3d 27 2f 75 73  #TCL_PREFIX='/us
3490: 72 2f 6c 6f 63 61 6c 27 0a 23 54 43 4c 5f 45 58  r/local'.#TCL_EX
34a0: 45 43 5f 50 52 45 46 49 58 3d 27 2f 75 73 72 2f  EC_PREFIX='/usr/
34b0: 6c 6f 63 61 6c 27 0a 23 0a 23 54 43 4c 5f 53 48  local'.#.#TCL_SH
34c0: 4c 49 42 5f 43 46 4c 41 47 53 3d 27 2d 66 50 49  LIB_CFLAGS='-fPI
34d0: 43 27 0a 23 54 43 4c 5f 53 48 4c 49 42 5f 4c 44  C'.#TCL_SHLIB_LD
34e0: 3d 27 63 63 20 2d 73 68 61 72 65 64 27 0a 23 54  ='cc -shared'.#T
34f0: 43 4c 5f 53 48 4c 49 42 5f 53 55 46 46 49 58 3d  CL_SHLIB_SUFFIX=
3500: 27 2e 73 6f 27 0a 23 54 43 4c 5f 44 4c 5f 4c 49  '.so'.#TCL_DL_LI
3510: 42 53 3d 27 2d 6c 64 6c 27 0a 23 54 43 4c 5f 4c  BS='-ldl'.#TCL_L
3520: 44 5f 46 4c 41 47 53 3d 27 2d 72 64 79 6e 61 6d  D_FLAGS='-rdynam
3530: 69 63 27 0a 23 54 43 4c 5f 4c 44 5f 53 45 41 52  ic'.#TCL_LD_SEAR
3540: 43 48 5f 46 4c 41 47 53 3d 27 27 0a 23 54 43 4c  CH_FLAGS=''.#TCL
3550: 5f 52 41 4e 4c 49 42 3d 27 3a 27 0a 23 54 43 4c  _RANLIB=':'.#TCL
3560: 5f 50 41 43 4b 41 47 45 5f 50 41 54 48 3d 27 2f  _PACKAGE_PATH='/
3570: 75 73 72 2f 6c 6f 63 61 6c 2f 6c 69 62 27 0a     usr/local/lib'.