Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Spack
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
eic_tools
Spack
Commits
9cf1257b
Commit
9cf1257b
authored
8 years ago
by
Adam J. Stewart
Browse files
Options
Downloads
Patches
Plain Diff
Filter compilers
parent
deb4f919
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
var/spack/repos/builtin/packages/psi4/package.py
+24
-0
24 additions, 0 deletions
var/spack/repos/builtin/packages/psi4/package.py
with
24 additions
and
0 deletions
var/spack/repos/builtin/packages/psi4/package.py
+
24
−
0
View file @
9cf1257b
...
...
@@ -23,6 +23,7 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
from
spack
import
*
import
os
class
Psi4
(
Package
):
...
...
@@ -74,3 +75,26 @@ def install(self, spec, prefix):
make
()
# ctest()
make
(
'
install
'
)
self
.
filter_compilers
()
def
filter_compilers
(
self
):
"""
Run after install to tell the configuration files to
use the compilers that Spack built the package with.
If this isn
'
t done, they
'
ll have PLUGIN_CXX set to
Spack
'
s generic cxx. We want it to be bound to
whatever compiler it was built with.
"""
kwargs
=
{
'
ignore_absent
'
:
True
,
'
backup
'
:
False
,
'
string
'
:
True
}
cc_files
=
[
'
bin/psi4-config
'
]
cxx_files
=
[
'
bin/psi4-config
'
,
'
include/psi4/psiconfig.h
'
]
for
filename
in
cc_files
:
filter_file
(
os
.
environ
[
'
CC
'
],
self
.
compiler
.
cc
,
os
.
path
.
join
(
self
.
prefix
,
filename
),
**
kwargs
)
for
filename
in
cxx_files
:
filter_file
(
os
.
environ
[
'
CXX
'
],
self
.
compiler
.
cxx
,
os
.
path
.
join
(
self
.
prefix
,
filename
),
**
kwargs
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment