ADDED ChangeLog Index: ChangeLog ================================================================== --- ChangeLog +++ ChangeLog @@ -0,0 +1,5 @@ + +2000-07-01 Johannes Zellner + + * switched to automake + * small fix so that itcl config switches are correctly completed. ADDED Makefile.am Index: Makefile.am ================================================================== --- Makefile.am +++ Makefile.am @@ -0,0 +1,28 @@ +## -*- automake -*- +## FILE: "/home/joze/src/tclreadline/Makefile.am" +## LAST MODIFICATION: "Sun, 02 Jul 2000 00:01:52 +0200 (joze)" +## (C) 2000 by Johannes Zellner, +## $Id$ +## --- +## tclreadline -- gnu readline for tcl +## http://www.zellner.org/tclreadline/ +## Copyright (c) 1998 - 2000, Johannes Zellner +## This software is copyright under the BSD license. +## --- + +## AUTOMAKE_OPTIONS = foreign + +lib_LTLIBRARIES = libtclreadline.la + +libtclreadline_la_SOURCES = config.h tclreadline.c tclreadline.h +INCLUDES = -I$(TCL_INCLUDE_DIR) -I$(READLINE_INCLUDE_DIR) + +## libtclreadline_la_LIBADD = $(LIBS) +libtclreadline_la_LDFLAGS = -release $(MAJOR).$(MINOR).$(PATCHLEVEL) + +tclrldir = @TCLRL_DIR@ +tclrl_SCRIPTS = pkgIndex.tcl tclreadlineCompleter.tcl tclreadlineInit.tcl tclreadlineSetup.tcl +INSTALL_SCRIPT = ${INSTALL_DATA} + +man_MANS = tclreadline.n + DELETED Makefile.in Index: Makefile.in ================================================================== --- Makefile.in +++ Makefile.in @@ -1,307 +0,0 @@ -# -*- make -*- -# FILE: "/home/joze/src/tclreadline/Makefile.in" -# LAST MODIFICATION: "Sat, 25 Mar 2000 20:50:24 +0100 (joze)" -# (C) 1998 - 2000 by Johannes Zellner, -# $Id$ -# --- -# -# tclreadline -- gnu readline for tcl -# http://www.zellner.org/tclreadline/ -# Copyright (c) 1998 - 2000, Johannes Zellner -# -# This software is copyright under the BSD license. -# -# ================================================================== - - -MAJOR_VERSION = @TCLREADLINE_MAJOR_VERSION@ -MINOR_VERSION = @TCLREADLINE_MINOR_VERSION@ -VERSION = @TCLREADLINE_VERSION@ -# NOTE, that PATCHLEVEL is the complete version string -# -PATCHLEVEL = $(VERSION).@TCLREADLINE_PATCHLEVEL@ - -#host = @host@ -#host_cpu = @host_cpu@ -#host_vendor = @host_vendor@ -#host_os = @host_os@ - -srcdir = @srcdir@ -VPATH = @srcdir@ - -#---------------------------------------------------------------- -# Things you can change to personalize the Makefile for your own -# site (you can make these changes in either Makefile.in or -# Makefile, but changes to Makefile will get lost if you re-run -# the configuration script). -#---------------------------------------------------------------- - -# Default top-level directories in which to install architecture- -# specific files (exec_prefix) and machine-independent files such -# as scripts (prefix). The values specified here may be overridden -# at configure-time with the --exec-prefix and --prefix options -# to the "configure" script. - -prefix = @prefix@ -exec_prefix = @exec_prefix@ - -bindir = @bindir@ - -# The following definition can be set to non-null for special systems -# like AFS with replication. It allows the pathnames used for installation -# to be different than those used for actually reference files at -# run-time. INSTALL_ROOT is prepended to $prefix and $exec_prefix -# when installing files. -INSTALL_ROOT = - -# Directory from which applications will reference the library of Tcl -# scripts (note: you can set the TCLREADLINE_LIBRARY environment variable at -# run-time to override the compiled-in location): -TCLREADLINE_LIBRARY = @TCLREADLINE_LIBRARY@ - -# Path name to use when installing library scripts: -LIBRARY_INSTALL_DIR = $(INSTALL_ROOT)$(TCLREADLINE_LIBRARY) - -# Directory in which to install the archive libitk.a: -LIB_INSTALL_DIR = $(INSTALL_ROOT)$(exec_prefix)/lib - -# Path to use at runtime to refer to LIB_INSTALL_DIR: -LIB_RUNTIME_DIR = $(exec_prefix)/lib - -# Top-level directory for manual entries: -# MAN_INSTALL_DIR = $(INSTALL_ROOT)$(prefix)/man -MAN_INSTALL_DIR = $(INSTALL_ROOT)@mandir@ - -# Directory in which to install manual entries for the built-in -# Tcl commands implemented by Tk: -MANN_INSTALL_DIR = $(MAN_INSTALL_DIR)/mann - - -# To change the compiler switches, for example to change from -O -# to -g, change the following line: -CFLAGS = @CFLAGS@ -CPPFLAGS = @CPPFLAGS@ - -# To disable ANSI-C procedure prototypes reverse the comment characters -# on the following lines: -PROTO_FLAGS = -#PROTO_FLAGS = -DNO_PROTOTYPE - - -# Some versions of make, like SGI's, use the following variable to -# determine which shell to use for executing commands: -SHELL = /bin/sh - -# Tk used to let the configure script choose which program to use -# for installing, but there are just too many different versions of -# "install" around; better to use the install-sh script that comes -# with the distribution, which is slower but guaranteed to work. - -INSTALL = $(TOP_DIR)/aux/install-sh -c -# INSTALL = @INSTALL@ -INSTALL_PROGRAM = ${INSTALL} -INSTALL_DATA = ${INSTALL} -m 644 -MKINSTALLDIRS = $(TOP_DIR)/aux/mkinstalldirs - -# The symbols below provide support for dynamic loading and shared -# libraries. The values of the symbols are normally set by the -# configure script. You shouldn't normally need to modify any of -# these definitions by hand. - -SHLIB_CFLAGS = @SHLIB_CFLAGS@ - - -# The symbol below provides support for dynamic loading and shared -# libraries. See configure.in for a description of what it means. -# The values of the symbolis normally set by the configure script. - -SHLIB_LD = @SHLIB_LD@ - -#---------------------------------------------------------------- -# The information below is modified by the configure script when -# Makefile is generated from Makefile.in. You shouldn't normally -# modify any of this stuff by hand. -#---------------------------------------------------------------- - -RANLIB = @RANLIB@ -TOP_DIR = $(srcdir) -TCL_INCLUDE_DIR = @TCL_INCLUDE_DIR@ -TCL_LIB_SPEC = @TCL_LIB_SPEC@ -TK_LIB_SPEC = @TK_LIB_SPEC@ -READLINE_INCLUDE_DIR = @READLINE_INCLUDE_DIR@ -TCLREADLINE_LIB_FILE = @TCLREADLINE_LIB_FILE@ - -READLINE_LIB = @READLINE_LIB_DIR@ -lreadline -TERMLIB = @TERMLIB@ -TERMLIB_DIR = @TERMLIB_DIR@ - -#---------------------------------------------------------------- -# The information below should be usable as is. The configure -# script won't modify it and you shouldn't need to modify it -# either. -#---------------------------------------------------------------- - - -CC = @CC@ -DEFS = @DEFS@ - -CC_SWITCHES = $(CFLAGS) $(SHLIB_CFLAGS) -I$(TOP_DIR) \ - -I$(TCL_INCLUDE_DIR) -I$(READLINE_INCLUDE_DIR) - -OBJS = tclreadline.o - -CSRCS = $(TOP_DIR)/tclreadline.c -TCLFILES = tclreadlineInit.tcl tclreadlineSetup.tcl tclreadlineCompleter.tcl - -SOURCES = \ - COPYING \ - AUTHORS \ - Makefile.in \ - README \ - configure.in \ - pkgIndex.tcl.in \ - sample.tclshrc \ - sources \ - config.h.in \ - tclreadline.c \ - tclreadline.h.in \ - tclreadline.n.in \ - tclreadlineConfig.sh.in \ - tclreadlineInit.tcl.in \ - tclreadlineSetup.tcl.in \ - tclreadlineCompleter.tcl \ - tclshrl.c \ - wishrl.c - -MISC = TODO - -AUXILIARY = \ - aux/config.guess \ - aux/config.sub \ - aux/install-sh \ - aux/mkinstalldirs \ - aux/vimtags - -MAN = tclreadline.n -HTML = tclreadline.n.html - - -all: $(TCLREADLINE_LIB_FILE) - - -.PHONY: clean distclean ctags tcltags vimtags tags ci co - -.SUFFIXES: .c .o .so .sl .tcl - - - -@TCLREADLINE_LIB_FILE@: ${OBJS} - rm -f $(TCLREADLINE_LIB_FILE) - @MAKE_LIB@ $(TERMLIB_DIR) $(READLINE_LIB) $(TERMLIB) - $(RANLIB) $(TCLREADLINE_LIB_FILE) - -shells: tclshrl wishrl - -tclshrl: $(OBJS) tclshrl.o - $(CC) -o tclshrl tclshrl.o $(OBJS) $(TERMLIB_DIR) $(READLINE_LIB) $(TERMLIB) $(TCL_LIB_SPEC) - -wishrl: $(OBJS) wishrl.o - $(CC) -o wishrl wishrl.o $(OBJS) $(TERMLIB_DIR) $(READLINE_LIB) $(TERMLIB) $(TK_LIB_SPEC) $(TCL_LIB_SPEC) - -install: install-binaries install-libraries install-man - -install-shells: install-tclshrl install-wishrl - -install-tclshrl: - $(MKINSTALLDIRS) $(bindir) - $(INSTALL_PROGRAM) tclshrl $(bindir)/tclshrl - -install-wishrl: - $(MKINSTALLDIRS) $(bindir) - $(INSTALL_PROGRAM) wishrl $(bindir)/wishrl - -install-man: $(MANN_INSTALL_DIR)/$(MAN) - -install-binaries: $(TCLREADLINE_LIB_FILE) - @$(MKINSTALLDIRS) $(LIBRARY_INSTALL_DIR) - @echo "Installing $(TCLREADLINE_LIB_FILE)" - @$(INSTALL_DATA) $(TCLREADLINE_LIB_FILE) \ - $(LIBRARY_INSTALL_DIR)/$(TCLREADLINE_LIB_FILE) - @(cd $(LIBRARY_INSTALL_DIR); $(RANLIB) $(TCLREADLINE_LIB_FILE)) - chmod 555 $(LIBRARY_INSTALL_DIR)/$(TCLREADLINE_LIB_FILE) - - -install-libraries: tclreadlineInit.tcl tclreadlineSetup.tcl \ - tclreadlineCompleter.tcl pkgIndex.tcl tclreadlineConfig.sh - @$(MKINSTALLDIRS) $(LIBRARY_INSTALL_DIR) - for f in \ - tclreadlineInit.tcl \ - tclreadlineSetup.tcl \ - tclreadlineCompleter.tcl \ - pkgIndex.tcl \ - tclreadlineConfig.sh\ - ; do \ - $(INSTALL_DATA) $$f $(LIBRARY_INSTALL_DIR) \ - ; done - -FORCE: - -$(MANN_INSTALL_DIR)/$(MAN): FORCE - - $(INSTALL_DATA) $(srcdir)/$(MAN) $@ && chmod 644 $@ - -tclreadline.n.html: tclreadline.n - rman -f html $^ > $@ - -Makefile: $(TOP_DIR)/Makefile.in - $(SHELL) config.status - -clean: - rm -f *.a *.o core errs *~ \#* tags* *.E a.out errors so_locations - -distclean: clean - rm -f \ - Makefile *.so.* *.sl pkgIndex.tcl tclreadlineInit.tcl \ - tclreadlineSetup.tcl config.h tclreadline.h tclreadline.n \ - tclreadlineConfig.sh config.status config.log config.cache - -depend: - makedepend -- $(CC_SWITCHES) -- $(CSRCS) - -configure: configure.in - autoconf - -tclreadline.o: $(TOP_DIR)/tclreadline.c Makefile - $(CC) -c $(CC_SWITCHES) $(DEFS) $(TOP_DIR)/tclreadline.c - -tclshrl.o: $(TOP_DIR)/tclshrl.c Makefile - $(CC) -c $(CC_SWITCHES) $(DEFS) $(TOP_DIR)/tclshrl.c - -wishrl.o: $(TOP_DIR)/wishrl.c Makefile - $(CC) -c $(CC_SWITCHES) $(DEFS) $(TOP_DIR)/wishrl.c - -ctags: - ctags -R - -tcltags: ctags tclreadlineInit.tcl.in tclreadlineSetup.tcl.in \ - tclreadlineCompleter.tcl - tcltags -a tclreadlineInit.tcl.in tclreadlineSetup.tcl.in \ - tclreadlineCompleter.tcl - -vimtags: tcltags - vimtags - -tags: vimtags - - -dist: distribution -distribution: $(SOURCES) configure $(AUXILIARY) tclreadline.n.html - - mkdir -p dist/tclreadline-$(PATCHLEVEL)/aux - - cp $(SOURCES) configure tclreadline.n.html dist/tclreadline-$(PATCHLEVEL) - - cp $(AUXILIARY) dist/tclreadline-$(PATCHLEVEL)/aux - (cd dist; tar zcvf tclreadline-$(PATCHLEVEL).tar.gz tclreadline-$(PATCHLEVEL); rm -rf tclreadline-$(PATCHLEVEL)) - - cp README dist/tclreadline-$(PATCHLEVEL).README - - echo AddDescription '"most recent version"' tclreadline-$(PATCHLEVEL).tar.gz > dist/.htaccess - - echo 'IndexOptions NameWidth=* SuppressHTMLPreamble FancyIndexing' >> dist/.htaccess - - -# DO NOT DELETE THIS LINE -- make depend depends on it. ADDED NEWS Index: NEWS ================================================================== --- NEWS +++ NEWS ADDED SCENARIO Index: SCENARIO ================================================================== --- SCENARIO +++ SCENARIO @@ -0,0 +1,28 @@ + +YOU TYPE: YOU GET: + + +=== SCENARIO 1 === + +puts $ puts $ + + a list of all variables ... +puts $t puts $t + + a list of all variables + beginning with t ... +puts $tcl_pl puts $tcl_platform( + + a list of all array names of + tcl_platform +puts $tcl_platform(b puts $tcl_platform(byteOrder) + + + +=== SCENARIO 2 === + +button .b button .b +.b co .b configure +.b co .b configure + + a list of all button options ... +.b co-r .b configure -relief +.b co-rg .b configure -relief groove + + ADDED autogen.sh Index: autogen.sh ================================================================== --- autogen.sh +++ autogen.sh @@ -0,0 +1,62 @@ +#!/bin/sh +# FILE: "/home/joze/src/tclreadline/autogen.sh" +# LAST MODIFICATION: "Sat, 01 Jul 2000 17:31:39 +0200 (joze)" +# (C) 2000 by Johannes Zellner, +# $Id$ + +srcdir=`dirname $0` +test -z "$srcdir" && srcdir=. + +ORIGDIR=`pwd` +cd $srcdir +PROJECT=tclreadline +TEST_TYPE=-f +FILE=tclreadline.h + +DIE=0 + +(autoconf --version) < /dev/null > /dev/null 2>&1 || { + echo + echo "You must have autoconf installed to compile $PROJECT." + echo "Download the appropriate package for your distribution," + echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/" + DIE=1 +} + +(automake --version) < /dev/null > /dev/null 2>&1 || { + echo + echo "You must have automake installed to compile $PROJECT." + echo "Get ftp://sourceware.cygnus.com/pub/automake/automake-1.4.tar.gz" + echo "(or a newer version if it is available)" + DIE=1 +} + +if test "$DIE" -eq 1; then + exit 1 +fi + +test $TEST_TYPE $FILE || { + echo "You must run this script in the top-level $PROJECT directory" + exit 1 +} + +if test -z "$*"; then + echo "I am going to run ./configure with no arguments - if you wish " + echo "to pass any to it, please specify them on the $0 command line." +fi + +case $CC in +*xlc | *xlc\ * | *lcc | *lcc\ *) am_opt=--include-deps;; +esac + +aclocal $ACLOCAL_FLAGS + +# optionally feature autoheader +(autoheader --version) < /dev/null > /dev/null 2>&1 && autoheader + +automake -a $am_opt +autoconf +cd $ORIGDIR + +$srcdir/configure --enable-maintainer-mode "$@" + DELETED aux/install-sh Index: aux/install-sh ================================================================== --- aux/install-sh +++ aux/install-sh @@ -1,250 +0,0 @@ -#! /bin/sh -# -# install - install a program, script, or datafile -# This comes from X11R5 (mit/util/scripts/install.sh). -# -# Copyright 1991 by the Massachusetts Institute of Technology -# -# Permission to use, copy, modify, distribute, and sell this software and its -# documentation for any purpose is hereby granted without fee, provided that -# the above copyright notice appear in all copies and that both that -# copyright notice and this permission notice appear in supporting -# documentation, and that the name of M.I.T. not be used in advertising or -# publicity pertaining to distribution of the software without specific, -# written prior permission. M.I.T. makes no representations about the -# suitability of this software for any purpose. It is provided "as is" -# without express or implied warranty. -# -# Calling this script install-sh is preferred over install.sh, to prevent -# `make' implicit rules from creating a file called install from it -# when there is no Makefile. -# -# This script is compatible with the BSD install script, but was written -# from scratch. It can only install one file at a time, a restriction -# shared with many OS's install programs. - - -# set DOITPROG to echo to test this script - -# Don't use :- since 4.3BSD and earlier shells don't like it. -doit="${DOITPROG-}" - - -# put in absolute paths if you don't have them in your path; or use env. vars. - -mvprog="${MVPROG-mv}" -cpprog="${CPPROG-cp}" -chmodprog="${CHMODPROG-chmod}" -chownprog="${CHOWNPROG-chown}" -chgrpprog="${CHGRPPROG-chgrp}" -stripprog="${STRIPPROG-strip}" -rmprog="${RMPROG-rm}" -mkdirprog="${MKDIRPROG-mkdir}" - -transformbasename="" -transform_arg="" -instcmd="$mvprog" -chmodcmd="$chmodprog 0755" -chowncmd="" -chgrpcmd="" -stripcmd="" -rmcmd="$rmprog -f" -mvcmd="$mvprog" -src="" -dst="" -dir_arg="" - -while [ x"$1" != x ]; do - case $1 in - -c) instcmd="$cpprog" - shift - continue;; - - -d) dir_arg=true - shift - continue;; - - -m) chmodcmd="$chmodprog $2" - shift - shift - continue;; - - -o) chowncmd="$chownprog $2" - shift - shift - continue;; - - -g) chgrpcmd="$chgrpprog $2" - shift - shift - continue;; - - -s) stripcmd="$stripprog" - shift - continue;; - - -t=*) transformarg=`echo $1 | sed 's/-t=//'` - shift - continue;; - - -b=*) transformbasename=`echo $1 | sed 's/-b=//'` - shift - continue;; - - *) if [ x"$src" = x ] - then - src=$1 - else - # this colon is to work around a 386BSD /bin/sh bug - : - dst=$1 - fi - shift - continue;; - esac -done - -if [ x"$src" = x ] -then - echo "install: no input file specified" - exit 1 -else - true -fi - -if [ x"$dir_arg" != x ]; then - dst=$src - src="" - - if [ -d $dst ]; then - instcmd=: - else - instcmd=mkdir - fi -else - -# Waiting for this to be detected by the "$instcmd $src $dsttmp" command -# might cause directories to be created, which would be especially bad -# if $src (and thus $dsttmp) contains '*'. - - if [ -f $src -o -d $src ] - then - true - else - echo "install: $src does not exist" - exit 1 - fi - - if [ x"$dst" = x ] - then - echo "install: no destination specified" - exit 1 - else - true - fi - -# If destination is a directory, append the input filename; if your system -# does not like double slashes in filenames, you may need to add some logic - - if [ -d $dst ] - then - dst="$dst"/`basename $src` - else - true - fi -fi - -## this sed command emulates the dirname command -dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` - -# Make sure that the destination directory exists. -# this part is taken from Noah Friedman's mkinstalldirs script - -# Skip lots of stat calls in the usual case. -if [ ! -d "$dstdir" ]; then -defaultIFS=' -' -IFS="${IFS-${defaultIFS}}" - -oIFS="${IFS}" -# Some sh's can't handle IFS=/ for some reason. -IFS='%' -set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'` -IFS="${oIFS}" - -pathcomp='' - -while [ $# -ne 0 ] ; do - pathcomp="${pathcomp}${1}" - shift - - if [ ! -d "${pathcomp}" ] ; - then - $mkdirprog "${pathcomp}" - else - true - fi - - pathcomp="${pathcomp}/" -done -fi - -if [ x"$dir_arg" != x ] -then - $doit $instcmd $dst && - - if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi && - if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi && - if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi && - if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi -else - -# If we're going to rename the final executable, determine the name now. - - if [ x"$transformarg" = x ] - then - dstfile=`basename $dst` - else - dstfile=`basename $dst $transformbasename | - sed $transformarg`$transformbasename - fi - -# don't allow the sed command to completely eliminate the filename - - if [ x"$dstfile" = x ] - then - dstfile=`basename $dst` - else - true - fi - -# Make a temp file name in the proper directory. - - dsttmp=$dstdir/#inst.$$# - -# Move or copy the file name to the temp name - - $doit $instcmd $src $dsttmp && - - trap "rm -f ${dsttmp}" 0 && - -# and set any options; do chmod last to preserve setuid bits - -# If any of these fail, we abort the whole thing. If we want to -# ignore errors from any of these, just make sure not to ignore -# errors from the above "$doit $instcmd $src $dsttmp" command. - - if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi && - if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi && - if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi && - if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi && - -# Now rename the file to the real destination. - - $doit $rmcmd -f $dstdir/$dstfile && - $doit $mvcmd $dsttmp $dstdir/$dstfile - -fi && - - -exit 0 DELETED aux/mkinstalldirs Index: aux/mkinstalldirs ================================================================== --- aux/mkinstalldirs +++ aux/mkinstalldirs @@ -1,40 +0,0 @@ -#! /bin/sh -# mkinstalldirs --- make directory hierarchy -# Author: Noah Friedman -# Created: 1993-05-16 -# Public domain - -# $Id$ - -errstatus=0 - -for file -do - set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` - shift - - pathcomp= - for d - do - pathcomp="$pathcomp$d" - case "$pathcomp" in - -* ) pathcomp=./$pathcomp ;; - esac - - if test ! -d "$pathcomp"; then - echo "mkdir $pathcomp" 1>&2 - - mkdir "$pathcomp" || lasterr=$? - - if test ! -d "$pathcomp"; then - errstatus=$lasterr - fi - fi - - pathcomp="$pathcomp/" - done -done - -exit $errstatus - -# mkinstalldirs ends here Index: config.h.in ================================================================== --- config.h.in +++ config.h.in @@ -1,24 +1,29 @@ - - /* ================================================================== - - FILE: "/home/joze/src/tclreadline/config.h.in" - LAST MODIFICATION: "Sat, 25 Mar 2000 20:46:56 +0100 (joze)" - (C) 1998 - 2000 by Johannes Zellner, - $Id$ - vim:set ft=c: - --- - - tclreadline -- gnu readline for tcl - http://www.zellner.org/tclreadline/ - Copyright (c) 1998 - 2000, Johannes Zellner - - This software is copyright under the BSD license. - - ================================================================== */ - - +/* config.h.in. Generated automatically from configure.in by autoheader. */ + +/* Define to empty if the keyword does not work. */ +#undef const + +/* Define if you have the ANSI C header files. */ +#undef STDC_HEADERS + +/* Define if you have the header file. */ +#undef HAVE_STRING_H + +/* Define if you have the readline library (-lreadline). */ +#undef HAVE_LIBREADLINE + +/* Name of package */ +#undef PACKAGE + +/* Version number of package */ +#undef VERSION + +/* Define if we have libreadline. */ +#undef READLINE_LIBRARY + +/* Define if _rl_executing_macro is resolved in libreadline. */ #undef EXECUTING_MACRO_HACK +/* Define if rl_cleanup_after_signal is resolved in libreadline. */ #undef CLEANUP_AFER_SIGNAL -#undef READLINE_LIBRARY Index: configure.in ================================================================== --- configure.in +++ configure.in @@ -1,48 +1,62 @@ dnl -*- autoconf -*- dnl FILE: "/home/joze/src/tclreadline/configure.in" -dnl LAST MODIFICATION: "Sat, 01 Jul 2000 16:19:57 +0200 (joze)" +dnl LAST MODIFICATION: "Sun, 02 Jul 2000 00:12:15 +0200 (joze)" dnl (C) 1998 - 2000 by Johannes Zellner, dnl $Id$ dnl --- -dnl dnl tclreadline -- gnu readline for tcl dnl http://www.zellner.org/tclreadline/ dnl Copyright (c) 1998 - 2000, Johannes Zellner -dnl dnl This software is copyright under the BSD license. -dnl -dnl ================================================================== */ - AC_INIT(tclreadline.c) -AC_CONFIG_HEADER(config.h) +AM_CONFIG_HEADER(config.h) AC_PREREQ(2.13) AC_REVISION($Revision$) AC_CONFIG_AUX_DIR(./aux) -TCLREADLINE_MAJOR_VERSION=1 -TCLREADLINE_MINOR_VERSION=2 -TCLREADLINE_PATCHLEVEL=1 -TCLREADLINE_VERSION=$TCLREADLINE_MAJOR_VERSION.$TCLREADLINE_MINOR_VERSION -TCLREADLINE_PATCHLEVEL_STR=${TCLREADLINE_VERSION}.${TCLREADLINE_PATCHLEVEL} -VERSION=$TCLREADLINE_VERSION +MAJOR=2 +MINOR=0 +PATCHLEVEL=0 +VERSION=$MAJOR.$MINOR +PATCHLEVEL_STR=$VERSION.$PATCHLEVEL + +AC_SUBST(MAJOR) +AC_SUBST(MINOR) +AC_SUBST(PATCHLEVEL) +AC_SUBST(VERSION) +AC_SUBST(PATCHLEVEL_STR) + +AM_INIT_AUTOMAKE(tclreadline, $VERSION) + + +AC_PROG_MAKE_SET dnl AM_INIT_AUTOMAKE(tclreadline, $VERSION) AC_CANONICAL_HOST +AC_PROG_CC +AC_EXEEXT +dnl AC_LIBTOOL_DLOPEN +AM_PROG_LIBTOOL +AC_SUBST(LIBTOOL_DEPS) +if ${CONFIG_SHELL} ./libtool --features | grep "enable static" >/dev/null; then + STATIC=-static +else + STATIC= +fi +AC_SUBST(STATIC) -TCLREADLINE_LPATH=`echo $LD_LIBRARY_PATH $LD_RUN_PATH $LPATH | sed 's/:/ /g'` -TCLREADLINE_LPATH="$TCLREADLINE_LPATH /usr/local/lib /lib /usr/lib /usr/shlib" +AC_C_CONST +AC_PROG_INSTALL +AC_PROG_RANLIB +AC_PROG_LN_S -#-------------------------------------------------------------------- -# See if there was a command-line option for where Tcl is; if -# not, search for Tcl. -#-------------------------------------------------------------------- - +# -- WHICH TCL TO USE AC_ARG_WITH( tcl, [ --with-tcl=DIR where to look for tclConfig.sh], tcl_search=$withval, tcl_search="" @@ -57,75 +71,21 @@ fi done if test -z "$TCL_LIB_DIR"; then AC_MSG_ERROR(Can't find Tcl libraries. Use --with-tcl to specify the directory containing tclConfig.sh on your system.) -else - . $TCL_LIB_DIR/tclConfig.sh - AC_MSG_RESULT($TCL_LIB_DIR/tclConfig.sh) - AC_MSG_CHECKING([for your tcl version]) - AC_MSG_RESULT([$TCL_VERSION, patchlevel $TCL_PATCH_LEVEL]) -fi - -#-------------------------------------------------------------------- -# eventually check for tkConfig.sh -#-------------------------------------------------------------------- - -tk_search="no" -AC_ARG_WITH( - tk, - [ --with-tk=DIR where to look for tkConfig.sh], - tk_search=$withval, - tk_search="yes" -) - -if test "$tk_search" != "no"; then - AC_MSG_CHECKING([which tkConfig.sh to use]) - TK_LIB_DIR="" - for dir in $tk_search $TCL_LIB_DIR /usr/lib /usr/local/lib $exec_prefix/lib /usr/local/lib/unix /opt/tcl/lib; do - if test -r $dir/tkConfig.sh; then - TK_LIB_DIR=$dir - break - fi - done - - if ! test -z "$TK_LIB_DIR"; then - . $TK_LIB_DIR/tkConfig.sh - AC_MSG_RESULT($TK_LIB_DIR/tkConfig.sh) - AC_MSG_CHECKING([for your tk version]) - AC_MSG_RESULT([$TK_VERSION, patchlevel $TK_PATCH_LEVEL]) - AC_SUBST(TK_LIB_SPEC) - fi -fi - -#-------------------------------------------------------------------- -# Read in configuration information generated by Tcl for shared -# libraries, and arrange for it to be substituted into our -# Makefile. -#-------------------------------------------------------------------- - - -SHLIB_CFLAGS=$TCL_SHLIB_CFLAGS -SHLIB_LD=$TCL_SHLIB_LD -if test $TCL_SHLIB_SUFFIX = ""; then - AC_MSG_ERROR(TCL_SHLIB_SUFFIX not defined -- should be something like .so or .sl on unix.) -else - SHLIB_SUFFIX=$TCL_SHLIB_SUFFIX -fi -DL_LIBS=$TCL_DL_LIBS -LD_FLAGS=$TCL_LD_FLAGS -SHLIB_LD_LIBS=$TCL_SHLIB_LD_LIBS -TCLREADLINE_PACKAGE_PATH=$TCL_PACKAGE_PATH - - -#-------------------------------------------------------------------- -# Check, if tcl_version is > 8.0 -#-------------------------------------------------------------------- +fi + +. $TCL_LIB_DIR/tclConfig.sh +AC_MSG_RESULT($TCL_LIB_DIR/tclConfig.sh) +AC_MSG_CHECKING([for your tcl version]) +AC_MSG_RESULT([$TCL_VERSION, patchlevel $TCL_PATCH_LEVEL]) + +# Check, if tcl_version is > 8.0 if test $TCL_MAJOR_VERSION -lt 8; then AC_MSG_ERROR(need tcl 8.0 or higher.) fi - # ----------------------------------------------------------------------- # Set up a new default --prefix. # ----------------------------------------------------------------------- @@ -134,136 +94,16 @@ # AC_PREFIX_DEFAULT(/usr/local) if test "${prefix}" = "NONE"; then prefix=$TCL_PREFIX fi -if test "${exec_prefix}" = "NONE"; then - exec_prefix=$TCL_EXEC_PREFIX -else - TCLREADLINE_PACKAGE_PATH=${exec_prefix}/lib -fi - -TCLREADLINE_LIBRARY=${exec_prefix}/lib/tclreadline$TCLREADLINE_VERSION - - -# ----------------------------------------------------------------------- -# Check for some programs here. -# ----------------------------------------------------------------------- - -AC_PROG_INSTALL -AC_PROG_RANLIB -AC_PROG_LN_S - - - -# ----------------------------------------------------------------------- -# Prefer the compiler, which was used -# to build tcl. -# ----------------------------------------------------------------------- - - -AC_ARG_ENABLE(gcc, [ --enable-gcc allow use of gcc if available], - [gcc_ok=$enableval], [gcc_ok=no]) -if test "$gcc_ok" = "yes"; then - AC_PROG_CC -else - CC=$TCL_CC - AC_SUBST(CC) -fi - - - - -# ----------------------------------------------------------------------- -# checking for the preprocessor. -# FIXME: do we need this ? -# ----------------------------------------------------------------------- - -AC_PROG_CPP - - -if test -z "$CFLAGS" ; then - CFLAGS=$TCL_CFLAGS_OPTIMIZE -fi - -dnl #-------------------------------------------------------------------- -dnl # If this is gcc, add some extra compile flags. -dnl #-------------------------------------------------------------------- -dnl -dnl AC_MSG_CHECKING([whether C compiler is gcc]) -dnl AC_CACHE_VAL(tclreadline_cv_prog_gcc, -dnl AC_EGREP_CPP(_cc_is_gcc_, [ -dnl #ifdef __GNUC__ -dnl _cc_is_gcc_ -dnl #endif -dnl ], [tclreadline_cv_prog_gcc=yes], [tclreadline_cv_prog_gcc=no])) -dnl AC_MSG_RESULT([$tclreadline_cv_prog_gcc]) -dnl -dnl if test -z "$CFLAGS" ; then -dnl CFLAGS=$TCL_CFLAGS_OPTIMIZE -dnl fi -dnl if test "$tclreadline_cv_prog_gcc" = "yes" ; then -dnl CFLAGS="$CFLAGS -Wshadow -Wtraditional -Wall" -dnl fi -dnl -dnl AC_MSG_CHECKING([default compiler flags]) -dnl AC_ARG_WITH(cflags, [ --with-cflags=FLAGS set compiler flags to FLAGS], -dnl [CFLAGS="$with_cflags"]) -dnl -dnl AC_MSG_RESULT([$CFLAGS]) - -if test "$TCL_CC" != "$CC" ; then - echo "" - echo "WARNING: Compiler is $CC but Tcl was compiled with $TCL_CC" - echo "" -fi - -#-------------------------------------------------------------------- -# The statements below define a collection of symbols related to -# building libtclreadline as a shared library instead of a static library. -# (static is not implemented yet anyway). -#-------------------------------------------------------------------- - -AC_ARG_ENABLE(shared, - [ --disable-shared don't build libtclreadline as a shared library.], - [ok=$enableval], [ok=yes]) -if test "$ok" = "yes"; then - if test ${TCL_SHARED_BUILD} = 0; then - AC_MSG_ERROR(Tcl was not built with --enable-shared, so you can't use shared libraries.) - fi - SHLIB_CFLAGS="${SHLIB_CFLAGS}" - eval "TCLREADLINE_LIB_FILE=libtclreadline${VERSION}${SHLIB_SUFFIX}" - TCLREADLINE_PKG_FILE="[[file join [file dirname \$dir] ${TCLREADLINE_LIB_FILE}]]" - MAKE_LIB="\$(SHLIB_LD) -o ${TCLREADLINE_LIB_FILE} \$(OBJS) ${SHLIB_LD_LIBS}" - RANLIB=":" -else - SHLIB_CFLAGS="" - eval "TCLREADLINE_LIB_FILE=libtclreadline${VERSION}.a" - TCLREADLINE_PKG_FILE="[[file join [file dirname \$dir] ${TCLREADLINE_LIB_FILE}]]" - MAKE_LIB="ar cr ${TCLREADLINE_LIB_FILE} \${OBJS}" -fi - -# Note: in the following variable, it's important to use the absolute -# path name of the Tcl directory rather than "..": this is because -# AIX remembers this path and will attempt to use it at run-time to look -# up the Tcl library. - -if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then - TCLREADLINE_BUILD_LIB_SPEC="-L`pwd` -ltclreadline${VERSION}" - TCLREADLINE_LIB_SPEC="-L${TCLREADLINE_LIBRARY} -ltclreadline${VERSION}" -else - TCLREADLINE_BUILD_LIB_SPEC="-L`pwd` -ltclreadline`echo ${VERSION} | tr -d .`" - TCLREADLINE_LIB_SPEC="-L${TCLREADLINE_LIBRARY} -ltclreadline`echo ${VERSION} | tr -d .`" -fi - - - - -# HEADER CHECKS -# +TCLRL_DIR="${prefix}/lib/tclreadline$VERSION" +AC_SUBST(TCLRL_DIR) + +# HEADERS AC_HEADER_STDC - +AC_CHECK_HEADERS(string.h) #-------------------------------------------------------------------- # Check for tcl.h #-------------------------------------------------------------------- @@ -293,12 +133,11 @@ #-------------------------------------------------------------------- # Check for readline.h #-------------------------------------------------------------------- AC_ARG_WITH(readline-includes, - [ --with-readline-includes=DIR - readline include files in DIR], + [ --with-readline-includes=DIR readline include files in DIR], rl_includes=$withval, rl_includes="") AC_MSG_CHECKING([where to look for readline.h]) READLINE_INCLUDE_DIR="" for dir in $rl_includes /usr/local/include/readline /usr/local/include /usr/include/readline /usr/include ; do @@ -319,133 +158,45 @@ if test "x${base}" != "xreadline"; then AC_DEFINE_UNQUOTED(READLINE_LIBRARY, 1, [ Define if we have libreadline. ]) fi fi - - -#-------------------------------------------------------------------- -# Check for libreadline -#-------------------------------------------------------------------- - AC_ARG_WITH(readline-library, - [ --with-readline-library=DIR - readline library files in DIR], - rl_library=$withval, rl_library="") - -AC_MSG_CHECKING([where to look for libreadline$SHLIB_SUFFIX]) -READLINE_LIB_DIR="" -READLINE_VERSION_SUFFIX="" -for dir in $rl_library $TCLREADLINE_LPATH $prefix/lib/readline; do - if test -r $dir/libreadline$SHLIB_SUFFIX; then - READLINE_LIB_DIR=$dir - break - fi - if test -r $dir/libreadline$SHLIB_SUFFIX.4; then - READLINE_VERSION_SUFFIX=".4" - READLINE_LIB_DIR=$dir - break - fi - if test -r $dir/libreadline$SHLIB_SUFFIX.4.0; then - READLINE_VERSION_SUFFIX=".4.0" - READLINE_LIB_DIR=$dir - break - fi - if test -r $dir/libreadline$SHLIB_SUFFIX.3; then - READLINE_VERSION_SUFFIX=".3" - READLINE_LIB_DIR=$dir - break - fi - if test -r $dir/libreadline$SHLIB_SUFFIX.3.0; then - READLINE_VERSION_SUFFIX=".3.0" - READLINE_LIB_DIR=$dir - break - fi -done - -if test -z "$READLINE_LIB_DIR"; then - AC_MSG_ERROR([ - Can't find libreadline$SHLIB_SUFFIX. - Use --with-readline-library to specify the directory - containing libreadline$SHLIB_SUFFIX on your system.]) -else - AC_MSG_RESULT(${READLINE_LIB_DIR}/libreadline${SHLIB_SUFFIX}${READLINE_VERSION_SUFFIX}) -fi - -READLINE_LIB_DIR="-L${READLINE_LIB_DIR}" - - + [ --with-readline-library=DIR + lib spec to readline (e.g. '-L/usr/local/lib -lreadline')], + LIBS="$LIBS $withval", + AC_CHECK_LIB(readline, rl_callback_read_char, , + AC_MSG_RESULT([ + Your readline version does not support readline's alternate interface. + Please upgrade to readline >= 2.2 and retry. + ]) + exit + ) +) # --- # check for the terminal library. # --- -olibs=${LIBS} AC_ARG_WITH(tlib-library, - [ --with-tlib-library=DIR - where to search for curses / termcap], - tlib_library=$withval, tlib_library="") - -AC_MSG_CHECKING([where to look for the terminal library]) -TERMLIB_DIR="" -TERMLIB_VERSION_SUFFIX="" -for dir in $tlib_library $TCLREADLINE_LPATH $prefix/lib/; do - for tlib in ncurses termlib termcap curses; do - dnl It's possible that a library is found but it doesn't work - dnl e.g., shared library that cannot be found - dnl compile and run a test program to be sure - dnl echo "" - dnl echo "" - LIBS="-L${dir} -l${tlib}" - AC_TRY_RUN([ -#ifdef HAVE_TERMCAP_H -# include -#endif -main() {char *s; s=(char *)tgoto("%p1%d", 0, 1); exit(0); }], - res="OK", res="FAIL", res="FAIL") - if test "$res" = "OK"; then - TERMLIB_DIR=-L${dir} - if test "`(uname) 2>/dev/null`" = SunOS && - uname -r | grep '^5' >/dev/null; then - TERMLIB_DIR_R="${TERMLIB_DIR} -R${dir}" - fi - TERMLIB=-l${tlib} - break - fi - if test "x${TERMLIB_DIR}" = "x"; then - AC_MSG_RESULT($LIBS is unusable) - else - break - fi - done - if test "x${TERMLIB_DIR}" != "x"; then - break - fi -done - -if test "x$TERMLIB_DIR" = "x"; then - AC_MSG_ERROR([ -no terminal library found. Please retry with the --with-tlib argument.]) -else - AC_MSG_RESULT(${TERMLIB_DIR} ${TERMLIB}) -fi - - -#-------------------------------------------------------------------- -# Check for appropriate version of gnu readline -# (older versions of gnu readline don't have -# rl_callback_read_char ()). -#-------------------------------------------------------------------- - -LIBS="${READLINE_LIB_DIR} ${TERMLIB_DIR} -lreadline $TERMLIB $olibs" -alternate=no -AC_CHECK_FUNC( - rl_callback_read_char, alternate=yes, alternate=no -) -if test "$alternate" = "no"; then - AC_MSG_ERROR(alternate interface not supported by this readline version.) -fi + [ --with-tlib-library=DIR + lib spec to tlib (e.g. '-L/usr/local/lib -lncurses')], + LIBS="$LIBS $withval", + for tlib in ncurses termlib termcap curses; do + brk=yes + AC_CHECK_LIB($tlib, tputs, , brk=no) + if test $brk == "yes"; then + HAVE_TLIB=yes + break + fi + done + if test "x" = "x$HAVE_TLIB"; then + AC_MSG_ERROR([ + no terminal library found. Please retry with the --with-tlib argument. + ]) + fi +) # check for readline's (macro.c) private variable # _rl_executing_macro. @@ -483,75 +234,12 @@ return 0; }], READLINE_VERSION=`cat conftestversion` AC_MSG_RESULT($READLINE_VERSION), AC_MSG_RESULT(failed), - AC_MSG_RESULT(no cross compiling)) - - - - -# This is a test -#AC_C_BIGENDIAN - -# TODO: check for readline version -# (link testprogram with -lreadline) - -AC_SUBST(TCLREADLINE_MAJOR_VERSION) -AC_SUBST(TCLREADLINE_MINOR_VERSION) -AC_SUBST(TCLREADLINE_VERSION) -AC_SUBST(TCLREADLINE_PATCHLEVEL) -AC_SUBST(TCLREADLINE_LIBRARY) -AC_SUBST(TCLREADLINE_PATCHLEVEL_STR) - - -AC_SUBST(TCL_LIB_DIR) -AC_SUBST(TCL_LIB_SPEC) + AC_MSG_RESULT(no cross compiling) +) + + AC_SUBST(TCL_INCLUDE_DIR) AC_SUBST(READLINE_INCLUDE_DIR) - -AC_SUBST(CFLAGS) -AC_SUBST(DL_LIBS) -AC_SUBST(LD_FLAGS) -AC_SUBST(RANLIB) - -AC_SUBST(MAKE_LIB) -AC_SUBST(SHLIB_CFLAGS) - -AC_SUBST(SHLIB_LD) -AC_SUBST(SHLIB_LD_LIBS) - -AC_SUBST(SHLIB_SUFFIX) - -AC_SUBST(TERMLIB) -AC_SUBST(TERMLIB_DIR) -AC_SUBST(READLINE_LIB_DIR) - -AC_SUBST(TCLREADLINE_LIB_FILE) -AC_SUBST(TCLREADLINE_BUILD_LIB_SPEC) -AC_SUBST(TCLREADLINE_LIB_SPEC) - -AC_SUBST(TCLREADLINE_LIB_DIR) -AC_SUBST(TCLREADLINE_PKG_FILE) - -AC_SUBST(TCLREADLINE_PACKAGE_PATH) - - -AC_OUTPUT(Makefile tclreadline.h tclreadlineInit.tcl tclreadlineSetup.tcl tclreadlineConfig.sh tclreadline.n pkgIndex.tcl) - - -#TCL_CC='cc' -#TCL_CFLAGS_DEBUG='-g' -#TCL_CFLAGS_OPTIMIZE='-O' -#TCL_SHARED_BUILD=1 -# -#TCL_PREFIX='/usr/local' -#TCL_EXEC_PREFIX='/usr/local' -# -#TCL_SHLIB_CFLAGS='-fPIC' -#TCL_SHLIB_LD='cc -shared' -#TCL_SHLIB_SUFFIX='.so' -#TCL_DL_LIBS='-ldl' -#TCL_LD_FLAGS='-rdynamic' -#TCL_LD_SEARCH_FLAGS='' -#TCL_RANLIB=':' -#TCL_PACKAGE_PATH='/usr/local/lib' +AC_OUTPUT(Makefile tclreadline.h tclreadlineInit.tcl tclreadlineSetup.tcl tclreadline.n pkgIndex.tcl) Index: pkgIndex.tcl.in ================================================================== --- pkgIndex.tcl.in +++ pkgIndex.tcl.in @@ -1,17 +1,13 @@ #!/usr/local/bin/tclsh # FILE: "/home/joze/src/tclreadline/pkgIndex.tcl.in" -# LAST MODIFICATION: "Sat, 25 Mar 2000 20:49:59 +0100 (joze)" +# LAST MODIFICATION: "Sat, 01 Jul 2000 21:53:04 +0200 (joze)" # (C) 1998 - 2000 by Johannes Zellner, # $Id$ # --- -# # tclreadline -- gnu readline for tcl # http://www.zellner.org/tclreadline/ # Copyright (c) 1998 - 2000, Johannes Zellner -# # This software is copyright under the BSD license. -# -# ================================================================== -package ifneeded tclreadline @TCLREADLINE_VERSION@ \ +package ifneeded tclreadline @VERSION@ \ [list source [file join $dir tclreadlineInit.tcl]] Index: tclreadline.c ================================================================== --- tclreadline.c +++ tclreadline.c @@ -1,20 +1,16 @@ /* ================================================================== - FILE: "/home/joze/src/tclreadline/tclreadline.c" - LAST MODIFICATION: "Sat, 25 Mar 2000 21:40:27 +0100 (joze)" + LAST MODIFICATION: "Sat, 01 Jul 2000 23:47:30 +0200 (joze)" (C) 1998 - 2000 by Johannes Zellner, $Id$ --- - tclreadline -- gnu readline for tcl http://www.zellner.org/tclreadline/ Copyright (c) 1998 - 2000, Johannes Zellner - This software is copyright under the BSD license. - ================================================================== */ #ifdef HAVE_CONFIG_H # include "config.h" #endif @@ -30,11 +26,12 @@ #else # include # include #endif -/** + +/* * this prototype is missing * in readline.h */ void rl_extend_line_buffer(int len); @@ -541,11 +538,11 @@ if (TCL_OK != (status = Tcl_LinkVar(interp, "::tclreadline::historyLength", (char*) &tclrl_history_length, TCL_LINK_INT))) return status; if (TCL_OK != (status = Tcl_LinkVar(interp, "::tclreadline::library", - (char*) &TCLRL_LIBRARY, TCL_LINK_STRING | TCL_LINK_READ_ONLY))) + (char*) &tclrl_library, TCL_LINK_STRING | TCL_LINK_READ_ONLY))) return status; if (TCL_OK != (status = Tcl_LinkVar(interp, "::tclreadline::version", (char*) &TCLRL_VERSION, TCL_LINK_STRING | TCL_LINK_READ_ONLY))) return status; if (TCL_OK != (status = Tcl_LinkVar(interp, "::tclreadline::patchLevel", @@ -554,11 +551,11 @@ if (TCL_OK != (status = Tcl_LinkVar(interp, "::tclreadline::license", (char*) &tclrl_license, TCL_LINK_STRING | TCL_LINK_READ_ONLY))) return status; if (TCL_OK != (status = Tcl_LinkVar(interp, "tclreadline_library", - (char*) &TCLRL_LIBRARY, TCL_LINK_STRING | TCL_LINK_READ_ONLY))) + (char*) &tclrl_library, TCL_LINK_STRING | TCL_LINK_READ_ONLY))) return status; if (TCL_OK != (status = Tcl_LinkVar(interp, "tclreadline_version", (char*) &TCLRL_VERSION, TCL_LINK_STRING | TCL_LINK_READ_ONLY))) return status; if (TCL_OK != (status = Tcl_LinkVar(interp, "tclreadline_patchLevel", Index: tclreadline.h.in ================================================================== --- tclreadline.h.in +++ tclreadline.h.in @@ -1,27 +1,23 @@ /* ================================================================== - FILE: "/home/joze/src/tclreadline/tclreadline.h.in" - LAST MODIFICATION: "Sat, 25 Mar 2000 20:48:54 +0100 (joze)" + LAST MODIFICATION: "Sat, 01 Jul 2000 23:46:41 +0200 (joze)" (C) 1998 - 2000 by Johannes Zellner, $Id$ vim:set ft=c: --- - tclreadline -- gnu readline for tcl http://www.zellner.org/tclreadline/ Copyright (c) 1998 - 2000, Johannes Zellner - This software is copyright under the BSD license. - ================================================================== */ -static char *TCLRL_VERSION = "@TCLREADLINE_VERSION@"; +static char *TCLRL_VERSION = "@VERSION@"; -static char *TCLRL_LIBRARY = "@TCLREADLINE_LIBRARY@"; +static char* tclrl_library = "@TCLRL_DIR@"; -/** +/* * NOTE, that PATCHLEVEL is the complete version string. */ -static char *TCLRL_PATCHLEVEL = "@TCLREADLINE_PATCHLEVEL_STR@"; +static char *TCLRL_PATCHLEVEL = "@PATCHLEVEL_STR@"; Index: tclreadline.n.in ================================================================== --- tclreadline.n.in +++ tclreadline.n.in @@ -1,17 +1,15 @@ .TH tclreadline n "@TCLREADLINE_VERSION@.@TCLREADLINE_PATCHLEVEL@" "Johannes Zellner" .\" FILE: "/home/joze/src/tclreadline/tclreadline.n.in" -.\" LAST MODIFICATION: "Sat, 25 Mar 2000 21:51:43 +0100 (joze)" +.\" LAST MODIFICATION: "Sat, 01 Jul 2000 21:52:43 +0200 (joze)" .\" (C) 1998 - 2000 by Johannes Zellner, .\" $Id$ .\" --- -.\" .\" tclreadline -- gnu readline for tcl .\" http://www.zellner.org/tclreadline/ .\" Copyright (c) 1998 - 2000, Johannes Zellner -.\" .\" This software is copyright under the BSD license. .\" # CS - begin code excerpt .de CS Index: tclreadlineConfig.sh.in ================================================================== --- tclreadlineConfig.sh.in +++ tclreadlineConfig.sh.in @@ -1,19 +1,16 @@ #!/bin/sh # FILE: "/home/joze/src/tclreadline/tclreadlineConfig.sh.in" -# LAST MODIFICATION: "Sat, 25 Mar 2000 20:51:07 +0100 (joze)" +# LAST MODIFICATION: "Sat, 01 Jul 2000 21:52:25 +0200 (joze)" # (C) 1998 - 2000 by Johannes Zellner, # $Id$ # --- -# # tclreadline -- gnu readline for tcl # http://www.zellner.org/tclreadline/ # Copyright (c) 1998 - 2000, Johannes Zellner -# # This software is copyright under the BSD license. -# -# ================================================================== +# --- # # This shell script (for sh) is generated automatically by tclreadline's # configure script. It will create shell variables for most of # the configuration options discovered by the configure script. # This script is intended to be included by the configure scripts @@ -23,26 +20,11 @@ # file in addition to this one. # # The information in this file is specific to a single platform. # tclreadline's version number. -TCLREADLINE_VERSION='@TCLREADLINE_VERSION@' -TCLREADLINE_MAJOR_VERSION='@TCLREADLINE_MAJOR_VERSION@' -TCLREADLINE_MINOR_VERSION='@TCLREADLINE_MINOR_VERSION@' +TCLREADLINE_VERSION='@VERSION@' +TCLREADLINE_MAJOR_VERSION='@MAJOR@' +TCLREADLINE_MINOR_VERSION='@MINOR@' # there's no leading dot here as in tclConfig.sh! -TCLREADLINE_PATCHLEVEL='@TCLREADLINE_PATCHLEVEL@' - -# The name of the tclreadline library -# (may be either a .a file or a shared library): -TCLREADLINE_LIB_FILE=@TCLREADLINE_LIB_FILE@ - -# String to pass to linker to pick up the tclreadline library from its -# build directory. -TCLREADLINE_BUILD_LIB_SPEC='@TCLREADLINE_BUILD_LIB_SPEC@' - -# String to pass to linker to pick up the tclreadline library from its -# installed directory. -TCLREADLINE_LIB_SPEC='@TCLREADLINE_LIB_SPEC@' - -# Location of the top-level source directories from which tclreadline -# was built. -TCLREADLINE_SRC_DIR='@srcdir@' +TCLREADLINE_PATCHLEVEL='@PATCHLEVEL@' + Index: tclreadlineInit.tcl.in ================================================================== --- tclreadlineInit.tcl.in +++ tclreadlineInit.tcl.in @@ -1,30 +1,26 @@ #!/usr/local/bin/tclsh # FILE: "/home/joze/src/tclreadline/tclreadlineInit.tcl.in" -# LAST MODIFICATION: "Sat, 25 Mar 2000 20:51:17 +0100 (joze)" +# LAST MODIFICATION: "Sat, 01 Jul 2000 23:54:15 +0200 (joze)" # (C) 1998 - 2000 by Johannes Zellner, # $Id$ # --- -# # tclreadline -- gnu readline for tcl # http://www.zellner.org/tclreadline/ # Copyright (c) 1998 - 2000, Johannes Zellner -# # This software is copyright under the BSD license. -# -# ================================================================== -package provide tclreadline @TCLREADLINE_VERSION@ +package provide tclreadline @VERSION@ namespace eval tclreadline:: { namespace export Init } proc ::tclreadline::Init {} { uplevel #0 { if ![info exists tclreadline::library] { - if [catch {load @TCLREADLINE_LIBRARY@/@TCLREADLINE_LIB_FILE@} msg] { + if [catch {load @TCLRL_DIR@/../libtclreadline[info sharedlibextension]} msg] { puts stderr $msg exit 2 } } } Index: tclreadlineSetup.tcl.in ================================================================== --- tclreadlineSetup.tcl.in +++ tclreadlineSetup.tcl.in @@ -1,22 +1,18 @@ #!/usr/locanl/bin/tclsh # FILE: "/home/joze/src/tclreadline/tclreadlineSetup.tcl.in" -# LAST MODIFICATION: "Sat, 25 Mar 2000 20:51:30 +0100 (joze)" +# LAST MODIFICATION: "Sat, 01 Jul 2000 21:53:28 +0200 (joze)" # (C) 1998 - 2000 by Johannes Zellner, # $Id$ # --- -# # tclreadline -- gnu readline for tcl # http://www.zellner.org/tclreadline/ # Copyright (c) 1998 - 2000, Johannes Zellner -# # This software is copyright under the BSD license. -# -# ================================================================== -package provide tclreadline @TCLREADLINE_VERSION@ +package provide tclreadline @VERSION@ proc unknown args { global auto_noexec auto_noload env unknown_pending tcl_interactive global errorCode errorInfo