Closed Danie-1 closed 2 weeks ago
I think this issue should be fixed in the development version: https://github.com/michal-h21/make4ht/commit/af9cfa3d050c8bc2551217d31d54e3fd745b59dd
The fix is in parse_lg
function in mkutils.lua
, where we check if the file referenced by the File:
directive in the .lg
file exists in the build dir. If it doesn't exist, the original path of the file is used.
Thanks! I should've checked that the bug was still present on the latest version. I've tested again with the newer version and the bug isn't present anymore.
Create the following files:
mwe.tex
:styles.sty
(empty file)styles.4ht
:styles.css
(empty file)Then run the following command:
make4ht mwe.tex -B "builddir" -d "outdir"
.I get the error
cp: cannot stat 'builddir/styles.css': No such file or directory
. I'm not sure if this is considered a bug, and I'm not too sure how to fix it. The same problem is also present when using tex4ebooks. I think the issue could be fixed for both make4ht and tex4ebook by modifying the copy or cp functions inmkutils.lua
. Maybe the line sayingkpse.find_file(src)
would be a good place to add some more code. The thing that makes me a bit uncertain though is that I want to run another attempt where we remove the builddir from the beginning, but I can't do this because I don't know how to get the builddir from inside the cp function.