博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
GNU make manual 翻译(九十一)
阅读量:7222 次
发布时间:2019-06-29

本文共 1205 字,大约阅读时间需要 4 分钟。

继续翻译

`%' characters in a `vpath' directive's pattern can be quoted with preceding backslashes (`\').  Backslashes that would otherwise quote `%' characters can be quoted with more backslashes.  Backslashes that quote `%' characters or other backslashes are removed from the pattern before it is compared to file names.  Backslashes that are not in danger of quoting `%' characters go unmolested.
When a prerequisite fails to exist in the current directory, if the PATTERN in a `vpath' directive matches the name of the prerequisite file, then the DIRECTORIES in that directive are searched just like(and before) the directories in the `VPATH' variable.                                                   For example,              vpath %.h ../headers                                                tells `make' to look for any prerequisite whose name ends in `.h' in the directory `../headers' if the file is not found in the current directory.

在一个 vpath 指令模式中的 % 符号可以被反斜线引用起来。反斜线也可以被反斜线所引用。

在进行文件名比较的时候,起到引用作用的反斜线将被从模式中移走。不起引用作用的反斜线会被忽略。

一个前提条件不在当前目录,如果 vpath 指令中的模式匹配了前提条件文件,那么此指令中的 DIRECTORIES 就会被搜索,就像在 VPATH 变量中一样。

例如,

vpath %.h ../headers
告诉 make 去在 ../headers 目录下寻找任何名字为 .h 的文件,如果此文件在当前目录中没有的话。

 

后文待续

转载地址:http://yuzfm.baihongyu.com/

你可能感兴趣的文章
Java的多进程运行模式分析
查看>>
百度面试题:求绝对值最小的数
查看>>
敏捷个人手机应用:如何使用时中法目标
查看>>
Android 解决ListView 和 ScrollView 共存冲突的问题
查看>>
利用Power Designer反向数据库结构
查看>>
在ISA 2006企业版环境下配置存储服务器(CSS)
查看>>
使用Seam-gen生成基础项目骨架
查看>>
RHCE学习<13>RHCS集群(RHCS+GFS2+ISCSI)
查看>>
Java线程:线程私有变量
查看>>
[Web开发] Web 2.0 网站估价工具
查看>>
IE8 默认以Web Standards模式显示网页 全面遵循Web标准
查看>>
网站Web项目树形菜单的实现过程(ExtJS+SpringMVC+Spring+Hibernate+MySQL)
查看>>
深入浅出Attribute(中)——Attribute本质论
查看>>
Lync 小技巧-52-Lync 2013-不加域-客户端-2-导入-证书-信任链
查看>>
Drawable、Bitmap、Canvas和Paint的关系以及部分使用方法
查看>>
DeepEarth中的几何图形基础框架模型
查看>>
Enterprise Library Step By Step系列(十):缓冲应用程序块——进阶篇
查看>>
C# 对Excel操作时,单元格值的读取
查看>>
PreparedStatement--摘抄自http://blog.chinaunix.net/u/28512/showart_221625.html
查看>>
网络扫描程序的详细分析与实现
查看>>