From cb6d357208b2db9516aaa0046bca751e51b32ec2 Mon Sep 17 00:00:00 2001 From: ruki Date: Wed, 1 Jul 2020 00:53:41 +0800 Subject: improve makefile generator --- xmake/plugins/project/make/makefile.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'xmake/plugins/project/make/makefile.lua') diff --git a/xmake/plugins/project/make/makefile.lua b/xmake/plugins/project/make/makefile.lua index 95df0ee86..02deeb3f9 100644 --- a/xmake/plugins/project/make/makefile.lua +++ b/xmake/plugins/project/make/makefile.lua @@ -233,8 +233,9 @@ function _make_target(makefile, target, targetflags) makefile:printf("%s:", targetfile) -- make dependence for the dependent targets - for _, dep in ipairs(target:get("deps")) do - makefile:write(" " .. project.target(dep):targetfile()) + for _, depname in ipairs(target:get("deps")) do + local dep = project.target(depname) + makefile:write(" " .. (dep:isphony() and depname or dep:targetfile())) end -- make dependence for objects -- cgit v1.3.1