Lines Matching +full:linux +full:- +full:intel
36 isARM_value = -1
116 …help.addArgument('Compilers', '-with-cpp=<prog>', nargs.Arg(None, None, 'Specify the C preprocesso…
117 …help.addArgument('Compilers', '-CPP=<prog>', nargs.Arg(None, None, 'Specify the C prepr…
118 …help.addArgument('Compilers', '-CPPFLAGS=<string>', nargs.Arg(None, None, 'Specify the C only …
119 … help.addArgument('Compilers', '-with-cc=<prog>', nargs.Arg(None, None, 'Specify the C compiler'))
120 …help.addArgument('Compilers', '-CC=<prog>', nargs.Arg(None, None, 'Specify the C compi…
121 …help.addArgument('Compilers', '-CFLAGS=<string>', nargs.Arg(None, None, 'Overwrite the defau…
123 …help.addArgument('Compilers', '-CFLAGS+=<string>', nargs.Arg(None, None, 'Add to the default …
124 …help.addArgument('Compilers', '-CC_LINKER_FLAGS=<string>', nargs.Arg(None, [], 'Specify the C lin…
126 …help.addArgument('Compilers', '-CXXPP=<prog>', nargs.Arg(None, None, 'Specify the C++ pre…
127 …help.addArgument('Compilers', '-CXXPPFLAGS=<string>', nargs.Arg(None, None, 'Specify the C++ pre…
128 …help.addArgument('Compilers', '-with-cxx=<prog>', nargs.Arg(None, None, 'Specify the C++ compiler'…
129 …help.addArgument('Compilers', '-CXX=<prog>', nargs.Arg(None, None, 'Specify the C++ com…
130 …help.addArgument('Compilers', '-CXXFLAGS=<string>', nargs.Arg(None, None, 'Overwrite the defau…
132 …help.addArgument('Compilers', '-CXXFLAGS+=<string>', nargs.Arg(None, None, 'Add to the default …
133 …help.addArgument('Compilers', '-CXX_CXXFLAGS=<string>', nargs.Arg(None, '', 'Specify the C++ com…
134 …help.addArgument('Compilers', '-CXX_LINKER_FLAGS=<string>', nargs.Arg(None, [], 'Specify the…
136 …help.addArgument('Compilers', '-FPP=<prog>', nargs.Arg(None, None, 'Specify the Fortran…
137 …help.addArgument('Compilers', '-FPPFLAGS=<string>', nargs.Arg(None, None, 'Specify the Fortran…
138 …help.addArgument('Compilers', '-with-fc=<prog>', nargs.Arg(None, None, 'Specify the Fortran compi…
139 …help.addArgument('Compilers', '-FC=<prog>', nargs.Arg(None, None, 'Specify the Fortran…
140 …help.addArgument('Compilers', '-FFLAGS=<string>', nargs.Arg(None, None, 'Overwrite the defau…
142 …help.addArgument('Compilers', '-FFLAGS+=<string>', nargs.Arg(None, None, 'Add to the default …
143 …help.addArgument('Compilers', '-FC_LINKER_FLAGS=<string>', nargs.Arg(None, [], 'Specify the…
145 …help.addArgument('Compilers', '-with-large-file-io=<bool>', nargs.ArgBool(None, 0, 'Allow IO with …
147 …help.addArgument('Compilers', '-CUDAPP=<prog>', nargs.Arg(None, None, 'Specify the CUDA pre…
148 …help.addArgument('Compilers', '-CUDAPPFLAGS=<string>', nargs.Arg(None, None, 'Specify the CUDA pre…
149 …help.addArgument('Compilers', '-with-cudac=<prog>', nargs.Arg(None, None, 'Specify the CUDA com…
150 …help.addArgument('Compilers', '-CUDAC=<prog>', nargs.Arg(None, None, 'Specify the CUDA com…
151 …help.addArgument('Compilers', '-CUDAFLAGS=<string>', nargs.Arg(None, None, 'Overwrite the PETSc …
153 …help.addArgument('Compilers', '-CUDAC_LINKER_FLAGS=<string>', nargs.Arg(None, [], 'Specify …
155 …help.addArgument('Compilers', '-HIPPP=<prog>', nargs.Arg(None, None, 'Specify the HIP prepr…
156 …help.addArgument('Compilers', '-HIPPPFLAGS=<string>', nargs.Arg(None, None, 'Specify the HIP prepr…
157 …help.addArgument('Compilers', '-with-hipc=<prog>', nargs.Arg(None, None, 'Specify the HIP compi…
158 …help.addArgument('Compilers', '-HIPC=<prog>', nargs.Arg(None, None, 'Specify the HIP compi…
159 …help.addArgument('Compilers', '-HIPFLAGS=<string>', nargs.Arg(None, None, 'Overwrite the PETSc d…
161 …help.addArgument('Compilers', '-HIPC_LINKER_FLAGS=<string>', nargs.Arg(None, [], 'Specify t…
163 …help.addArgument('Compilers', '-SYCLPP=<prog>', nargs.Arg(None, None, 'Specify the SYCL pre…
164 …help.addArgument('Compilers', '-SYCLPPFLAGS=<string>', nargs.Arg(None, None, 'Specify the SYCL pre…
165 …help.addArgument('Compilers', '-with-syclc=<prog>', nargs.Arg(None, None, 'Specify the SYCL com…
166 …help.addArgument('Compilers', '-SYCLC=<prog>', nargs.Arg(None, None, 'Specify the SYCL com…
167 …help.addArgument('Compilers', '-SYCLFLAGS=<string>', nargs.Arg(None, None, 'Overwrite the PETSc …
169 …help.addArgument('Compilers', '-SYCLC_LINKER_FLAGS=<string>', nargs.Arg(None, '', 'Specify …
171 ## help.addArgument('Compilers', '-LD=<prog>', nargs.Arg(None, None, 'Specify the e…
172 ## help.addArgument('Compilers', '-CC_LD=<prog>', nargs.Arg(None, None, 'Specify the l…
173 ## help.addArgument('Compilers', '-CXX_LD=<prog>', nargs.Arg(None, None, 'Specify the l…
174 ## help.addArgument('Compilers', '-FC_LD=<prog>', nargs.Arg(None, None, 'Specify the l…
175 …help.addArgument('Compilers', '-with-shared-ld=<prog>', nargs.Arg(None, None, 'Specify the shared…
176 …help.addArgument('Compilers', '-LD_SHARED=<prog>', nargs.Arg(None, None, 'Specify the shared…
177 …help.addArgument('Compilers', '-LDFLAGS=<string>', nargs.Arg(None, '', 'Specify the linker…
178 …help.addArgument('Compilers', '-with-ar=<prog>', nargs.Arg(None, None, 'Specify t…
179 …help.addArgument('Compilers', '-AR=<prog>', nargs.Arg(None, None, 'Specify t…
180 …help.addArgument('Compilers', '-AR_FLAGS=<string>', nargs.Arg(None, None, 'Specify…
181 …help.addArgument('Compilers', '-with-ranlib=<prog>', nargs.Arg(None, None, 'Specify r…
182 …help.addArgument('Compilers', '-with-pic=<bool>', nargs.ArgBool(None, 0, 'Compile wi…
183 …help.addArgument('Compilers', '-sharedLibraryFlags=<string>', nargs.Arg(None, [], 'Specify the…
184 …help.addArgument('Compilers', '-dynamicLibraryFlags=<string>', nargs.Arg(None, [], 'Specify the…
185 …help.addArgument('Compilers', '-LIBS=<string>', nargs.Arg(None, None, 'Specify extra libr…
186 …help.addArgument('Compilers', '-with-environment-variables=<bool>',nargs.ArgBool(None, 0, 'Use com…
196 …-with-cxx-dialect=<dialect>',nargs.Arg(None, 'auto', 'Dialect under which to compile C++ sources. …
197 …-with-hip-dialect=<dialect>',nargs.Arg(None, 'auto', 'Dialect under which to compile HIP sources. …
198 …-with-cuda-dialect=<dialect>',nargs.Arg(None, 'auto', 'Dialect under which to compile CUDA sources…
199 …-with-sycl-dialect=<dialect>',nargs.Arg(None, 'auto', 'Dialect under which to compile SYCL sources…
213 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' -V',checkCommand = …
226 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' -v',checkCommand = …
228 if output.find('w64-mingw32') >= 0:
238 …rror, status) = config.base.Configure.executeShellCommand(compiler+' --help | head -n 20 ', log = …
244 '-print-libgcc-file-name',
245 'passed on to the various sub-processes invoked by gcc',
246 'passed on to the various sub-processes invoked by cc',
247 … 'passed on to the various sub-processes invoked by gfortran',
248 'passed on to the various sub-processes invoked by g++',
249 'passed on to the various sub-processes invoked by c++',
251 and not any([s in output for s in ['Intel(R)',
252 … 'Unrecognised option --help passed to ld', # NAG f95 compiler
256 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
257 found = any([s in output for s in ['(GCC)','GNU Fortran','gcc-','g++-']])
268 …rror, status) = config.base.Configure.executeShellCommand(compiler+' --help | head -n 500', log = …
282 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
292 '''Returns true if the compiler is an Intel oneAPI compiler'''
294 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
296 found = any([s in output for s in ['Intel(R) oneAPI']])
298 if log: log.write('Detected Intel oneAPI compiler\n')
307 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
309 …# Currently we only tested Intel oneAPI DPC++. Expand the list as more sycl compilers are available
321 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
333 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
343 '''returns true if the compiler is gcc-11.0.x or later'''
345 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
348 strmatch = re.match(r'gcc[-0-9]*\s+\(.*\)\s+(\d+)\.(\d+)',output)
356 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' -dumpversion', log …
370 '''returns true if the compiler is gcc-15.0.x or later'''
372 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
375 strmatch = re.match(r'gcc[-0-9]*\s+\(.*\)\s+(\d+)\.(\d+)',output)
383 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' -dumpversion', log …
397 '''returns true if the compiler is gfortran-10.0.x or later'''
399 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
413 '''returns true if the compiler is gfortran-8 or later'''
415 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
431 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' -V',checkCommand = …
444 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' -qversion', log = l…
454 '''Returns true if the compiler is a Intel compiler'''
456 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version', log = l…
458 if 'Intel' in output:
459 if log: log.write('Detected Intel compiler\n')
468 if x and x.find('CRAYPE_MIC-KNL') > -1:
476 (output, error, status) = config.base.Configure.executeShellCommand(compiler+' -V', log = log)
489 …# Cray PE compiler wrappers (e.g., cc) when invoked with --version option will complain when CRAY_…
492 'CRAY_CPU_TARGET="%s" %s --version' % (canary_value, compiler),
508 … (output, error, status) = config.base.Configure.executeShellCommand(compiler+' -VV', log = log)
522 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' -V',checkCommand = …
535 …(output, error, status) = config.base.Configure.executeShellCommand(compiler+' --version',checkCom…
551 if log: log.write('Detected Non-Microsoft Windows native compiler\n')
559 … output, error, _ = cls.executeShellCommand(compiler + ' --version', checkCommand=noCheck, log=log)
572 …(output, error, status) = config.base.Configure.executeShellCommand(ar + ' -V',checkCommand = noCh…
583 …(output, error, status) = config.base.Configure.executeShellCommand(ar + ' -V',checkCommand = noCh…
585 if output.find('[-X{32|64|32_64|d64|any}]') >= 0:
594 (output, error, status) = config.base.Configure.executeShellCommand('uname -s', log = log)
597 if output.find('linux') >= 0:
598 if log: log.write('Detected Linux OS')
628 '''Returns true if system is linux'''
670 '''Returns true if system is processor-type is ARM'''
672 if isARM_value == -1:
673 (output, error, status) = config.base.Configure.executeShellCommand('uname -m', log = log)
693 if ('with-cc' in self.argDB and self.argDB['with-cc'] != '0') or 'CC' in self.argDB:
695 if ('with-cxx' in self.argDB and self.argDB['with-cxx'] != '0') or 'CXX' in self.argDB:
697 if ('with-fc' in self.argDB and self.argDB['with-fc'] != '0') or 'FC' in self.argDB:
699 if self.argDB['download-mpich'] or self.argDB['download-openmpi']:
701 if 'with-mpi-include' in self.argDB and self.argDB['with-mpi-include']:
703 if 'with-mpi' in self.argDB and self.argDB['with-mpi'] and self.argDB['with-mpi-compilers']:
737 …fault HC used by the DC is ancient and PETSc uses a different HC (e.g., through --with-cxx=...)."""
739 setHostFlag = '-ccbin'
759 … the CXX dialect supported by the compiler (language) [and corresponding compiler option - if any].
762 -with-<lang>-dialect can take options:
772 - if needed, appends the relevant CXX dialect flag to <lang> compiler flags
773 - self.cxxDialectRange = (minSupportedDialect,maxSupportedDialect) (e.g. ('c++11','c++14'))
774 - self.addDefine('HAVE_{LANG}_DIALECT_CXX{DIALECT_NUM}',1) for every supported dialect
775 - self.lang+'dialect' = 'c++'+maxDialectNumber (e.g. 'c++14') but ONLY if the user
779 - The user has set both the --with-dialect=[...] configure options and -std=[...] in their
781 - The combination of specifically requested packages cannot all be compiled with the same flag
782 - An unknown C++ dialect is provided
788 - The compiler does not support at minimum -std=c++11
815 auto trailing(int x) -> int { return x+2; }
889 auto lmbd = [=, *this] { std::cout << i << " " << this->var << std::endl; };
928 … concept Hashable = requires(T a) { { std::hash<T>{}(a) } -> std::convertible_to<std::size_t>; };
950 stdflag_base = '-std:'
952 stdflag_base = '-Qstd='
954 stdflag_base = '-std='
958 …self.logPrint('checkCxxDialect: PETSc believes compiler ({compiler}) {isgnuish} gnu-ish'.format(co…
972 configureArg = lang.join(['with-','-dialect'])
980 …self.logPrint('checkCxxDialect: configure option after sanitization: --{opt}={val}'.format(opt=con…
1007 sanitized = langDialectFromFlags[-1].lower().replace(stdflag_base,'')
1012 …tion {opt}'.format(flagdialect=langDialectFromFlags,compiler=compiler,opt='--'+configureArg+'='+wi…
1014 …--{opt}={sanitized} if you really want to use that value, otherwise remove {flag} from compiler fl…
1045 …supported, PETSc only tests up to C++{maxver}. Remove -std=[...] from compiler flags and/or omit -…
1048 minDialect,maxDialect = 0,-1
1054 if maxDialect == -1:
1056 ver = int(withLangDialect[-2:])
1065 …mess += ' (you have explicitly requested --{}={}). Remove this flag and let configure choose the m…
1075 compareFunction = lambda x,y: x[-2:] > y[-2:]
1078 compareFunction = lambda x,y: x == 'NONE' or x[-2:] < y[-2:]
1087 packageBlame = '\n'.join('\t- '+s for s in packageRanges[packageBound])
1094 'Has {kind} bound of -std={packdlct}'
1101 '\tHas {kind} bound of -std={packdlct}, using package requirement -std={packdlct}'
1120 # -std=gnu++17
1121 # -std=c++17
1122 # -std=gnu++14
1127 '\n'.join(['checkCxxDialect: Have potential flag pool:']+['\t - '+f for f,_ in flagPool])
1143 if index == len(flagPool)-1:
1146 '{lang} compiler ({compiler}) appears non-compliant with C++{ver} or didn\'t accept:',
1148 '- '+(f[:-2] if f.startswith('(NO FLAG)') else f) for f,_ in flagPool[:index+1]
1159 '\n'.join('- '+s for s in packDialects[minPackDialect]),
1162 dialectNum = minPackDialect[-2:]
1173 …'Note, you have explicitly requested --{}={}. If you do not need C++{ver}, then remove this flag a…
1174 … consulting your compilers user manual. There may be other flags (e.g. \'--gcc-toolchain\') you mu…
1201 if dlct.num > flag[-2:]:
1208 setattr(self,lang+'dialect','c++'+dialects[maxDialect-1].num)
1225 …essages do not indicate failure of the compiler you can rerun with the option --ignoreLinkOutput=1'
1230 self.LIBS += ' -lpetsc-ufod4vtr9mqHvKIQiVAm'
1241 if not self.argDB['with-batch']:
1245 …bmit jobs you will need to configure using ./configure with the additional option --with-batch. ',
1249 msg = '\n'.join((msg,'See https://petsc.org/release/faq/#error-libimf'))
1255 …'''For Cray Intel KNL systems returns the underlying compiler line used by the wrapper compiler if…
1256 …'''This removes all the KNL specific options allowing the generated binary to run on the front-end…
1258 '''make process. This does not work for the Cray compiler module, only intel and gcc'''
1260 …(output,error,status) = self.executeShellCommand(compiler+' -craype-verbose',checkCommand = script…
1265 for i in output[1:-1]:
1266 if i.find('mic') > -1 or i.find('knl') > -1 or i.find('KNL') > -1:
1269 if i.startswith('-L') or i.startswith('-l') or i.startswith('-Wl'):
1278 …'''For Cray Intel KNL systems returns the underlying linker options used by the wrapper compiler i…
1279 …(output,error,status) = self.executeShellCommand(compiler+' -craype-verbose',checkCommand = script…
1283 for i in output[1:-1]:
1284 if i.find('mic') > -1 or i.find('knl') > -1 or i.find('KNL') > -1:
1287 if i.find('darshan') > -1:
1290 if i.find('static') > -1:
1292 if i.startswith('-I') or i.startswith('-D'):
1295 if i.startswith('-lsci_gnu'):
1306 if self.argDB['download-mpich']: mesg ='with downloaded MPICH'
1307 elif self.argDB['download-openmpi']: mesg ='with downloaded Open MPI'
1310 elif 'with-cc' in self.argDB:
1311 yield self.argDB['with-cc']
1312 …raise RuntimeError('C compiler you provided with -with-cc='+self.argDB['with-cc']+' cannot be foun…
1315 …raise RuntimeError('C compiler you provided with -CC='+self.argDB['CC']+' cannot be found or does …
1316 …elif self.useMPICompilers() and 'with-mpi-dir' in self.argDB and os.path.isdir(os.path.join(self.a…
1318 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpincc')
1319 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpiicc')
1320 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpicc')
1321 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpcc')
1322 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'hcc')
1323 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpcc_r')
1325 …appers in '+self.argDB['with-mpi-dir']+'/bin cannot be found or do not work. See https://petsc.org…
1327 if self.useMPICompilers() and 'with-mpi-dir' in self.argDB:
1328 …# if it gets here this means that self.argDB['with-mpi-dir']/bin does not exist so we should not s…
1330 …th-mpi-dir'], 'bin')+ ' dir does not exist! Skipping check for MPI compilers due to potentially in…
1332 self.argDB['with-mpi-compilers'] = 0
1371 output = self.executeShellCommand(compiler + ' -show', log = self.log)[0]
1373 self.logPrint('-show option failed for MPI compiler wrapper '+compiler)
1374 …self.logPrint(' MPI compiler wrapper '+compiler+' is likely incorrect.\n Use --with-mpi-dir to in…
1379 if 'with-cc' in self.argDB and self.argDB['with-cc'] == '0':
1380 … raise RuntimeError('A functional C compiler is necessary for configure, cannot use --with-cc=0')
1396 (output,error,status) = self.executeShellCommand(self.CC+' --version', log = self.log)
1400 … if self.isDarwin(self.log) and self.isARM(self.log) and output.find('x86_64-apple-darwin') > -1:
1401 …rror('Running on a macOS ARM system but your compilers are configured for Intel processors\n' + ou…
1403 …(output, error, status) = config.base.Configure.executeShellCommand(self.CC+' -v | head -n 20', lo…
1406 …self.logPrintWarning('Intel compiler being used with gcc 4.8.5 compatibility, failures may occur. …
1409 self.argDB['with-mpi-compilers'] = 1
1413 '''Determines the C preprocessor from --with-cpp, then CPP, then the C compiler'''
1414 if 'with-cpp' in self.argDB:
1415 yield self.argDB['with-cpp']
1419 yield self.CC+' -E'
1420 yield self.CC+' --use cpp32'
1438 '''Determine the CUDA compiler using CUDAC, then --with-cudac
1439 - Any given category can be excluded'''
1443 elif 'with-cudac' in self.argDB:
1444 yield self.argDB['with-cudac']
1445 …raise RuntimeError('CUDA compiler you provided with -with-cudac='+self.argDB['with-cudac']+' canno…
1448 …raise RuntimeError('CUDA compiler you provided with -CUDAC='+self.argDB['CUDAC']+' cannot be found…
1449 elif 'with-cuda-dir' in self.argDB:
1450 nvccPath = os.path.join(self.argDB['with-cuda-dir'], 'bin','nvcc')
1454 yield os.path.join('/Developer','NVIDIA','CUDA-6.5','bin','nvcc')
1467 self.executeShellCommand(self.CUDAC+' --version', log = self.log)
1477 '''Determines the CUDA preprocessor from --with-cudapp, then CUDAPP, then the CUDA compiler'''
1478 if 'with-cudacpp' in self.argDB:
1479 yield self.argDB['with-cudapp']
1484 yield self.CUDAC+' -E'
1501 '''Determine the HIP compiler using HIPC, then --with-hipc
1502 - Any given category can be excluded'''
1506 elif 'with-hipc' in self.argDB:
1507 yield self.argDB['with-hipc']
1508 …raise RuntimeError('HIPC compiler you provided with -with-hipc='+self.argDB['with-hipc']+' cannot …
1511 …raise RuntimeError('HIP compiler you provided with -HIPC='+self.argDB['HIPC']+' cannot be found or…
1512 elif 'with-hip-dir' in self.argDB:
1513 hipPath = os.path.join(self.argDB['with-hip-dir'], 'bin','hipcc')
1528 self.executeShellCommand(self.HIPC+' --version', log = self.log)
1538 '''Determines the HIP preprocessor from --with-hippp, then HIPPP, then the HIP compiler'''
1539 if 'with-hipcpp' in self.argDB:
1540 yield self.argDB['with-hippp']
1545 yield self.HIPC+' -E'
1562 '''Determine the SYCL compiler using SYCLC, then --with-syclc
1563 - Any given category can be excluded'''
1567 elif 'with-syclc' in self.argDB:
1568 yield self.argDB['with-syclc']
1569 …raise RuntimeError('SYCLC compiler you provided with -with-syclxx='+self.argDB['with-syclxx']+' ca…
1572 …raise RuntimeError('SYCLC compiler you provided with -SYCLC='+self.argDB['SYCLC']+' cannot be foun…
1573 elif 'with-sycl-dir' in self.argDB:
1574 syclPath = os.path.join(self.argDB['with-sycl-dir'], 'bin','dpcpp')
1586 self.executeShellCommand(self.SYCLC+' --version', log = self.log)
1595 '''Determines the SYCL preprocessor from --with-syclpp, then SYCLPP, then the SYCL compiler'''
1596 if 'with-syclpp' in self.argDB:
1597 yield self.argDB['with-syclpp']
1602 yield self.SYCLC +' -E'
1623 if self.argDB['download-mpich']: mesg ='with downloaded MPICH'
1624 elif self.argDB['download-openmpi']: mesg ='with downloaded Open MPI'
1627 elif 'with-c++' in self.argDB:
1628 raise RuntimeError('Keyword --with-c++ is WRONG, use --with-cxx')
1629 if 'with-CC' in self.argDB:
1630 raise RuntimeError('Keyword --with-CC is WRONG, use --with-cxx')
1632 if 'with-cxx' in self.argDB:
1633 …if self.argDB['with-cxx'] == 'gcc': raise RuntimeError('Cannot use C compiler gcc as the C++ compi…
1634 yield self.argDB['with-cxx']
1635 …raise RuntimeError('C++ compiler you provided with -with-cxx='+self.argDB['with-cxx']+' cannot be …
1638 …raise RuntimeError('C++ compiler you provided with -CXX='+self.argDB['CXX']+' cannot be found or d…
1639 …elif self.usedMPICompilers and 'with-mpi-dir' in self.argDB and os.path.isdir(os.path.join(self.ar…
1640 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpinc++')
1641 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpiicpc')
1642 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpicxx')
1643 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'hcp')
1644 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpic++')
1646 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpiCC')
1647 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpCC_r')
1648 …rovided with -with-mpi-dir='+self.argDB['with-mpi-dir']+' cannot be found or does not work. See ht…
1720 self.executeShellCommand(self.CXX+' --version', log = self.log)
1727 '''Determines the Cxx preprocessor from CXXPP, then --with-cxxpp, then the Cxx compiler'''
1728 if 'with-cxxpp' in self.argDB:
1729 yield self.argDB['with-cxxpp']
1733 yield self.CXX+' -E'
1734 yield self.CXX+' --use cpp32'
1751 …t('MPI installation '+self.getCompiler()+' is likely incorrect.\n Use --with-mpi-dir to indicate …
1761 if self.argDB['download-mpich']: mesg ='with downloaded MPICH'
1762 elif self.argDB['download-openmpi']: mesg ='with downloaded Open MPI'
1765 elif 'with-fc' in self.argDB:
1766 yield self.argDB['with-fc']
1767 …raise RuntimeError('Fortran compiler you provided with --with-fc='+self.argDB['with-fc']+' cannot …
1771 …raise RuntimeError('Fortran compiler you provided with -FC='+self.argDB['FC']+' cannot be found or…
1772 …elif self.usedMPICompilers and 'with-mpi-dir' in self.argDB and os.path.isdir(os.path.join(self.ar…
1773 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpinfort')
1774 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpiifort')
1775 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpif90')
1776 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpf90')
1777 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpxlf95_r')
1778 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpxlf90_r')
1779 yield os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpxlf_r')
1780 if os.path.isfile(os.path.join(self.argDB['with-mpi-dir'], 'bin', 'mpif90')):
1781 …--with-mpi-dir='+self.argDB['with-mpi-dir']+' cannot be found or does not work.\nRun with --with-f…
1816 …n' # On OpenBSD, the GFortran executable is named egfortran, https://fortran-lang.org/learn/os_set…
1832 if 'with-fc' in self.argDB and self.argDB['with-fc'] == '0':
1850 self.executeShellCommand(self.FC+' --version', log = self.log)
1856 '''Determines the Fortran preprocessor from FPP, then --with-fpp, then the Fortran compiler'''
1857 if 'with-fpp' in self.argDB:
1858 yield self.argDB['with-fpp']
1862 yield self.FC+' -E'
1863 yield self.FC+' --use cpp32'
1880 …t('MPI installation '+self.getCompiler()+' is likely incorrect.\n Use --with-mpi-dir to indicate …
1917 … 'warning: -commons use_dylibs is no longer supported, using error treatment instead',
1918 'warning: -bind_at_load is deprecated on macOS',
1946 self.log.write('Added to '+self.language[-1]+' compiler flag '+flagsArg+': '+flag+'\n')
1961 self.log.write('Added to '+self.language[-1]+' preprocessor flag '+flagsArg+': '+flag+'\n')
1996 with self.extraCompilerFlags(['-Wunknown-pragmas']) as skipFlags:
2003 if self.language[-1] == 'CUDA':
2004 yield '-Xcompiler -fPIC'
2005 yield '-fPIC'
2008 PICFlags = ['-fPIC']
2010 PICFlags = ['-qPIC']
2012 PICFlags = ['-PIC','-qPIC','-KPIC','-fPIC','-fpic']
2014 output = self.executeShellCommand(self.getCompiler() + ' -show', log = self.log)[0]
2016 …self.logPrint('Skipping checking MPI compiler command for PIC flag since MPI compiler -show causes…
2021 if output.find(' '+i+' ') > -1:
2032 … useSharedLibraries = 'with-shared-libraries' in self.argDB and self.argDB['with-shared-libraries']
2033 myLanguage = self.language[-1]
2034 if not self.argDB['with-pic'] and not useSharedLibraries:
2037 if self.argDB['with-pic'] and not useSharedLibraries:
2039 …# to fix it the capability to build shared libraries must be enabled in configure if --with-pic=tr…
2041 … flags if shared libraries is turned off\nEither run using --with-shared-libraries or --with-pic=0…
2084 …for f in ['-Wno-implicit-int', '-Wno-int-conversion', '-Wno-implicit-function-declaration', '-Wno-…
2089 '''check for large file support with 64-bit offset'''
2090 if not self.argDB['with-large-file-io']:
2099 self.addCompilerFlag('-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64',compilerOnly=1)
2101 … self.logPrint('Error adding ' +language+ ' flags -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64')
2103 self.logPrint('Rejected ' +language+ ' flags -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64')
2115 flag = '-a'
2125 if 'with-ar' in self.argDB:
2126 defaultAr = self.argDB['with-ar']
2131 if 'with-ranlib' in self.argDB:
2132 defaultRanlib = self.argDB['with-ranlib']
2138 …raise RuntimeError('The archiver set --with-ar="'+defaultAr+'" is broken or incompatible with the …
2141 …eError('The archiver set --with-ar="'+defaultAr+'" is broken or incompatible with the ranlib set (…
2144 …raise RuntimeError('The archiver set --AR="'+envAr+'" is broken or incompatible with the ranlib se…
2147 …ntimeError('The archiver set --AR="'+envAr+'" is broken or incompatible with the ranlib set (perha…
2151 …raise RuntimeError('You set a value for --with-ar='+defaultAr+'", but '+defaultAr+' cannot be used…
2155 …raise RuntimeError('You set a value for -AR="'+envAr+'" (perhaps in your environment), but '+envAr…
2161 …raise RuntimeError('You set --with-ranlib="'+defaultRanlib+'", but '+defaultRanlib+' cannot be use…
2167 …raise RuntimeError('You set -RANLIB="'+envRanlib+'" (perhaps in your environment), but '+defaultRa…
2172 yield ('ar',self.getArchiverFlags('ar'),'ranlib -c')
2175 # IBM with 64-bit pointers
2176 yield ('ar','-X64 '+self.getArchiverFlags('ar'),'ranlib -c')
2177 yield ('ar','-X64 '+self.getArchiverFlags('ar'),'ranlib')
2178 yield ('ar','-X64 '+self.getArchiverFlags('ar'),'true')
2204 …raise RuntimeError('Ranlib is not functional with your archiver. Try --with-ranlib=true if ranlib…
2223 self.LIBS = '-L'+self.tmpDir+' -lconf1 ' + oldLibs
2240 if 'with-ar' in self.argDB:
2241 raise RuntimeError('Archiver set with --with-ar='+self.argDB['with-ar']+' does not exist')
2243 … raise RuntimeError('Could not find a suitable archiver. Use --with-ar to specify an archiver.')
2283 language = self.language[-1]
2287 if not self.argDB['with-shared-libraries']:
2294 if 'with-shared-ld' in self.argDB:
2295 yield (self.argDB['with-shared-ld'], [], 'so')
2299 if 'with-shared-ld' in self.argDB:
2300 …yield (self.argDB['with-shared-ld'], ['-dynamiclib', '-undefined dynamic_lookup', '-no_compact_unw…
2302 … yield (self.CXX, ['-dynamiclib', '-undefined dynamic_lookup', '-no_compact_unwind'], 'dylib')
2303 yield (self.CC, ['-dynamiclib', '-undefined dynamic_lookup', '-no_compact_unwind'], 'dylib')
2307 yield (self.CXX, ['-qmkshrobj'], 'so')
2308 yield (self.CXX, ['-shared'], 'so')
2309 yield (self.CXX, ['-dynamic'], 'so')
2310 yield (self.CC, ['-shared'], 'dll')
2313 yield (self.CC, ['-qmkshrobj'], 'so')
2314 yield (self.CC, ['-shared'], 'so')
2315 yield (self.CC, ['-dynamic'], 'so')
2316 yield (self.CC, ['-shared'], 'dll')
2320 yield (self.CXX, ['-LD'], 'dll')
2321 yield (self.CC, ['-LD'], 'dll')
2325 yield (self.CXX, ['-G'], 'so')
2326 yield (self.CC, ['-G'], 'so')
2327 …# If user does not explicitly enable shared-libraries - disable shared libraries and default to st…
2328 if not 'with-shared-libraries' in self.framework.clArgDB:
2329 self.argDB['with-shared-libraries'] = 0
2345 self.logPrint('Trying '+self.language[-1]+' compiler flag '+picFlag)
2364 # using printf appears to correctly identify non-pic code on X86_64
2368 self.LIBS += ' -L'+self.tmpDir+' -lconftest'
2376 …self.logPrint('Rejected '+self.language[-1]+' compiler flag '+picFlag+' because it was not compati…
2397 self.logPrint('Rejecting '+self.language[-1]+' linker flag '+flag+' due to \n'+output)
2399 self.logPrint('Valid '+self.language[-1]+' linker flag '+flag)
2420 …ldTestFlags = ['-Wl,-bind_at_load', '-Wl,-commons,use_dylibs', '-Wl,-search_paths_first', '-Wl,-no…
2421 if self.LDFLAGS.find('-Wl,-ld_classic') < 0:
2422 ldTestFlags.append('-Wl,-no_warn_duplicate_libraries')
2446 …for testFlag in ['-Qwd10161']: #Warning for Intel icl, there appear to be no way to remove warni…
2458 - IRIX: -rpath
2459 - Linux, OSF: -Wl,-rpath,
2460 - Solaris: -R
2461 - FreeBSD: -Wl,-R,'''
2474 flag = '-L'
2477 self.logPrint('Cygwin detected! disabling -rpath test.')
2479 …# test '-R' before '-rpath' as sun compilers [c,fortran] don't give proper errors with wrong optio…
2481 testFlags = ['-Wl,-rpath,', '-R','-rpath ' , '-Wl,-R,']
2483 testFlags = ['-Wl,-rpath,']
2484 …# test '-R' before '-Wl,-rpath' for SUN compilers [as cc on linux accepts -Wl,-rpath, but f90 & C…
2486 testFlags.insert(0,'-R')
2500 - Mac OSX requires an explicit reference to libc for shared linking'''
2512 self.LIBS += '-lc '
2525 if 'with-dynamic-ld' in self.argDB:
2526 yield (self.argDB['with-dynamic-ld'], [], 'so')
2529 if 'with-dynamic-ld' in self.argDB:
2530 yield (self.argDB['with-dynamic-ld'], ['-dynamiclib -undefined dynamic_lookup'], 'dylib')
2532 yield (self.CXX, ['-dynamiclib -undefined dynamic_lookup'], 'dylib')
2533 yield (self.CC, ['-dynamiclib -undefined dynamic_lookup'], 'dylib')
2539 yield (self.CXX, ['-shared'], 'so')
2541 yield (self.CC, ['-shared'], 'so')
2573 return -1;
2577 return -1;
2581 return -1;
2665 '''Check if --with-mpi-dir is used along with CC CXX or FC compiler options.
2666 This usually prevents mpi compilers from being used - so issue a warning'''
2668 if 'with-mpi-dir' in self.argDB and self.argDB['with-mpi-compilers']:
2669 optcplrs = [(['with-cc','CC'],['mpincc','mpiicc','mpicc','mpcc','hcc','mpcc_r']),
2670 … (['with-fc','FC'],['mpinfort','mpiifort','mpif90','mpxlf95_r','mpxlf90_r','mpxlf_r','mpf90']),
2671 (['with-cxx','CXX'],['mpinc++','mpiicpc','mpicxx','hcp','mpic++','mpiCC','mpCC_r'])]
2677 …for mpicplr in [os.path.join(self.argDB['with-mpi-dir'], 'bin', cplr),os.path.join(self.argDB['wit…
2679 …msg = '--'+opt+'='+self.argDB[opt]+' is specified along with --with-mpi-dir='+self.argDB['with-mpi…
2680 …ompiler to select and use! Please specify either [mpi] compilers or --with-mpi-dir - but not both!…
2681 …In most cases, specifying --with-mpi-dir - and not explicitly listing compilers could be preferabl…
2687 if 'with-mpi-dir' in self.argDB:
2688 libdir = os.path.join(self.argDB['with-mpi-dir'], 'lib')
2689 if os.path.exists(os.path.join(libdir,'libopen-rte.so')):
2701 …if envVal in self.framework.clArgDB or (envVal in ignoreEnvCompilers and 'with-'+envVal.lower() in…
2704 elif self.argDB['with-environment-variables']:
2705 …self.logPrintWarning(msg+'Using it! Use "./configure --disable-environment-variables" to NOT use t…
2712 '''Set configure compilers from the environment, from -with-environment-variables'''
2713 if 'with-environment-variables' in self.framework.clArgDB:
2761 argdbName = 'with-' + compilerName.casefold()
2764 # compiler was explicitly disabled, i.e. --with-cxx=0
2783 # user explicitly enabled a compiler, e.g. --with-cxx=clang++, so the fact
2787 …'Note, you have explicitly requested --{}={}. If you don\'t need {}, or that specific compiler, re…