High-level wrapper around libxml2 and libxslt libraries

Dowload and Installation

Implementation-specific notes

cl-libxml2 is known to work with SBCL and CLISP on Gentoo Linux using gentoo-lisp-overlay.



Download tarballs or get it from git: :

$ git clone git://

Build C helper library

libxslt requires functions with variable arguments list for error handling callbacks (see xsltSetGenericErrorFunc). CFFI does not support such functions, and, thus, C helper library is required for libxslt errors translation into lisp conditions. The helper library resides in the directory foreign. :

$ cd /path/to/cl-libxml2
$ make -C foreign
$ make -C foreign install

Compilation and loading

Register the .asd file, e.g. by symlinking it: :

$ ln -sf `pwd`/cl-libxml2/cl-libxml2.asd /path/to/your/registry/
$ ln -sf `pwd`/cl-libxml2/cl-libxslt.asd /path/to/your/registry/
$ ln -sf `pwd`/cl-libxml2/xfactory.asd /path/to/your/registry/

To compile cl-libxlm2 with XSLT support use:

(asdf:operate 'asdf:load-op :cl-libxslt)

Or without XSLT:

(asdf:operate 'asdf:load-op :cl-libxml2)

To compile XFactory system:

(asdf:operate 'asdf:load-op :xfactory)

Run test suite (optional)

Compile cl-libxlm2 with XSLT support as described above.

Test suite can be launched by asdf's test-op operator. If cl-libxml2 has not been yet loaded with asdf:load-op, asdf:test-op will do it automatically.

Run tests with XSLT:

(asdf:operate 'asdf:test-op :cl-libxslt)

Without XSLT:

(asdf:operate 'asdf:test-op :cl-libxml2)

And for XFactory system:

(asdf:operate 'asdf:test-op :xfactory)

@2009-2010 Moskvitin Andrey