2016-12-26 1 views
0

メークファイルでは次の文字は何を意味しますか?メークファイルの特殊文字意味と使用

$ @、$? $ *、$ <、$^

私はいくつかの説明を見ましたが、正確に使用する方法は完全にはわかりませんでした。

+0

可能な重複を参照してください[makefileのシンボルの$ @と$は<何を意味するのですか?](http://stackoverflow.com/質問/ 3220277/what-do-the-makefile-symbols-and-mean) – mike510a

答えて

1
パターンとさらに説明するために、特別な変数
When wildcard % appears in the dependency list, it is replaced with 
the same string that was used to perform substitution in the target. 

Inside actions we can use: 
    [email protected] to represent the full target name of the current target 
    $? returns the dependencies that are newer than the current target 
    $* returns the text that corresponds to % in the target  
    $< returns the name of the first dependency 
    $^ returns the names of all the dependencies with space as the delimiter 

を使用して、のThis github link