install GKlib headers along with METIS

This commit is contained in:
Denis Davydov 2016-03-24 20:23:13 +01:00
parent 38ea75e8ca
commit 7fb463abb9
2 changed files with 33 additions and 2 deletions

View file

@ -0,0 +1,22 @@
# HG changeset patch
# User Sean Farley <sean@mcs.anl.gov>
# Date 1332269671 18000
# Tue Mar 20 13:54:31 2012 -0500
# Node ID b95c0c2e1d8bf8e3273f7d45e856f0c0127d998e
# Parent 88049269953c67c3fdcc4309bf901508a875f0dc
cmake: add gklib headers to install into include
diff -r 88049269953c -r b95c0c2e1d8b libmetis/CMakeLists.txt
Index: libmetis/CMakeLists.txt
===================================================================
--- a/libmetis/CMakeLists.txt Tue Mar 20 13:54:29 2012 -0500
+++ b/libmetis/CMakeLists.txt Tue Mar 20 13:54:31 2012 -0500
@@ -12,6 +12,8 @@ endif()
if(METIS_INSTALL)
install(TARGETS metis
LIBRARY DESTINATION lib
RUNTIME DESTINATION lib
ARCHIVE DESTINATION lib)
+ install(FILES gklib_defs.h DESTINATION include)
+ install(FILES gklib_rename.h DESTINATION include)
endif()

View file

@ -24,7 +24,7 @@
##############################################################################
from spack import *
import glob
class Metis(Package):
"""
@ -49,6 +49,8 @@ class Metis(Package):
depends_on('gdb', when='+gdb')
patch('install_gklib_defs_rename.patch')
def install(self, spec, prefix):
options = []
@ -81,3 +83,10 @@ def install(self, spec, prefix):
cmake(source_directory, *options)
make()
make("install")
# install GKlib headers, which will be needed for ParMETIS
GKlib_dist = join_path(prefix.include,'GKlib')
mkdirp(GKlib_dist)
fs = glob.glob(join_path(source_directory,'GKlib',"*.h"))
for f in fs:
install(f, GKlib_dist)