--- /dev/null
+Requirements:
+
+ * GNU Readline (libreadline.so.4)
+ * UFFI
+
+Run make, and you are set. At least almost.
--- /dev/null
+;; Copyright (c) 2003 Nikodemus Siivola
+;;
+;; Permission is hereby granted, free of charge, to any person obtaining
+;; a copy of this software and associated documentation files (the
+;; "Software"), to deal in the Software without restriction, including
+;; without limitation the rights to use, copy, modify, merge, publish,
+;; distribute, sublicense, and/or sell copies of the Software, and to
+;; permit persons to whom the Software is furnished to do so, subject to
+;; the following conditions:
+;;
+;; The above copyright notice and this permission notice shall be included
+;; in all copies or substantial portions of the Software.
+;;
+;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+;; IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+;; CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
--- /dev/null
+VERSION=0.1
+NAME=cl-readline-$(VERSION)
+
+all: libreadline-cl.o
+
+all:
+ gcc -fPIC -DPIC -c libreadline-cl.c -o libreadline-cl.o
+ gcc -shared libreadline-cl.o -lreadline4 -o libreadline-cl.so
+
+
--- /dev/null
+CL-READLINE 0.1
+
+ CL-READLINE is a simple UFFI-based wrapper for the GNU Readline
+ library.
+
+ CL-READLINE has been tested on Debian GNU/Linux under SBCl, SBCL-MT
+ and CMUCL. Other platforms and UFFI compatible implementations should
+ work, but may require tweaking.
+
+ To use:
+
+ (asdf:oos 'asdf:load-op 'readline)
+ (rl:readline :prompt "> ")
+
--- /dev/null
+- Keybindings
+
+- Maintain several concurrent completion lists,
+ with easy switch back and forth.
+
+- Keybinding to switch between completion lists.
+
+- File-based completion list.
+
+- Better history control
+
+- 8bit fix
+
+- REPL
+
+- Paren-matching settable despite .inputrc
+
+- Hidden characters. (Password-style)
+
+- Lightweight version based on alternate library with
+ more permissive license.
+
+- Samrter installation
--- /dev/null
+cl-kmrcl (1.22-1) unstable; urgency=low
+
+ * Improve xml-utils when an expected tag is not found.
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 3 Dec 2002 02:32:37 -0700
+
+cl-kmrcl (1.21-1) unstable; urgency=low
+
+ * Remore allegroserve dependant modules
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 24 Nov 2002 13:13:05 -0700
+
+cl-kmrcl (1.20.2-1) unstable; urgency=low
+
+ * Remove 'load-compiled-op from .asd file
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Fri, 8 Nov 2002 09:41:22 -0700
+
+cl-kmrcl (1.20.1-1) unstable; urgency=low
+
+ * Add with-each-file-line & with-each-stream-line to export list, fix
+ bugs in those functions
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Wed, 7 Nov 2002 14:52:39 -0700
+
+cl-kmrcl (1.20-1) unstable; urgency=low
+
+ * Add with-each-stream-line, with-each-file-line
+ * Use gensyms in other functions to avoid variable capture
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Wed, 6 Nov 2002 13:33:39 -0700
+
+cl-kmrcl (1.19.1-1) unstable; urgency=low
+
+ * Made indent-spaces reslient to non-numeric parameter
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 4 Nov 2002 11:33:03 -0700
+
+cl-kmrcl (1.19-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 3 Nov 2002 13:08:44 -0700
+
+cl-kmrcl (1.18-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 21 Oct 2002 11:51:17 -0600
+
+cl-kmrcl (1.17-1) unstable; urgency=low
+
+ * Fix buggy kmrcl.asd file
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 21 Oct 2002 11:51:17 -0600
+
+cl-kmrcl (1.16-1) unstable; urgency=low
+
+ * Rework handling of aserve requirement
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 20 Oct 2002 20:37:01 -0600
+
+cl-kmrcl (1.15-1) unstable; urgency=low
+
+ * Add depends: for common-lisp-controller and cl-aserve
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 19 Oct 2002 19:59:02 -0600
+
+cl-kmrcl (1.14-1) unstable; urgency=low
+
+ * ml-class.lisp: Add XHTML format
+ * web-utils.lisp: Add standard headers for xml, html, xhtml,
+ added user-agent-ie-p
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Thu, 17 Oct 2002 16:25:31 -0600
+
+cl-kmrcl (1.13-1) unstable; urgency=low
+
+ * ml-class.lisp: Add ie-xmlrefformat for Internet Explorer's idea of
+ a link in XML. Add SCL compatibility.
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 15 Oct 2002 23:23:57 -0600
+
+cl-kmrcl (1.12-1) unstable; urgency=low
+
+ * Fix .asd file if CL-ASERVE is not installed
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 15 Oct 2002 16:46:47 -0600
+
+cl-kmrcl (1.11-1) unstable; urgency=low
+
+ * Change .asd file for ASERVE require
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 15 Oct 2002 16:38:28 -0600
+
+cl-kmrcl (1.10-1) unstable; urgency=low
+
+ * ml-class.lisp: Fix package name
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 14 Oct 2002 14:48:43 -0600
+
+cl-kmrcl (1.9-1) unstable; urgency=low
+
+ * ml-class.lisp: Get package name from object
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 14 Oct 2002 13:23:23 -0600
+
+cl-kmrcl (1.8-1) unstable; urgency=low
+
+ * ml-class.lisp: Add defgeneric for generic functions
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 14 Oct 2002 09:11:08 -0600
+
+cl-kmrcl (1.7-1) unstable; urgency=low
+
+ * Push :kmrcl onto features
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 13 Oct 2002 20:47:45 -0600
+
+cl-kmrcl (1.6-1) unstable; urgency=low
+
+ * ml-class.lisp: Fix CMUCL compatibility, add SBCL compatibility
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 13 Oct 2002 11:04:04 -0600
+
+cl-kmrcl (1.5-1) unstable; urgency=low
+
+ * ml-class.lisp: Change pcl package to sb-pcl for sbcl
+ * kmrcl.asd: remove sbcl from reader conditional for ml-class
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 13 Oct 2002 10:16:14 -0600
+
+cl-kmrcl (1.4-1) unstable; urgency=low
+
+ * Add pcl:validate-superclass for CMUCL/SBCL compatibility
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 13 Oct 2002 10:09:39 -0600
+
+cl-kmrcl (1.3) unstable; urgency=low
+
+ * Change .asd to fix problem with ml-class
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 12 Oct 2002 13:03:49 -0600
+
+cl-kmrcl (1.2-1) unstable; urgency=low
+
+ * Seperate string and equal functions into their own files
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 12 Oct 2002 00:03:18 -0600
+
+cl-kmrcl (1.1-1) unstable; urgency=low
+
+ * Re-arrange defclass order in ml-classes.lisp for cmucl compatibility
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Fri, 11 Oct 2002 20:00:29 -0600
+
+cl-kmrcl (1.0-1) unstable; urgency=low
+
+ * Initial Release (closes: 163955)
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 5 Oct 2002 13:19:33 -0600
+
--- /dev/null
+cl-kmrcl (1.38-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 4 May 2003 08:43:14 -0600
+
+cl-kmrcl (1.37-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Fri, 2 May 2003 16:30:15 -0600
+
+cl-kmrcl (1.36-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Fri, 2 May 2003 01:28:00 -0600
+
+cl-kmrcl (1.35-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 29 Apr 2003 21:18:40 -0600
+
+cl-kmrcl (1.34-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 29 Apr 2003 20:14:55 -0600
+
+cl-kmrcl (1.33-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 29 Apr 2003 09:24:35 -0600
+
+cl-kmrcl (1.32-1) unstable; urgency=low
+
+ * Vary signature of DIRECT-SLOT-DEFINITION-CLASS depending on
+ implementation
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 28 Apr 2003 19:35:37 -0600
+
+cl-kmrcl (1.31-1) unstable; urgency=low
+
+ * New upstream
+ * Add kmr-mop package
+ * Add tests suite, add cl-rt to depends
+ * Use compat file rather than DH_COMPAT variable
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 28 Apr 2003 14:32:16 -0600
+
+cl-kmrcl (1.30-1) unstable; urgency=low
+
+ * Really fix typo
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Wed, 26 Mar 2003 14:11:09 -0700
+
+cl-kmrcl (1.29-1) unstable; urgency=low
+
+ * Fix typo in new sb-mop support
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 25 Mar 2003 06:42:15 -0700
+
+cl-kmrcl (1.28-1) unstable; urgency=low
+
+ * Fix sbcl for versions without sb-mop package
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 24 Mar 2003 22:19:49 -0700
+
+cl-kmrcl (1.27-1) unstable; urgency=low
+
+ * New upstream for sbcl 0.8pre MOP changes
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 24 Mar 2003 21:12:17 -0700
+
+cl-kmrcl (1.26-1) unstable; urgency=low
+
+ * Add nsubseq
+ * Rework list-to-delimited-sequence
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Fri, 7 Feb 2003 07:19:14 -0700
+
+cl-kmrcl (1.25-1) unstable; urgency=low
+
+ * strings.lisp: add new functions
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 13 Jan 2003 14:40:37 -0700
+
+cl-kmrcl (1.24-1) unstable; urgency=low
+
+ * strings.lisp: fix typo error
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 28 Dec 2002 00:58:18 -0700
+
+cl-kmrcl (1.23-1) unstable; urgency=low
+
+ * New upstream, add string functions
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Thu, 26 Dec 2002 04:46:15 -0700
+
+cl-kmrcl (1.22-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 2 Dec 2002 17:54:02 -0700
+
+cl-kmrcl (1.21-1) unstable; urgency=low
+
+ * Remore allegroserve dependant modules
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 24 Nov 2002 13:13:05 -0700
+
+cl-kmrcl (1.20.2-1) unstable; urgency=low
+
+ * Remove 'load-compiled-op from .asd file
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Fri, 8 Nov 2002 09:41:22 -0700
+
+cl-kmrcl (1.20.1-1) unstable; urgency=low
+
+ * Add with-each-file-line & with-each-stream-line to export list, fix
+ bugs in those functions
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Wed, 7 Nov 2002 14:52:39 -0700
+
+cl-kmrcl (1.20-1) unstable; urgency=low
+
+ * Add with-each-stream-line, with-each-file-line
+ * Use gensyms in other functions to avoid variable capture
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Wed, 6 Nov 2002 13:33:39 -0700
+
+cl-kmrcl (1.19.1-1) unstable; urgency=low
+
+ * Made indent-spaces reslient to non-numeric parameter
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 4 Nov 2002 11:33:03 -0700
+
+cl-kmrcl (1.19-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 3 Nov 2002 13:08:44 -0700
+
+cl-kmrcl (1.18-1) unstable; urgency=low
+
+ * New upstream
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 21 Oct 2002 11:51:17 -0600
+
+cl-kmrcl (1.17-1) unstable; urgency=low
+
+ * Fix buggy kmrcl.asd file
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 21 Oct 2002 11:51:17 -0600
+
+cl-kmrcl (1.16-1) unstable; urgency=low
+
+ * Rework handling of aserve requirement
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 20 Oct 2002 20:37:01 -0600
+
+cl-kmrcl (1.15-1) unstable; urgency=low
+
+ * Add depends: for common-lisp-controller and cl-aserve
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 19 Oct 2002 19:59:02 -0600
+
+cl-kmrcl (1.14-1) unstable; urgency=low
+
+ * ml-class.lisp: Add XHTML format
+ * web-utils.lisp: Add standard headers for xml, html, xhtml,
+ added user-agent-ie-p
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Thu, 17 Oct 2002 16:25:31 -0600
+
+cl-kmrcl (1.13-1) unstable; urgency=low
+
+ * ml-class.lisp: Add ie-xmlrefformat for Internet Explorer's idea of
+ a link in XML. Add SCL compatibility.
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 15 Oct 2002 23:23:57 -0600
+
+cl-kmrcl (1.12-1) unstable; urgency=low
+
+ * Fix .asd file if CL-ASERVE is not installed
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 15 Oct 2002 16:46:47 -0600
+
+cl-kmrcl (1.11-1) unstable; urgency=low
+
+ * Change .asd file for ASERVE require
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Tue, 15 Oct 2002 16:38:28 -0600
+
+cl-kmrcl (1.10-1) unstable; urgency=low
+
+ * ml-class.lisp: Fix package name
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 14 Oct 2002 14:48:43 -0600
+
+cl-kmrcl (1.9-1) unstable; urgency=low
+
+ * ml-class.lisp: Get package name from object
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 14 Oct 2002 13:23:23 -0600
+
+cl-kmrcl (1.8-1) unstable; urgency=low
+
+ * ml-class.lisp: Add defgeneric for generic functions
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Mon, 14 Oct 2002 09:11:08 -0600
+
+cl-kmrcl (1.7-1) unstable; urgency=low
+
+ * Push :kmrcl onto features
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 13 Oct 2002 20:47:45 -0600
+
+cl-kmrcl (1.6-1) unstable; urgency=low
+
+ * ml-class.lisp: Fix CMUCL compatibility, add SBCL compatibility
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 13 Oct 2002 11:04:04 -0600
+
+cl-kmrcl (1.5-1) unstable; urgency=low
+
+ * ml-class.lisp: Change pcl package to sb-pcl for sbcl
+ * kmrcl.asd: remove sbcl from reader conditional for ml-class
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 13 Oct 2002 10:16:14 -0600
+
+cl-kmrcl (1.4-1) unstable; urgency=low
+
+ * Add pcl:validate-superclass for CMUCL/SBCL compatibility
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sun, 13 Oct 2002 10:09:39 -0600
+
+cl-kmrcl (1.3) unstable; urgency=low
+
+ * Change .asd to fix problem with ml-class
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 12 Oct 2002 13:03:49 -0600
+
+cl-kmrcl (1.2-1) unstable; urgency=low
+
+ * Seperate string and equal functions into their own files
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 12 Oct 2002 00:03:18 -0600
+
+cl-kmrcl (1.1-1) unstable; urgency=low
+
+ * Re-arrange defclass order in ml-classes.lisp for cmucl compatibility
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Fri, 11 Oct 2002 20:00:29 -0600
+
+cl-kmrcl (1.0-1) unstable; urgency=low
+
+ * Initial Release (closes: 163955)
+
+ -- Kevin M. Rosenberg <kmr@debian.org> Sat, 5 Oct 2002 13:19:33 -0600
+
--- /dev/null
+Source: cl-readline
+Section: devel
+Priority: optional
+Maintainer: Kevin M. Rosenberg <kmr@debian.org>
+Build-Depends: debhelper (>= 4.0.0), libreadline4-dev
+Standards-Version: 3.5.9.0
+
+Package: cl-readline
+Architecture: any
+Depends: ${shlibs:Depends}, common-lisp-controller, cl-uffi, libreadline4
+Description: Common Lisp interface to the GNU readline library
+ This package uses UFFI to provide an interface to the GNU readline
+ library for Common Lisp programs.
+
+
--- /dev/null
+This package was debianized by Kevin M. Rosenberg <kmr@debian.org> in
+May 2003.
+
+It was downloaded from http://www.cliki.org/cl-readline
+
+Upstream Author: Nikodemus Siivola
+
+
+;; Copyright (c) 2003 Nikodemus Siivola
+;;
+;; Permission is hereby granted, free of charge, to any person obtaining
+;; a copy of this software and associated documentation files (the
+;; "Software"), to deal in the Software without restriction, including
+;; without limitation the rights to use, copy, modify, merge, publish,
+;; distribute, sublicense, and/or sell copies of the Software, and to
+;; permit persons to whom the Software is furnished to do so, subject to
+;; the following conditions:
+;;
+;; The above copyright notice and this permission notice shall be included
+;; in all copies or substantial portions of the Software.
+;;
+;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+;; IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+;; CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
--- /dev/null
+README
+TODO
--- /dev/null
+#! /bin/sh
+
+
+set -e
+
+# package name according to lisp
+LISP_PKG=cl-readline
+
+# summary of how this script can be called:
+# * <postinst> `configure' <most-recently-configured-version>
+# * <old-postinst> `abort-upgrade' <new version>
+# * <conflictor's-postinst> `abort-remove' `in-favour' <package>
+# <new-version>
+# * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
+# <failed-install-package> <version> `removing'
+# <conflicting-package> <version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+#
+# quoting from the policy:
+# Any necessary prompting should almost always be confined to the
+# post-installation script, and should be protected with a conditional
+# so that unnecessary prompting doesn't happen if a package's
+# installation fails and the `postinst' is called with `abort-upgrade',
+# `abort-remove' or `abort-deconfigure'.
+
+case "$1" in
+ configure)
+ /usr/sbin/register-common-lisp-source ${LISP_PKG}
+ ;;
+ abort-upgrade|abort-remove|abort-deconfigure)
+ ;;
+ *)
+ echo "postinst called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
--- /dev/null
+#! /bin/sh
+
+
+set -e
+
+# package name according to lisp
+LISP_PKG=cl-readline
+
+# summary of how this script can be called:
+# * <prerm> `remove'
+# * <old-prerm> `upgrade' <new-version>
+# * <new-prerm> `failed-upgrade' <old-version>
+# * <conflictor's-prerm> `remove' `in-favour' <package> <new-version>
+# * <deconfigured's-prerm> `deconfigure' `in-favour'
+# <package-being-installed> <version> `removing'
+# <conflicting-package> <version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+
+case "$1" in
+ remove|upgrade|deconfigure)
+ /usr/sbin/unregister-common-lisp-source ${LISP_PKG}
+ ;;
+ failed-upgrade)
+ ;;
+ *)
+ echo "prerm called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
+
+
--- /dev/null
+#!/usr/bin/make -f
+
+pkg := readline
+debpkg := cl-$(pkg)
+
+clc-source := usr/share/common-lisp/source
+clc-systems := usr/share/common-lisp/systems
+clc-files := $(clc-source)/$(pkg)
+doc-dir := usr/share/doc/$(debpkg)
+lib-dir := usr/lib/cl-readline
+
+source-files := $(wildcard *.lisp)
+
+configure: configure-stamp
+configure-stamp:
+ dh_testdir
+ # Add here commands to configure the package.
+ touch configure-stamp
+
+
+build: build-stamp
+
+build-stamp: configure-stamp
+ dh_testdir
+ # Add here commands to compile the package.
+ $(MAKE)
+ touch build-stamp
+
+clean:
+ dh_testdir
+ dh_testroot
+ rm -f build-stamp configure-stamp
+ # Add here commands to clean up after the build process.
+ rm -f debian/$(debpkg).postinst.* debian/$(debpkg).prerm.*
+ dh_clean
+
+install: build
+ dh_testdir
+ dh_testroot
+ dh_clean -k
+ # Add here commands to install the package into debian/kmrcl.
+ dh_installdirs $(clc-systems) $(clc-files) $(clc-tests)
+ dh_install $(pkg).asd $(source-files) $(clc-files)
+ dh_link $(clc-files)/$(pkg).asd $(clc-systems)/$(pkg).asd
+ dh_install "libreadline-cl.so" $(lib-dir)
+
+# Build architecture-independent files here.
+binary-indep: build install
+
+
+# Build architecture-dependent files here.
+binary-arch: build install
+ dh_testdir
+ dh_testroot
+# dh_installdebconf
+ dh_installdocs
+# dh_installmenu
+# dh_installlogrotate
+# dh_installemacsen
+# dh_installpam
+# dh_installmime
+# dh_installinit
+# dh_installcron
+# dh_installman
+# dh_installinfo
+# dh_undocumented
+ dh_installchangelogs
+ dh_strip
+ dh_compress
+ dh_fixperms
+# dh_makeshlibs
+ dh_installdeb
+# dh_perl
+ dh_shlibdeps
+ dh_gencontrol
+ dh_md5sums
+ dh_builddeb
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install configure
+
--- /dev/null
+/*
+ * Copyright (c) 2003 Nikodemus Siivola
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sublicense, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+ * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+#include <string.h>
+#include <stdlib.h>
+#include <readline/readline.h>
+
+typedef struct {
+ char * str;
+ void * next;
+}
+node_t;
+
+node_t * collection = NULL;
+
+int
+add_completion (char * str)
+{
+ node_t * tmp = collection;
+ node_t * pre = NULL;
+ node_t * node;
+ while (tmp)
+ {
+ int cmp = strcmp (str, tmp->str);
+ if (0 == cmp)
+ return 1;
+
+ if (0 < cmp)
+ break;
+
+ /* printf ("-skip- (%s)\n", tmp->str);*/
+
+ pre = tmp;
+ tmp = tmp->next;
+ }
+
+ node = malloc (sizeof (node_t));
+ if (!node)
+ return 0;
+
+ node->next = tmp;
+ node->str = strdup (str);
+
+ if (! pre)
+ collection = node;
+ else
+ pre->next = node;
+
+ return 1;
+}
+
+node_t * root = NULL;
+
+char *
+custom_completer (const char * str, int target)
+{
+ size_t len = strlen (str);
+ if (0 == target)
+ {
+ root = NULL;
+ node_t * tmp = collection;
+ while (len && tmp)
+ {
+ if (0 == strncmp (str, tmp->str, len))
+ {
+ root = tmp;
+ return strdup (root->str);
+ }
+ else
+ tmp = tmp->next;
+ }
+ return (char *)NULL;
+ }
+ else if (root && (0 == strncmp (str, root->str, len)))
+ {
+ node_t * tmp = root;
+ root = root->next;
+ return strdup (tmp->str);
+ }
+ else
+ return (char *)NULL;
+}
+
+void
+clear_completions ()
+{
+ node_t * tmp;
+ while (collection)
+ {
+ /* printf ("-del- (%s)\n", collection->str); */
+ tmp = collection->next;
+ free (collection->str);
+ free (collection);
+ collection = tmp;
+ }
+}
+
+void
+use_custom_complete (void)
+{
+ rl_completion_entry_function = custom_completer;
+}
+
+void
+use_filename_complete (void)
+{
+ rl_completion_entry_function = rl_filename_completion_function;
+}
--- /dev/null
+;; Copyright (c) 2003 Nikodemus Siivola
+;;
+;; Permission is hereby granted, free of charge, to any person obtaining
+;; a copy of this software and associated documentation files (the
+;; "Software"), to deal in the Software without restriction, including
+;; without limitation the rights to use, copy, modify, merge, publish,
+;; distribute, sublicense, and/or sell copies of the Software, and to
+;; permit persons to whom the Software is furnished to do so, subject to
+;; the following conditions:
+;;
+;; The above copyright notice and this permission notice shall be included
+;; in all copies or substantial portions of the Software.
+;;
+;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+;; IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+;; CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+(in-package libreadline)
+
+(def-function "readline" ((prompt :cstring))
+ :module "readline"
+ :returning :cstring)
+
+(def-function "add_history" ((str :cstring))
+ :module "readline"
+ :returning :void)
+
+(def-function "add_completion" ((str :cstring))
+ :module "readline-cl"
+ :returning :int)
+
+(def-function "clear_completions" ()
+ :module "readline-cl"
+ :returning :void)
+
+(def-function "use_custom_complete" ()
+ :module "readline-cl"
+ :returning :void)
+
+(def-function "use_filename_complete" ()
+ :module "readline-cl"
+ :returning :void)
--- /dev/null
+;; Copyright (c) 2003 Nikodemus Siivola
+;;
+;; Permission is hereby granted, free of charge, to any person obtaining
+;; a copy of this software and associated documentation files (the
+;; "Software"), to deal in the Software without restriction, including
+;; without limitation the rights to use, copy, modify, merge, publish,
+;; distribute, sublicense, and/or sell copies of the Software, and to
+;; permit persons to whom the Software is furnished to do so, subject to
+;; the following conditions:
+;;
+;; The above copyright notice and this permission notice shall be included
+;; in all copies or substantial portions of the Software.
+;;
+;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+;; IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+;; CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+(defpackage libreadline
+ (:use cl uffi))
+
+(defpackage readline
+ (:nicknames rl)
+ (:use cl uffi)
+ (:export
+ add-completion
+ add-history
+ clear-completions
+ readline
+ use-cl-complete
+ use-custom-complete
+ use-filename-complete
+ ))
+
+(uffi:load-foreign-library "/usr/lib/cl-readline/libreadline-cl.so"
+ :module "readline-cl")
+
--- /dev/null
+;; -*- Lisp -*-
+;; Copyright (c) 2003 Nikodemus Siivola
+;;
+;; Permission is hereby granted, free of charge, to any person obtaining
+;; a copy of this software and associated documentation files (the
+;; "Software"), to deal in the Software without restriction, including
+;; without limitation the rights to use, copy, modify, merge, publish,
+;; distribute, sublicense, and/or sell copies of the Software, and to
+;; permit persons to whom the Software is furnished to do so, subject to
+;; the following conditions:
+;;
+;; The above copyright notice and this permission notice shall be included
+;; in all copies or substantial portions of the Software.
+;;
+;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+;; IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+;; CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+(asdf:defsystem readline
+ :depends-on (:uffi)
+ :components ((:file "packages")
+ (:file "libreadline" :depends-on ("packages"))
+ (:file "readline" :depends-on ("packages" "libreadline"))))
+
+
--- /dev/null
+;; Copyright (c) 2003 Nikodemus Siivola
+;;
+;; Permission is hereby granted, free of charge, to any person obtaining
+;; a copy of this software and associated documentation files (the
+;; "Software"), to deal in the Software without restriction, including
+;; without limitation the rights to use, copy, modify, merge, publish,
+;; distribute, sublicense, and/or sell copies of the Software, and to
+;; permit persons to whom the Software is furnished to do so, subject to
+;; the following conditions:
+;;
+;; The above copyright notice and this permission notice shall be included
+;; in all copies or substantial portions of the Software.
+;;
+;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+;; IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+;; CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+(in-package readline)
+
+(defvar *whitespace* (list #\Space #\Tab))
+
+(let (cl-complete)
+
+ (defun add-completion (string)
+ "Add STRING as a custom-completion."
+ (setq cl-complete nil)
+ (with-cstring (c-str string)
+ (= 1 (libreadline::add-completion c-str))))
+
+ (defun clear-completions ()
+ "Clear all custom-completions."
+ (setq cl-complete nil)
+ (libreadline::clear-completions))
+
+ (defun use-custom-complete ()
+ "Use custom-competions."
+ (libreadline::use-custom-complete)
+ nil)
+
+ (defun use-filename-complete ()
+ "Use default completion system. (filename)"
+ (libreadline::use-filename-complete)
+ nil)
+
+ (defun use-cl-complete ()
+ "Load symbols in package CL-USER as custom-completions."
+ (unless cl-complete
+ (setq cl-complete t)
+ (clear-completions)
+ (do-symbols (sym (find-package :cl-user))
+ (add-completion (string-downcase (string sym)))))
+ (use-custom-complete)
+ nil)
+
+ (defun add-history (string)
+ "Add STRING to history."
+ (with-cstring (c-string string)
+ (libreadline::add-history c-string))
+ string)
+
+ (defun readline (&key (prompt "") (history t))
+ "Read a line from current TTY with line-editing."
+ (with-cstring (c-prompt prompt)
+ (let ((str (string-trim
+ *whitespace*
+ (convert-from-cstring (libreadline::readline c-prompt)))))
+ (when (and history (not (string= "" str)))
+ (add-history str))))))