code: def create(self, basedir, outdir, name, prefix=None):
      
      zippath = os.path.join(outdir, '{}.{}'.format(name, self.extension))
      with open_zip(zippath, 'w', compression=self.compression) as zip:
        # For symlinks, we want to archive the actual content of linked files but
        # under the relpath derived from symlink.
        for root, _, files in safe_walk(basedir, followlinks=True):
          root = ensure_text(root)
          for file in files:
            file = ensure_text(file)
            full_path = os.path.join(root, file)
            relpath = os.path.relpath(full_path, basedir)
            if prefix:
              relpath = os.path.join(ensure_text(prefix), relpath)
            zip.write(full_path, relpath)
      return zippath
docs: :API: public