仅当目标已过时时,我如何使用 premake 运行 外部工具
How do I have premake run an external tool only if the target is out of date
作为构建过程的一部分,我有一个需要提取的存档。我可以使用 prebuildcommands
来始终提取它,但这是重复的并且会减慢构建速度。
怎么说"run this command only if the extracted directory does not exist"。
如果存档比目录新,最好也提取文件,但我不太关心这个,因为我不希望存档经常更改。
编辑:我有使用 Premake 4 的外部要求。
看起来文档有点不完整,但是(使用 Premake5)可能是这样的?
buildcommands { "cmd to unarchive the file" }
buildinputs { "name of archive" }
buildoutputs { "name of a file from the archive" }
作为构建过程的一部分,我有一个需要提取的存档。我可以使用 prebuildcommands
来始终提取它,但这是重复的并且会减慢构建速度。
怎么说"run this command only if the extracted directory does not exist"。
如果存档比目录新,最好也提取文件,但我不太关心这个,因为我不希望存档经常更改。
编辑:我有使用 Premake 4 的外部要求。
看起来文档有点不完整,但是(使用 Premake5)可能是这样的?
buildcommands { "cmd to unarchive the file" }
buildinputs { "name of archive" }
buildoutputs { "name of a file from the archive" }