很明显,目标比这两个 ls 命令的源更新:
[metaperl@andLinux ~/edan/pkg/gist.el] ls -l ../../wares/gist.el/gist.elc #target
-rw-r--r-- 1 metaperl metaperl 10465 Jul 18 10:56 ../../wares/gist.el/gist.elc
[metaperl@andLinux ~/edan/pkg/gist.el] ls -l yank/gist.el/gist.el #source
-rw-r--r-- 1 metaperl metaperl 13025 Jul 18 10:57 yank/gist.el/gist.el
[metaperl@andLinux ~/edan/pkg/gist.el]
但是,当我运行makepp -v
时,我被告知此规则不仅取决于列出的目标,还取决于 cd 和 mv 命令。
makepplog: 目标
/home/metaperl/edan/wares/gist.el/gist.elc' depend on
/usr/local/bin/emacs',/home/metaperl/edan/pkg/gist.el/yank/gist.el/gist.el',
/bin/mv'
make 逻辑的哪个方面规定生成目标的操作是决定是否生成目标的依赖链的一部分?
在我看来,只有列出的来源会影响目标是否被重建。
整个makepp -v
输出很长,存在于:
http: //gist.github.com/480468
我的makepp文件:
include main.makepp
#VER
PKG := gist.el
URL := http://github.com/defunkt/$(PKG).git
TARGET := $(WARES)gist.el/gist.elc
$(TARGET) : yank/gist.el/gist.el
cd $(dir $(input)) && $(BYTECOMPILE) gist.el
mv $(dir $(input)) $(WARES)
perl {{
print 'github username: ';
my $username = <STDIN>;
print 'github API token: ';
my $api_token = <STDIN>;
system "git config --global github.user $username";
system "git config --global github.token $api_token";
use File::Butler;
my $lines = Butler('init.el', 'read');
my $loc = sprintf '%s%s', $EDAN_PKG, "$PKG/";
$lines =~ s/__LOC__/$loc/g;
$lines =~ s/__PKG__/$PKG/g;
Butler( $EDAN_EL, prepend => \$lines );
}}
yank/gist.el/gist.el : yank
cd yank && git clone http://github.com/defunkt/gist.el.git
yank:
mkdir yank
$(phony clean):
$(RM) -rf $(dir $(TARGET)) yank