本文介绍了Makefile和通配符目标的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我的目录中包含许多文件.我想对这些文件(即md5sum)运行命令.与其继续重新计算校验和,我不希望存储校验和.我想以并行方式(make -j)计算校验和
I have a directory with many files. I would like to run a command against these files (ie. md5sum). Instead of keep recomputing the checksum I would like to store the checksum. I would like to compute the checksums in a parallel manner (make -j)
推荐答案
类似的东西:
md5sums: $(addsuffix .md5sum,$(wildcard *.foo))
%.md5sum: %
md5sum $< > $@
这是我们在有限的可用描述中所能做的最好的事情.
That's about the best we can do with the limited description available.
这篇关于Makefile和通配符目标的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!