third_party: Update waf to version 2.0.22
[samba.git] / third_party / waf / waflib / Build.py
index 52837618577f644b0455c67b3ef8ec8d8b92c7eb..b49dd8302b16179503957a38535090f96f2e3e2e 100644 (file)
@@ -1066,9 +1066,9 @@ class inst(Task.Task):
                else:
                        dest = os.path.normpath(Utils.subst_vars(self.install_to, self.env))
                if not os.path.isabs(dest):
-                   dest = os.path.join(self.env.PREFIX, dest)
+                       dest = os.path.join(self.env.PREFIX, dest)
                if destdir and Options.options.destdir:
-                       dest = os.path.join(Options.options.destdir, os.path.splitdrive(dest)[1].lstrip(os.sep))
+                       dest = Options.options.destdir.rstrip(os.sep) + os.sep + os.path.splitdrive(dest)[1].lstrip(os.sep)
                return dest
 
        def copy_fun(self, src, tgt):