zoukankan      html  css  js  c++  java
  • GNU make manual 翻译(六十八)

    继续翻译

    Secondary Expansion of Explicit Rules                        
    -------------------------------------                        
                            
    During the secondary expansion of explicit rules, `$$@' and `$$%' evaluate, respectively, to the file name of the target and, when the target is an archive member, the target member name.  The `$$<'  variable evaluates to the first prerequisite in the first rule for this  target.  `$$^' and `$$+' evaluate to the list of all prerequisites of  rules _that have already appeared_ for the same target (`$$+' with 
    repetitions and `$$^' without).  The following example will help  illustrate these behaviors:                        
                            
         .SECONDEXPANSION:                        
                            
         foo: foo.1 bar.1 $$< $$^ $$+    # line #1                        
                            
         foo: foo.2 bar.2 $$< $$^ $$+    # line #2                        
                            
         foo: foo.3 bar.3 $$< $$^ $$+    # line #3                        
                            
       In the first prerequisite list, all three variables (`$$<', `$$^', and `$$+') expand to the empty string.  In the second, they will have  values `foo.1', `foo.1 bar.1', and `foo.1 bar.1' respectively.  In the  third they will have values `foo.1', `foo.1 bar.1 foo.2 bar.2', and  `foo.1 bar.1 foo.2 bar.2 foo.1 foo.1 bar.1 foo.1 bar.1' respectively.   

    在对显式规则进行二次扩展期间,

    当目的是一个归档的成员,$$@ 和 $$% 分别被解析成为目的的名称--目的成员的各个名称。

    $$< 变量给出此第一个规则里的目的的第一个前提条件。

    $$^ 和 $$+ 此规则的所有的前提条件列表($$+ 有重复运算能力,$$^则没有)

    下面是一个例子,可以帮组我们理解其行为:

    .SECONDEXPANSION:

    foo: foo.1 bar.1 $$< $$^ $$+ # line #1

    foo: foo.2 bar.2 $$< $$^ $$+ # line #2

    foo: foo.3 bar.3 $$< $$^ $$+ # line #3

    In the first prerequisite list, all three variables (`$$<', `$$^',
    and `$$+') expand to the empty string. In the second, they will have
    values `foo.1', `foo.1 bar.1', and `foo.1 bar.1' respectively. In the
    third they will have values `foo.1', `foo.1 bar.1 foo.2 bar.2', and
    `foo.1 bar.1 foo.2 bar.2 foo.1 foo.1 bar.1 foo.1 bar.1' respectively.

    在第一行的前提条件列表中,此三个变量($$<,$$^,$$+)分别都是空串。

    在第二行,它们将分别拥有 foo.1, foo.1 bar.1  和 foo.1 bar.1 的值。

    在第三行,它们将分别拥有

            foo.1  

            foo.1 bar.1  foo.2 bar.2 

            foo.1 bar.1  foo.2 bar.2  foo.1 foo.1 bar.1  foo.1 bar.1 

    后文待续

  • 相关阅读:
    PHP的资源类型
    windows 配置 apache的多个站点
    php 压缩数据存储
    php统计图类库JpGraph
    php之ThinkPHP的memcached类的修改
    linux 安装报错:pkg-config not found
    Mysql清空表(truncate)与删除表中数据(delete)的区别
    【MySQL】查看MySQL配置文件路径及相关配置
    phper
    http 同步异步请求
  • 原文地址:https://www.cnblogs.com/gaojian/p/2688606.html
Copyright © 2011-2022 走看看