The new experimental version of mk-defsystem is MK:DEFSYSTEM 4.x (MK4). It is completely CLOS based and backward compatible with 3.x.
The sourceforge link to mk-defsystem is https://sourceforge.net/projects/clocc/
The CVS modules in the CLOCC are
- defsystem-3.x and
Note that the latest version of MK3 already includes the code shown below.
Did you know? You can also load foreign files with defsystem. For example, to define that C components are compiled by calling out to "make" and loaded using the foreign loader, try something like this example (originally from db-sockets):
(defparameter *make-program* "make") (defun c-make-file (filename &rest args &key output-file error-file) ;; make foo.o (declare (ignore args error-file)) (make::run-unix-program *make-program* (list output-file))) (make:define-language :c :compiler #'c-make-file :loader #+:lucid #'load-foreign-files #+cmu #'alien::load-foreign #+sbcl #'sb-alien::load-foreign #+:allegro #'load #-(or :cmu :sbcl :lucid :allegro) #'load :source-extension "c" :binary-extension "o")
then you define the relevant component like this:
(:file "get_h_errno.c" :language :c :source-extension "c" :binary-extension "o")
Are there any documents for mk-defsystem out there? How does one add a path to its search path?
I have done a mild update to the defsystem.html that appears in
clocc/src/defsystem-3.3i/docs/. I have submitted the changes, but don't believe they have been incorporated. You can find the documents here. I'll try to add some of the material discussed on this page, as time permits.
Just to clarify: the CLOCC documentation is limited and needs to be updated. As per the specific question, both MK3 and MK4 now have a new function
(mk:add-registry-location <i>pathname</i>)which does the PUSH in a more meaningful way.
Henrik Motakef's Fight the System explains how to use and load libraries with mk-defsystem.
MK-DEFSYSTEM is now also asdf-installlable, though not yet from the official site (FWIW, this is version 3.3 and the latest version is 3.6):