aboutsummaryrefslogtreecommitdiff
path: root/lib/compilers/dmd.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/compilers/dmd.js')
-rw-r--r--lib/compilers/dmd.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/compilers/dmd.js b/lib/compilers/dmd.js
index 62ef2de4a..8ee342277 100644
--- a/lib/compilers/dmd.js
+++ b/lib/compilers/dmd.js
@@ -52,10 +52,11 @@ class DMDCompiler extends BaseCompiler {
}
objdump(outputFilename, result, maxSize, intelAsm, demangle) {
+ const dirPath = path.dirname(outputFilename);
let args = ["-d", outputFilename, "-l", "--insn-width=16"];
if (demangle) args = args.concat("-C");
if (intelAsm) args = args.concat(["-M", "intel"]);
- return this.exec(this.compiler.objdumper, args, {maxOutput: maxSize})
+ return this.exec(this.compiler.objdumper, args, {maxOutput: maxSize, customCwd: dirPath})
.then(objResult => {
result.asm = objResult.stdout;
if (objResult.code !== 0) {