diff options
author | Ondřej Čertík <ondrej@certik.us> | 2017-10-13 15:15:06 -0600 |
---|---|---|
committer | Christoph Junghans <christoph.junghans@gmail.com> | 2017-10-13 15:15:06 -0600 |
commit | 6c3184820aa1052016d92f7ff0419b8085d8ad14 (patch) | |
tree | 6ff1278b5a60c37838157f7b6748549dcf43f748 /var | |
parent | 3c7dd367f809a70c9abc5d923857cebe40f89c41 (diff) | |
download | spack-6c3184820aa1052016d92f7ff0419b8085d8ad14.tar.gz spack-6c3184820aa1052016d92f7ff0419b8085d8ad14.tar.bz2 spack-6c3184820aa1052016d92f7ff0419b8085d8ad14.tar.xz spack-6c3184820aa1052016d92f7ff0419b8085d8ad14.zip |
Use cflags instead of the args variable (#5756)
That way the user can still append things to CFLAGS.
Diffstat (limited to 'var')
-rw-r--r-- | var/spack/repos/builtin/packages/m4/package.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/var/spack/repos/builtin/packages/m4/package.py b/var/spack/repos/builtin/packages/m4/package.py index 2523745e58..267b9c3784 100644 --- a/var/spack/repos/builtin/packages/m4/package.py +++ b/var/spack/repos/builtin/packages/m4/package.py @@ -48,11 +48,13 @@ class M4(AutotoolsPackage): spec = self.spec args = ['--enable-c++'] + # CFLAGS handling + cflags = copy.deepcopy(optflags[self.spec.compiler.name]) if spec.satisfies('%clang') and not spec.satisfies('platform=darwin'): - args.append('CFLAGS=-rtlib=compiler-rt') - + cflags.append('-rtlib=compiler-rt') if spec.satisfies('%intel'): - args.append('CFLAGS=-no-gcc') + cflags.append('-no-gcc') + args.append('CFLAGS = {0}'.format(' '.join(cflags))) if '+sigsegv' in spec: args.append('--with-libsigsegv-prefix={0}'.format( |