'Return the \'output\' (full output path) of a gyp spec.
E.g., the loadable module \'foobar\' in directory \'baz\' will produce
\'$(obj)/baz/libfoobar.so\''

def ComputeOutput(self, spec):

    assert (not self.is_mac_bundle)
    path = os.path.join(('$(obj).' + self.toolset), self.path)
    if ((self.type == 'executable') or self._InstallImmediately()):
        path = '$(builddir)'
    path = spec.get('product_dir', path)
    return os.path.join(path, self.ComputeOutputBasename(spec))
