autotools : set Executable() in dependent modules

This commit is contained in:
alalazo
2016-06-26 17:36:33 +02:00
parent 055f7f4ab6
commit acd9014553
3 changed files with 56 additions and 15 deletions

View File

@@ -25,17 +25,28 @@
from spack import *
class Libtool(Package):
"""libtool -- library building part of autotools"""
homepage = "https://www.gnu.org/software/libtool/"
url = "http://ftpmirror.gnu.org/libtool/libtool-2.4.2.tar.gz"
"""
libtool -- library building part of autotools
"""
homepage = 'https://www.gnu.org/software/libtool/'
url = 'http://ftpmirror.gnu.org/libtool/libtool-2.4.2.tar.gz'
version('2.4.6' , 'addf44b646ddb4e3919805aa88fa7c5e')
version('2.4.2' , 'd2f3b7d4627e69e13514a40e72a24d50')
version('2.4.6', 'addf44b646ddb4e3919805aa88fa7c5e')
version('2.4.2', 'd2f3b7d4627e69e13514a40e72a24d50')
depends_on('m4')
def _make_executable(self, name):
return Executable(join_path(self.prefix.bin, name))
def setup_dependent_package(self, module, dependent_spec):
# Automake is very likely to be a build dependency,
# so we add the tools it provides to the dependent module
executables = ['libtoolize', 'libtool']
for name in executables:
setattr(module, name, self._make_executable(name))
def install(self, spec, prefix):
configure("--prefix=%s" % prefix)
make()
make("install")