diff --git a/var/spack/repos/builtin/packages/ascent/package.py b/var/spack/repos/builtin/packages/ascent/package.py index ebca681c922..e6c9b8faa24 100644 --- a/var/spack/repos/builtin/packages/ascent/package.py +++ b/var/spack/repos/builtin/packages/ascent/package.py @@ -370,9 +370,7 @@ def _get_host_config_path(self, spec): # if on llnl systems, we can use the SYS_TYPE if "SYS_TYPE" in env: sys_type = env["SYS_TYPE"] - host_config_path = "{0}-{1}-{2}-ascent-{3}.cmake".format( - socket.gethostname(), sys_type, spec.compiler, spec.dag_hash() - ) + host_config_path = f"{socket.gethostname()}-{sys_type}-ascent-{spec.dag_hash()}.cmake" dest_dir = spec.prefix host_config_path = os.path.abspath(join_path(dest_dir, host_config_path)) return host_config_path diff --git a/var/spack/repos/builtin/packages/conduit/package.py b/var/spack/repos/builtin/packages/conduit/package.py index 7d9d343570f..63509bc0947 100644 --- a/var/spack/repos/builtin/packages/conduit/package.py +++ b/var/spack/repos/builtin/packages/conduit/package.py @@ -303,9 +303,7 @@ def _get_host_config_path(self, spec): # if on llnl systems, we can use the SYS_TYPE if "SYS_TYPE" in env: sys_type = env["SYS_TYPE"] - host_config_path = "{0}-{1}-{2}-conduit-{3}.cmake".format( - socket.gethostname(), sys_type, spec.compiler, spec.dag_hash() - ) + host_config_path = f"{socket.gethostname()}-{sys_type}-conduit-{spec.dag_hash()}.cmake" dest_dir = self.stage.source_path host_config_path = os.path.abspath(join_path(dest_dir, host_config_path)) diff --git a/var/spack/repos/builtin/packages/lvarray/package.py b/var/spack/repos/builtin/packages/lvarray/package.py index 17cbace3b9f..69126be8aa3 100644 --- a/var/spack/repos/builtin/packages/lvarray/package.py +++ b/var/spack/repos/builtin/packages/lvarray/package.py @@ -121,12 +121,7 @@ def _get_host_config_path(self, spec): var = "-".join([var, "cuda"]) hostname = socket.gethostname().rstrip("1234567890") - host_config_path = "%s-%s-%s%s.cmake" % ( - hostname, - self._get_sys_type(spec), - spec.compiler, - var, - ) + host_config_path = f"{hostname}-{self._get_sys_type(spec)}-{var}.cmake" dest_dir = self.stage.source_path host_config_path = os.path.abspath(pjoin(dest_dir, host_config_path)) diff --git a/var/spack/repos/builtin/packages/vtk-h/package.py b/var/spack/repos/builtin/packages/vtk-h/package.py index 1a93d29fea9..ce922a8e9ae 100644 --- a/var/spack/repos/builtin/packages/vtk-h/package.py +++ b/var/spack/repos/builtin/packages/vtk-h/package.py @@ -114,9 +114,7 @@ def _get_host_config_path(self, spec): # if on llnl systems, we can use the SYS_TYPE if "SYS_TYPE" in env: sys_type = env["SYS_TYPE"] - host_config_path = "{0}-{1}-{2}-vtkh-{3}.cmake".format( - socket.gethostname(), sys_type, spec.compiler, spec.dag_hash() - ) + host_config_path = f"{socket.gethostname()}-{sys_type}-vtkh-{spec.dag_hash()}.cmake" dest_dir = spec.prefix host_config_path = os.path.abspath(join_path(dest_dir, host_config_path)) return host_config_path