<div dir="ltr">Aah didn't think that cli also was a module. I kinda figured that the I needed to compile my module directly into like the other modules until you support it :) So other than the source files in the cli folder, which files would I have to change / read in the main project? b.[c|h]xx others ?<div><br></div><div>Thank you very much for the help - and the project!</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jan 2, 2018 at 4:14 PM, Boris Kolpackov <span dir="ltr"><<a href="mailto:boris@codesynthesis.com" target="_blank">boris@codesynthesis.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">Kalle Møller <<a href="mailto:kalle@k-moeller.dk">kalle@k-moeller.dk</a>> writes:<br>
<br>
> To learn more about the project, I would like to try and make my own module<br>
> / pure academic purpose. Maybe a latex build system. I would just love to<br>
> get a few pointeres, so that I don't have to debug step my way through.<br>
><br>
> Where should I look for the hook to generate a configuration?<br>
><br>
> When the user runs b update, where does that hook to cxx? As in is it the<br>
> cxx module that knows that a target should be rebuild or does the build<br>
> system tell cxx to rebuild the target?<br>
<br>
</div></div>I think the best way forward is to study a similar module and see how<br>
it works. cxx is very complex so I would recommend, perhaps, cli. It<br>
implements generation of command line interface parsing code (source<br>
code generation) using the cli compiler[1]. It is still probably a bit<br>
more complex than what you need, but I think it's the closest we've got.<br>
<br>
Overall, a latex module would need to do the following:<br>
<br>
1. Register input/output target types, say latex{} and ps{}.<br>
<br>
2. Implement and register a rule that translates input to output.<br>
<br>
3. Configure itself on load.<br>
<br>
Also note that currently build2 does not support building external<br>
modules so you will have to add yours directly into the build2<br>
executable. But this is something that we are planning to address<br>
in the very near future.<br>
<br>
[1] <a href="https://codesynthesis.com/projects/cli/" rel="noreferrer" target="_blank">https://codesynthesis.com/<wbr>projects/cli/</a><br>
<span class="HOEnZb"><font color="#888888"><br>
Boris<br>
</font></span></blockquote></div><br></div>