File tree Expand file tree Collapse file tree 5 files changed +19
-0
lines changed Expand file tree Collapse file tree 5 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -898,6 +898,16 @@ They are associated with `system partitions <#system-partition-configuration>`__
898898 A list of linker flags to be used with this environment by default.
899899
900900
901+ .. py :attribute :: environments.nvcc
902+
903+ :required: No
904+ :default: ``"nvcc" ``
905+
906+ The NVIDIA CUDA compiler to be used with this environment.
907+
908+ .. versionadded :: 4.6
909+
910+
901911.. py :attribute :: environments.target_systems
902912
903913 :required: No
Original file line number Diff line number Diff line change @@ -219,6 +219,7 @@ class ProgEnvironment(Environment):
219219 _cc = fields .TypedField (str )
220220 _cxx = fields .TypedField (str )
221221 _ftn = fields .TypedField (str )
222+ _nvcc = fields .TypedField (str )
222223 _cppflags = fields .TypedField (typ .List [str ])
223224 _cflags = fields .TypedField (typ .List [str ])
224225 _cxxflags = fields .TypedField (typ .List [str ])
@@ -320,4 +321,8 @@ def ldflags(self):
320321
321322 @property
322323 def nvcc (self ):
324+ '''The NVIDIA CUDA compiler of this programming environment.
325+
326+ :type: :class:`str`
327+ '''
323328 return self ._nvcc
Original file line number Diff line number Diff line change @@ -538,6 +538,7 @@ def create(cls, site_config):
538538 cc = site_config .get (f'environments/@{ e } /cc' ),
539539 cxx = site_config .get (f'environments/@{ e } /cxx' ),
540540 ftn = site_config .get (f'environments/@{ e } /ftn' ),
541+ nvcc = site_config .get (f'environments/@{ e } /nvcc' ),
541542 cppflags = site_config .get (f'environments/@{ e } /cppflags' ),
542543 cflags = site_config .get (f'environments/@{ e } /cflags' ),
543544 cxxflags = site_config .get (f'environments/@{ e } /cxxflags' ),
Original file line number Diff line number Diff line change 371371 "cc" : {"type" : " string" },
372372 "cxx" : {"type" : " string" },
373373 "ftn" : {"type" : " string" },
374+ "nvcc" : {"type" : " string" },
374375 "cppflags" : {
375376 "type" : " array" ,
376377 "items" : {"type" : " string" }
528529 "environments/cc" : " cc" ,
529530 "environments/cxx" : " CC" ,
530531 "environments/ftn" : " ftn" ,
532+ "environments/nvcc" : " nvcc" ,
531533 "environments/cppflags" : [],
532534 "environments/cflags" : [],
533535 "environments/cxxflags" : [],
Original file line number Diff line number Diff line change @@ -270,6 +270,7 @@ def test_select_subconfig(site_config):
270270 assert site_config .get ('systems/0/partitions/0/max_jobs' ) == 8
271271 assert len (site_config ['environments' ]) == 7
272272 assert site_config .get ('environments/@PrgEnv-gnu/cc' ) == 'gcc'
273+ assert site_config .get ('environments/@PrgEnv-gnu/nvcc' ) == 'nvcc'
273274 assert site_config .get ('environments/1/cxx' ) == 'g++'
274275 assert site_config .get ('environments/@PrgEnv-cray/cc' ) == 'cc'
275276 assert site_config .get ('environments/2/cxx' ) == 'CC'
You can’t perform that action at this time.
0 commit comments