diary @ telent

Another laptop, another attempt at configuring outgoing email#

Tue Mar 29 20:20:57 2005

Topics:

Another laptop, another attempt at configuring outgoing email. That is, it's the same laptop as last week, but I'd been putting off this task.

Requirements:

Available: a shell host that I have ssh access to.

Solution: harness the awesome power of smtpmail.el

(require 'smtpmail)
(defun ssh-smtpmail-send-it ()
  (let* ((smtpmail-smtp-server "localhost")
	 (smtpmail-smtp-service 2525)
	 (smtp-local-domain "telent.net")
	 (smtp-sendto-domain "telent.net")
	 (sendmail (start-process "ssh-smtp" nil
				  "/usr/bin/ssh"
				  "-L" "2525:localhost:25"
				  "loaclhost.telent.net"
				  "cat"))
	 (ready-p nil))
    (labels ((filter (p s)
		     (if (string-match "tunnel is ready" s)
			 (setq ready-p t)
		       (message "Received from SSH connection: %s" s))))
      (unwind-protect
	  (progn
	    (set-process-filter sendmail 'filter)
	    (process-send-string sendmail "tunnel is ready\n")
	    (while (not ready-p)
	      (accept-process-output sendmail))
	    (message "")
	    (smtpmail-send-it))
	(process-send-eof sendmail) ; ask it nicely first
	(kill-process sendmail))))); if that does nothing, inhume it forcefully

(setq send-mail-function 'ssh-smtpmail-send-it)
(setq message-send-mail-function 'ssh-smtpmail-send-it)

Needs to be able to connect to the shell host (yes, really, it is called loaclhost) without a password, which is what ssh-agent was invented for. Needs no configuration changes on the shell host (nor even root access, though it happens that I have that anyway). How it works: (1) opens an ssh connection to the shell host and runs cat, additionally with a tunnel connecting port 2525 on my laptop to 25(smtp) on the shell machine; (2) prints something to the cat process and waits for it to come back - by this time the tunnel should also be ready for use; (3) calls smtpmail-send-it, (4) cleans up. This is, I feel, marginally less tacky than sleep n where n is chosen experimentally to be (a) greater than the connection/tunnel setup time, (b) less than would drive me mad while waiting.

Incoming mail, if you were wondering, is delivered to a maildir on loaclhost then synced with the notebook using maildirsync

In other laptop-related news: still can't get ACPI S3 suspend to work. swsuspend2 doesn't like my pcmcia wireless card (it's an Atmel thing). APM suspend does work, but running with no ACPI causes the fan to spin constantly which is annoying in a quiet environment and probably shortening battery life. But: I may be able to dispense with the PCMCIA wireless card as I have a mini-pci card arriving tomorrow from Solwise. It's not yet certain whether that will give me any better PM support, but it can use the laptop's builtin antenna so maybe it'll at least give me better reception. Will see. It would be nice also if I can get it to distinguish more of the pointer buttons from each other (four physical buttons but X only sees two) so that I can have a proper middle button again.

SBCL 0.8.21, as announced on cl.l#

Mon Apr 4 15:04:27 2005

Topics: lisp sbcl

SBCL 0.8.21, as announced on cl.l. last Friday. Emphasis added since:


The Steel Bank Common Lisp development team is proud to announce the
release of SBCL 0.8.21.  This release marks the beginning of a period
of stabilisation towards 0.9 and eventually 1.0, as well as the usual
crop of bug fixes (some of them quite long-standing, notably the PROG2
issue which has been with us seemingly forever)

SBCL is an Open Source compiler and runtime system for ANSI Common
Lisp. It provides an interactive environment including an integrated
native compiler, a debugger, and many extensions.


* Notable changes

** Now possible to set global optimization policy, startup package,
   readtable, etc, in startup files, as they're read with READ and
   EVAL instead of LOAD as before

** debugger changes
  - less mess in backtraces
  - removed redundant TOPLEVEL restart 
  - many kinds of functions have more legible printed representation
    and are more amenable INSPECT.
  - SIGSEGV in foreign code handled more gracefully on x86 and x86-64
  
** Improved SB-INTROSPECT for needs of SLIME

** thread support for non-NPTL systems has been removed - locking
   is buggy and unreliable.  A threaded SBCL build will now warn at
   startup and refuse to create new threads, unless futex support 
   is detected in the kernel

** Updates to the x86-64 backend

** Many bug fixes

  - PROG2 returns the primary value of its first argument, as per ANSI
  - (TYPEP X '(MEMBER ...)) no longer returns a list in compiled code
  - LOAD binds *LOAD-PATHNAME* to the merged pathname
  - more bugs revealed by Paul Dietz' test suite: check the NEWS file
    for details

* For more information and downloads

   http://www.sbcl.org/platform-table.html

The sources will compile under almost any sufficiently-ANSI CL, or you
can wait for binaries which are currently being uploaded for various
platforms.

A total of one person spotted this and thought it unusual enough to ask about. Next year our April Fool will be less subtle, I promise.

Some brief feedback on my weekend in Amsterdam#

Tue Apr 26 10:56:24 2005

Topics: lisp sbcl

Some brief feedback on my weekend in Amsterdam.

In summary, then: