silo: Make silo use AutotoolsPackage (#8551)
To benefit from updates to config.guess for newer architectures. More info: https://github.com/spack/spack/issues/2063
This commit is contained in:
		 Nick Forrington
					Nick Forrington
				
			
				
					committed by
					
						 Adam J. Stewart
						Adam J. Stewart
					
				
			
			
				
	
			
			
			 Adam J. Stewart
						Adam J. Stewart
					
				
			
						parent
						
							ae8645e27d
						
					
				
				
					commit
					259b1834f1
				
			| @@ -25,7 +25,7 @@ | |||||||
| from spack import * | from spack import * | ||||||
|  |  | ||||||
|  |  | ||||||
| class Silo(Package): | class Silo(AutotoolsPackage): | ||||||
|     """Silo is a library for reading and writing a wide variety of scientific |     """Silo is a library for reading and writing a wide variety of scientific | ||||||
|        data to binary, disk files.""" |        data to binary, disk files.""" | ||||||
|  |  | ||||||
| @@ -58,8 +58,14 @@ def flag_handler(self, name, flags): | |||||||
|             flags.append('-ldl') |             flags.append('-ldl') | ||||||
|         return (flags, None, None) |         return (flags, None, None) | ||||||
|  |  | ||||||
|     def install(self, spec, prefix): |     def configure_args(self): | ||||||
|  |         spec = self.spec | ||||||
|         config_args = [ |         config_args = [ | ||||||
|  |             '--with-hdf5=%s,%s' % (spec['hdf5'].prefix.include, | ||||||
|  |                                    spec['hdf5'].prefix.lib), | ||||||
|  |             '--with-zlib=%s,%s' % (spec['zlib'].prefix.include, | ||||||
|  |                                    spec['zlib'].prefix.lib), | ||||||
|  |             '--enable-install-lite-headers', | ||||||
|             '--enable-fortran' if '+fortran' in spec else '--disable-fortran', |             '--enable-fortran' if '+fortran' in spec else '--disable-fortran', | ||||||
|             '--enable-silex' if '+silex' in spec else '--disable-silex', |             '--enable-silex' if '+silex' in spec else '--disable-silex', | ||||||
|             '--enable-shared' if '+shared' in spec else '--disable-shared', |             '--enable-shared' if '+shared' in spec else '--disable-shared', | ||||||
| @@ -79,14 +85,4 @@ def install(self, spec, prefix): | |||||||
|             config_args.append('CXX=%s' % spec['mpi'].mpicxx) |             config_args.append('CXX=%s' % spec['mpi'].mpicxx) | ||||||
|             config_args.append('FC=%s' % spec['mpi'].mpifc) |             config_args.append('FC=%s' % spec['mpi'].mpifc) | ||||||
|  |  | ||||||
|         configure( |         return config_args | ||||||
|             '--prefix=%s' % prefix, |  | ||||||
|             '--with-hdf5=%s,%s' % (spec['hdf5'].prefix.include, |  | ||||||
|                                    spec['hdf5'].prefix.lib), |  | ||||||
|             '--with-zlib=%s,%s' % (spec['zlib'].prefix.include, |  | ||||||
|                                    spec['zlib'].prefix.lib), |  | ||||||
|             '--enable-install-lite-headers', |  | ||||||
|             *config_args) |  | ||||||
|  |  | ||||||
|         make() |  | ||||||
|         make('install') |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user