Closed solsjo closed 1 year ago
it seems setting the environment variables from starlark results in a lot of memory being claimed. It might be wise to handle the setting via Args instead, so as to more efficiently handle it. Or pass the envs, as an action parameter instead of as an argument.
@Kernald Can you have a look at this pull request?
@patbro would you have time to review this pull request?
Sorry for the delay - I'll try looking at these over the next few days!
No worries! Thanks for the review @Kernald. I have a follow up commit that removes the tool_wrapper altogether as well. When you have time :)
Updated according to the comments.
@Kernald
Thanks!
This pull request aims at simplifying the rules, raise the readability, reduce the build time of the builds and promote extensibility.
Build times are reduced by not copying all binaries to a structure similar to the one latex expects. Latex / kpathsea assumes that directories with only symlinks to be empty. This is overcome by instead setting the environment variables that kpathsea makes use of (kpathsea is the lib responsible for locating files in the tex environment).
Apart from this further refactoring might be able to do away with the tool_wrapper altogether.