How to generate dependencies when they don't exist

I’m creating a cmake project to generate a number of typst PDFs. Some of these include images which are also generated by cmake. If I generate the images first I can use typst compile --deps to create a make format dependency file that works. The problem I have is I can’t initially generate that file if the images haven’t been generated yet.

That means I can’t generate the deps file during cmake configure and generating it during the normal cmake compile only works if the image happens to be first in the build order.

Is there a way I can get typst to only generate the deps file (no compilation to PDF) and add dep targets even if the files don’t exist? If not, is there another way to solve this issue that doesn’t involve a custom script to extract dependencies?