Commit d8dc44b4 authored by Eric Timmons's avatar Eric Timmons
Browse files

Source cleanup: move src/clpm-build/ to features/

parent 6ef08acb
(:source-registry-cache
"clpm-build.asd"
"clpm-cli.asd"
"clpm-features.asd"
"clpm-licenses.asd"
"clpm.asd"
"ext/adopt/adopt.asd"
......
......@@ -59,7 +59,7 @@ install the dependencies:
CLPM can be customized by placing a file named
=customize-target-features.lisp-expr= in the root of the repo with a single
=lambda= form in it that takes a list of features and returns a modified
feature list. See [[file:src/clpm-build/features.lisp]] for a brief description
feature list. See [[file:features/clpm-features.lisp]] for a brief description
of the available features.
For example, to disable Dexador support, use the following form:
......
......@@ -19,6 +19,7 @@
(deploy:define-resource-directory deploy-src "src/")
(deploy:define-resource-directory deploy-cli "cli/")
(deploy:define-resource-directory deploy-features "features/")
;; Don't deploy the WinHttp dll
#+clpm-winhttp
......@@ -47,7 +48,8 @@
(when (uiop:featurep :clpm-logical-pathnames)
(setf (logical-pathname-translations "clpm")
`(("clpm:src;**;*.*.*" ,(merge-pathnames "src/**/*.*" deploy:*data-location*))
("clpm:cli;**;*.*.*" ,(merge-pathnames "cli/**/*.*" deploy:*data-location*)))))
("clpm:cli;**;*.*.*" ,(merge-pathnames "cli/**/*.*" deploy:*data-location*))
("clpm:features;**;*.*.*" ,(merge-pathnames "features/**/*.*" deploy:*data-location*)))))
(setf *clpm-client-asd-pathname* (merge-pathnames "src/clpm-client/clpm-client.asd"
deploy:*data-location*))
(unless (uiop:probe-file* clpm-home)
......
......@@ -14,7 +14,7 @@
:license "BSD-2-Clause"
:pathname #+clpm-logical-pathnames #p"clpm:cli;" #-clpm-logical-pathnames "cli/"
:class :package-inferred-system
:defsystem-depends-on (#:deploy)
:defsystem-depends-on (#:clpm-features #:deploy)
:entry-point "clpm-cli/entry:main"
:build-operation "deploy-op"
:build-pathname "clpm"
......
;;;; CLPM-Build System Definition
;;;; CLPM-Features System Definition
;;;;
;;;; This software is part of CLPM. See README.org for more information. See
;;;; LICENSE for license information.
......@@ -6,13 +6,12 @@
#-:asdf3.2
(error "Requires ASDF >=3.2")
;; Not necessary, but easier to have when using SLIME.
(in-package :asdf-user)
(defsystem #:clpm-build
(defsystem #:clpm-features
:version (:read-file-form "src/clpm/version.lisp" :at (2 2))
:description "A Common Lisp Package Manager"
:description "Configuring *FEATURES* for CLPM"
:license "BSD-2-Clause"
:pathname #+clpm-logical-pathnames #p"clpm:src;clpm-build;" #-clpm-logical-pathnames "src/clpm-build/"
:pathname #+clpm-logical-pathnames #p"clpm:features;" #-clpm-logical-pathnames "features/"
:class :package-inferred-system
:depends-on (#:clpm-build/clpm-build))
:depends-on (#:clpm-features/clpm-features))
......@@ -4,7 +4,7 @@
:description "System containing the licenses for CLPM and its dependencies."
:license "BSD-2-Clause"
:serial t
:depends-on (#:clpm-build)
:depends-on (#:clpm-features)
:components ((:module "licenses"
:components ((:static-file "adopt")
(:static-file "alexandria")
......
......@@ -15,7 +15,7 @@
:license "BSD-2-Clause"
:pathname #+clpm-logical-pathnames #p"clpm:src;clpm;" #-clpm-logical-pathnames "src/clpm/"
:class :package-inferred-system
:defsystem-depends-on (#:clpm-build)
:defsystem-depends-on (#:clpm-features)
:depends-on (#:clpm/clpm
(:feature :clpm-curl #:clpm-multi-http-client-impl/curl)
(:feature :clpm-dexador #:clpm-multi-http-client-impl/dexador)
......
......@@ -3,11 +3,12 @@
;;;; This software is part of CLPM. See README.org for more information. See
;;;; LICENSE for license information.
(uiop:define-package #:clpm-build/features
(:use #:cl)
(uiop:define-package #:clpm-features/clpm-features
(:nicknames #:clpm-features)
(:use #:cl)
(:import-from #:trivial-features))
(in-package #:clpm-build/features)
(in-package #:clpm-features)
(defparameter *clpm-feature-documentation*
`((:clpm . "Required feature. Denotes that CLPM is present.")
......@@ -93,7 +94,7 @@
(defun load-features-from-file ()
(let ((pn (merge-pathnames (make-pathname :name "customize-target-features"
:type "lisp-expr")
(asdf:system-source-file "clpm-build")))
(asdf:system-source-file "clpm-features")))
(clpm-features (default-features)))
(when (probe-file pn)
(let* ((form (uiop:read-file-form pn))
......
......@@ -6,6 +6,7 @@
(let ((clpm-root (uiop:pathname-directory-pathname (uiop:ensure-absolute-pathname *load-pathname*))))
(setf (logical-pathname-translations "clpm")
`(("clpm:src;**;*.*.*" ,(merge-pathnames "src/**/*.*" clpm-root))
("clpm:cli;**;*.*.*" ,(merge-pathnames "cli/**/*.*" clpm-root)))))
("clpm:cli;**;*.*.*" ,(merge-pathnames "cli/**/*.*" clpm-root))
("clpm:features;**;*.*.*" ,(merge-pathnames "features/**/*.*" clpm-root)))))
(pushnew :clpm-logical-pathnames *features*)
;;;; CLPM Build helpers
;;;;
;;;; This software is part of CLPM. See README.org for more information. See
;;;; LICENSE for license information.
(uiop:define-package #:clpm-build/clpm-build
(:nicknames #:clpm-build)
(:use #:cl
#:clpm-build/features))
(in-package #:clpm-build/clpm-build)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment