forked from skypher/weblocks
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathweblocks-prevalence.asd
42 lines (35 loc) · 1.46 KB
/
weblocks-prevalence.asd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
;;;; -*- Mode: Lisp; Syntax: ANSI-Common-Lisp; Base: 10 -*-
(defpackage #:weblocks-prevalence-asd
(:use :cl :asdf))
(in-package :weblocks-prevalence-asd)
(defsystem weblocks-prevalence
:name "weblocks-prevalence"
:maintainer "Slava Akhmechet"
:author "Slava Akhmechet"
:licence "LLGPL"
:description "A weblocks backend for cl-prevalence."
:depends-on (:metatilities :cl-ppcre :cl-prevalence :bordeaux-threads)
:components ((:file "prevalence"))
:in-order-to ((compile-op (prepare-prevalence-op :weblocks-prevalence))
(load-op (prepare-prevalence-op :weblocks-prevalence))))
;;; This is necessary for specifying weblocks-memory as a dynamic dependency
(defclass prepare-prevalence-op (operation)
()
(:documentation "Used to run special code before prevalence system
is loaded."))
(defmethod perform ((o prepare-prevalence-op) (c (eql (find-system :weblocks-prevalence))))
(unless (find-package :weblocks-memory)
; load weblocks if necessary
(unless (find-package :weblocks)
(asdf:oos 'asdf:load-op :weblocks))
; load weblocks-memory.asd
(load (merge-pathnames
(make-pathname :directory '(:relative "src" "store" "memory")
:name "weblocks-memory" :type "asd")
(funcall (symbol-function (find-symbol (symbol-name '#:asdf-system-directory)
(find-package :weblocks)))
:weblocks)))
; load weblocks-memory
(asdf:oos 'asdf:load-op :weblocks-memory)))
(defmethod perform ((o prepare-prevalence-op) c)
nil)