I should know this... finding INPUT-FILES
Faré
fahree at gmail.com
Fri Jan 24 21:53:43 UTC 2020
On Fri, Jan 24, 2020 at 4:30 PM Phoebe Goldman <phoebe at goldman-tribe.org> wrote:
>
Interesting to see a new member of the "goldman tribe" hacking on ASDF!
> The impetus for this question is, I have subclassed cl-source-file with org-source-file and have defined tangle-op (as a subclass of both sideway-operation and upward-operation). my perform method is:
>
> (defmethod perform ((op tangle-op) (file org-source-file))
> (let* ((input-file (first (input-files op file)))
> (output-file (first (output-files op file))))
> (tangle input-file output-file)))
>
> where (tangle input-file output-file) runs emacs in batch mode to produce a lisp source file.
>
Things should mostly "just work" thanks to selfward-operation causing
the propagation of input-files to output-files. All you should have to
do is declare the dependencies. You can't have the selfward-operation
slot of compile-op depend on the component being operated on, so
probably you should instead have prepare-op depend on tangle-op, and
ensure that the input-files of prepare-op are the output-files of
tangle-op.
I suggest you define and test your input-files and output-files
methods at the SLIME REPL before you try to run ASDF on your system.
> How can I define my input-files and output-files methods to make the lisp source files appear in some build directory maintained by ASDF, rather than in my source tree?
>
That should happen mostly automatically thanks to selfward-operation.
—♯ƒ • François-René ÐVB Rideau •Reflection&Cybernethics• http://fare.tunes.org
My knowledge is finite. My ignorance is infinite.
More information about the asdf-devel
mailing list