Пример #1
0
 def program_files(self, executable):
     """
     Returns a list of files or directories that are necessary to run the tool.
     """
     installDir = os.path.dirname(executable)
     return [executable] + util.flatten(
         util.expand_filename_pattern(path, installDir)
         for path in REQUIRED_PATHS)
Пример #2
0
 def program_files(self, executable):
     """ List of files/directories necessary to build and run the tool. """
     executableDir = os.path.dirname(executable)
     dependencies = [
         "predator-repo",
         "build-all.sh"
         ]
     return [executable] + util.flatten(util.expand_filename_pattern(dep, installDir) for dep in dependencies)
Пример #3
0
 def program_files(self, executable):
     """
     OPTIONAL, this method is only necessary for situations when the benchmark environment
     needs to know all files belonging to a tool
     (to transport them to a cloud service, for example).
     Returns a list of files or directories that are necessary to run the tool,
     relative to the current directory.
     @return a list of paths as strings
     """
     installDir = os.path.dirname(executable)
     return [executable] + util.flatten(util.expand_filename_pattern(path, installDir) for path in self.REQUIRED_PATHS)
Пример #4
0
    def program_files(self, executable):
        installDir = joinpath(dirname(executable), '..')
        if self._version_newer_than('5.0.0'):
            paths = self.REQUIRED_PATHS_5_0_0
        elif self._version_newer_than('4.0.1'):
            paths = self.REQUIRED_PATHS_4_0_1
        else:
            paths = OldSymbiotic.REQUIRED_PATHS

        return [executable] + util.flatten(
            util.expand_filename_pattern(path, installDir) for path in paths)
Пример #5
0
 def program_files(self, executable):
     """
     OPTIONAL, this method is only necessary for situations when the benchmark environment
     needs to know all files belonging to a tool
     (to transport them to a cloud service, for example).
     Returns a list of files or directories that are necessary to run the tool,
     relative to the current directory.
     @return a list of paths as strings
     """
     installDir = os.path.dirname(executable)
     return [executable] + util.flatten(
         util.expand_filename_pattern(path, installDir)
         for path in self.REQUIRED_PATHS)
Пример #6
0
 def _program_files_from_executable(executable,
                                    required_paths,
                                    parent_dir=False):
     """
     Get a list of program files by expanding a list of path patterns
     and interpreting it as relative to the executable.
     This method can be used as helper for implementing the method program_files().
     Contrary to the default implementation of program_files(), this method does not explicitly
     add the executable to the list of returned files, it assumes that required_paths
     contains a path that covers the executable.
     @param executable: the path to the executable of the tool (typically the result of executable())
     @param required_paths: a list of required path patterns
     @param parent_dir: whether required_paths are relative to the directory of executable or the parent directory
     @return a list of paths as strings, suitable for result of program_files()
     """
     base_dir = os.path.dirname(executable)
     if parent_dir:
         base_dir = os.path.join(base_dir, os.path.pardir)
     return util.flatten(
         util.expand_filename_pattern(path, base_dir)
         for path in required_paths)
Пример #7
0
 def program_files(self, executable):
     install_dir = os.path.dirname(executable)
     paths = self.REQUIRED_PATHS_SVCOMP17 if self._is_svcomp17_version(
         executable) else self.REQUIRED_PATHS
     return [executable] + util.flatten(
         util.expand_filename_pattern(path, install_dir) for path in paths)
Пример #8
0
 def program_files(self, executable):
     installDir = os.path.join(os.path.dirname(executable), os.path.pardir)
     return util.flatten(
         util.expand_filename_pattern(path, installDir)
         for path in self.REQUIRED_PATHS)
Пример #9
0
 def program_files(self, executable):
     installDir = os.path.join(os.path.dirname(executable), os.path.pardir)
     return util.flatten(util.expand_filename_pattern(path, installDir) for path in REQUIRED_PATHS)
Пример #10
0
 def program_files(self, executable):
     """
     Returns a list of files or directories that are necessary to run the tool.
     """
     installDir = os.path.dirname(executable)
     return [executable] + util.flatten(util.expand_filename_pattern(path, installDir) for path in REQUIRED_PATHS)
Пример #11
0
 def program_files(self, executable):
     install_dir = os.path.dirname(executable)
     paths = self.REQUIRED_PATHS_SVCOMP17 if self._is_svcomp17_version(executable) else self.REQUIRED_PATHS
     return [executable] + util.flatten(util.expand_filename_pattern(path, install_dir) for path in paths)