diff options
author | Geoffrey Oxberry <goxberry@gmail.com> | 2018-09-14 15:53:25 -0700 |
---|---|---|
committer | Todd Gamblin <tgamblin@llnl.gov> | 2018-09-14 15:53:25 -0700 |
commit | 69a9a3291af5889e50c0300622da39601eb11a63 (patch) | |
tree | eee3c0b801850d33b3fcea921976f1e27665630a | |
parent | a76aa364819baf88d7bd45bad134f1de1e2012d6 (diff) | |
download | spack-69a9a3291af5889e50c0300622da39601eb11a63.tar.gz spack-69a9a3291af5889e50c0300622da39601eb11a63.tar.bz2 spack-69a9a3291af5889e50c0300622da39601eb11a63.tar.xz spack-69a9a3291af5889e50c0300622da39601eb11a63.zip |
ipopt: add debug variant (#9223)
-rw-r--r-- | var/spack/repos/builtin/packages/ipopt/package.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/ipopt/package.py b/var/spack/repos/builtin/packages/ipopt/package.py index 2b92d958ed..33a818bd89 100644 --- a/var/spack/repos/builtin/packages/ipopt/package.py +++ b/var/spack/repos/builtin/packages/ipopt/package.py @@ -47,6 +47,8 @@ class Ipopt(AutotoolsPackage): description="Build with Coin Harwell Subroutine Libraries") variant('metis', default=False, description="Build with METIS partitioning support") + variant('debug', default=False, + description="Build debug instead of optimized version") depends_on("blas") depends_on("lapack") @@ -100,4 +102,12 @@ class Ipopt(AutotoolsPackage): '--with-metis-lib=%s' % spec['metis'].libs.ld_flags, '--with-metis-incdir=%s' % spec['metis'].prefix.include]) + # The IPOPT configure file states that '--enable-debug' implies + # '--disable-shared', but adding '--enable-shared' overrides + # '--disable-shared' and builds a shared library with debug symbols + if '+debug' in spec: + args.append('--enable-debug') + else: + args.append('--disable-debug') + return args |