diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2022-03-28 10:26:39 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2022-03-28 10:26:39 +0200 |
commit | f7ff90672af84a83829371f04f961b389823414c (patch) | |
tree | 7b786cac5bb49e0ea492dd1fc131056c0b80978e /libbuild2/cc | |
parent | 9e55ab1d39bf987d7df87a027c4331e9be309d09 (diff) |
Respect dry-run in Windows assembly creation logic
Diffstat (limited to 'libbuild2/cc')
-rw-r--r-- | libbuild2/cc/windows-rpath.cxx | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/libbuild2/cc/windows-rpath.cxx b/libbuild2/cc/windows-rpath.cxx index e205924..a8bf104 100644 --- a/libbuild2/cc/windows-rpath.cxx +++ b/libbuild2/cc/windows-rpath.cxx @@ -361,11 +361,16 @@ namespace build2 // of the same amalgamation. This way if the amalgamation is moved // as a whole, the links will remain valid. // + // Note: mkanylink() is from libbutl and thus doesn't handle the + // dry-run mode. + // try { - switch (mkanylink (f, l, - true /* copy */, - f.sub (as.out_path ()) /* relative */)) + switch (as.ctx.dry_run + ? entry_type::symlink + : mkanylink (f, l, + true /* copy */, + f.sub (as.out_path ()) /* relative */)) { case entry_type::regular: print ("cp"); break; case entry_type::symlink: print ("ln -s"); break; |