mirror of
https://gitlab.com/ita1024/waf.git
synced 2024-11-25 11:19:52 +01:00
Interpret relative install paths relative to PREFIX
This commit is contained in:
parent
fe03c6fa47
commit
72ba2cff1e
@ -1054,6 +1054,8 @@ class inst(Task.Task):
|
||||
def get_install_path(self, destdir=True):
|
||||
"""
|
||||
Returns the destination path where files will be installed, pre-pending `destdir`.
|
||||
|
||||
Relative paths will be interpreted relative to `PREFIX` if no `destdir` is given.
|
||||
|
||||
:rtype: string
|
||||
"""
|
||||
@ -1061,6 +1063,8 @@ class inst(Task.Task):
|
||||
dest = self.install_to.abspath()
|
||||
else:
|
||||
dest = Utils.subst_vars(self.install_to, self.env)
|
||||
if not os.path.isabs(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))
|
||||
return dest
|
||||
|
Loading…
Reference in New Issue
Block a user