add static options for some libraries (#2876)

* add static options for some libraries

* make requested changes: add comments and use configure_args
This commit is contained in:
Jason Sarich
2017-01-24 13:48:01 -06:00
committed by Todd Gamblin
parent 7d3da2ebdc
commit 6e895c4ccc
5 changed files with 50 additions and 15 deletions

View File

@@ -186,6 +186,15 @@ def install(self, spec, prefix):
if '+shared' in spec:
options.append('-DSHARED:BOOL=ON')
else:
# Remove all RPATH options
# (RPATHxxx options somehow trigger cmake to link dynamically)
rpath_options = []
for o in options:
if o.find('RPATH') >= 0:
rpath_options.append(o)
for o in rpath_options:
options.remove(o)
if '+debug' in spec:
options.extend(['-DDEBUG:BOOL=ON',
'-DCMAKE_BUILD_TYPE:STRING=Debug'])