@@ -390,20 +390,9 @@ def generate_environment_specs(self, raw):
390390 f"%[when=%c] c={ compiler } %[when=%cxx] cxx={ compiler } %[when=%fortran] fortran={ compiler } "
391391 ]
392392
393- # An awkward hack to work around spack not supporting creating activation
394- # scripts for each file system view in an environment: it only generates them
395- # for the "default" view.
396- # The workaround is to create multiple versions of the same environment, one
397- # for each view.
398- # TODO: remove when the minimum supported version of spack is v0.21, in which
399- # this issue was fixed, see https://github.com/spack/spack/pull/40549
400- # we have a `--develop` workaround that uses the current approach of generating
401- # a separate environment for each view, with a view named "default", and uses
402- # the name default to generated the activation script.
393+ # Create all meta data for all of the views.
403394 env_names = set ()
404- env_name_map = {}
405395 for name , config in environments .items ():
406- env_name_map [name ] = []
407396 views = []
408397 for view_name , vc in config ["views" ].items ():
409398 if view_name in env_names :
@@ -434,7 +423,6 @@ def generate_environment_specs(self, raw):
434423 view_config ["root" ] = str (self .mount / "env" / view_name )
435424
436425 extra = view_config .pop ("uenv" )
437- env_name_map [name ].append ((view_name , view_config ))
438426 views .append ({"name" : view_name , "config" : view_config , "extra" : extra })
439427
440428 config ["views" ] = views
0 commit comments