Skip to content

Instantly share code, notes, and snippets.

@earl-ducaine
Created November 5, 2017 04:08
Show Gist options
  • Save earl-ducaine/a007da006b8d6db8b80223401b22f97f to your computer and use it in GitHub Desktop.
Save earl-ducaine/a007da006b8d6db8b80223401b22f97f to your computer and use it in GitHub Desktop.
Execute hook when entire system has been compiled
(asdf:defsystem :asdf-test
:around-compile
(lambda (compile-function)
(flet ((compile-success (&rest args)
(format t "args ~s~%" args)
t))
(apply compile-function (list :compile-check #'compile-success))))
:components
((:file "file1")
(:file "file2")))
;; To load "asdf-test":
;; Load 1 ASDF system:
;; asdf-test
;; ; Loading "asdf-test"
;; ; compiling file "/home/rett/dev/common-lisp/asdf-test/file1.lisp" (written 04 NOV 2017 09:04:15 PM):
;; ; /home/rett/.cache/common-lisp/sbcl-1.3.3.debian-linux-x64/home/rett/dev/common-lisp/asdf-test/file1-TMP.fasl written
;; ; compilation finished in 0:00:00.000
;; args (#P"/home/rett/dev/common-lisp/asdf-test/file1.lisp" :OUTPUT-FILE
;; #P"/home/rett/.cache/common-lisp/sbcl-1.3.3.debian-linux-x64/home/rett/dev/common-lisp/asdf-test/file1.fasl"
;; :EXTERNAL-FORMAT :UTF-8)
;; ; compiling file "/home/rett/dev/common-lisp/asdf-test/file2.lisp" (written 04 NOV 2017 09:05:01 PM):
;; ; /home/rett/.cache/common-lisp/sbcl-1.3.3.debian-linux-x64/home/rett/dev/common-lisp/asdf-test/file2-TMP.fasl written
;; ; compilation finished in 0:00:00.000
;; args (#P"/home/rett/dev/common-lisp/asdf-test/file2.lisp" :OUTPUT-FILE
;; #P"/home/rett/.cache/common-lisp/sbcl-1.3.3.debian-linux-x64/home/rett/dev/common-lisp/asdf-test/file2.fasl"
;; :EXTERNAL-FORMAT :UTF-8)
a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment