From c3d9ca6c89e68691b14e087798fd0f1ad4879a3d Mon Sep 17 00:00:00 2001 From: Tom van Dijck Date: Tue, 30 Jun 2015 15:02:52 -0700 Subject: [PATCH] fix targetdir default. --- src/base/config.lua | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/base/config.lua b/src/base/config.lua index 996b3765..39263ed4 100755 --- a/src/base/config.lua +++ b/src/base/config.lua @@ -31,7 +31,14 @@ function config.buildtargetinfo(cfg, kind, field) local basedir = cfg.project.location - local directory = cfg[field.."dir"] or cfg.targetdir or basedir + local targetdir + if cfg.platform then + targetdir = path.join(basedir, 'bin', cfg.platform, cfg.buildcfg) + else + targetdir = path.join(basedir, 'bin', cfg.buildcfg) + end + + local directory = cfg[field.."dir"] or cfg.targetdir or targetdir local basename = cfg[field.."name"] or cfg.targetname or cfg.project.name local prefix = cfg[field.."prefix"] or cfg.targetprefix or ""