From cf93f49462a319be4d6b6f263725297686612299 Mon Sep 17 00:00:00 2001 From: "Adam J. Stewart" Date: Mon, 8 May 2017 00:04:52 -0500 Subject: Fix PGI compiler detection on PowerPC (#4150) --- lib/spack/spack/compilers/pgi.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/lib/spack/spack/compilers/pgi.py b/lib/spack/spack/compilers/pgi.py index 146c153041..ed8bad1a9b 100644 --- a/lib/spack/spack/compilers/pgi.py +++ b/lib/spack/spack/compilers/pgi.py @@ -61,12 +61,20 @@ class Pgi(Compiler): @classmethod def default_version(cls, comp): - """The '-V' option works for all the PGI compilers. + """The ``-V`` option works for all the PGI compilers. Output looks like this:: pgcc 15.10-0 64-bit target on x86-64 Linux -tp sandybridge The Portland Group - PGI Compilers and Tools Copyright (c) 2015, NVIDIA CORPORATION. All rights reserved. + + on x86-64, and:: + + pgcc 17.4-0 linuxpower target on Linuxpower + PGI Compilers and Tools + Copyright (c) 2017, NVIDIA CORPORATION. All rights reserved. + + on PowerPC. """ return get_compiler_version( - comp, '-V', r'pg[^ ]* ([^ ]+) \d\d\d?-bit target') + comp, '-V', r'pg[^ ]* ([0-9.-]+) [^ ]+ target on ') -- cgit v1.2.3-60-g2f50