### this file is sourced not run

# source: james
TARBALL=arpack96.tar.gz
MD5SUM=fffaa970198b285676f4156cebc8626e 
SRC_URL=http://www.caam.rice.edu/software/ARPACK/SRC/$TARBALL
BUNDLE=

SLACKREQ='liblapack'
SLACKDESC='libarpack: libarpack 96 (Fortran eigenvalues library)  
libarpack:  
libarpack: ARPACK is a collection of Fortran77 subroutines designed to solve 
libarpack: large scale eigenvalue problems.  
libarpack: 
libarpack: 
libarpack: 
libarpack: 
libarpack: 
libarpack: 
libarpack: http://www.caam.rice.edu/software/ARPACK/
'

### default pkg_download
### default pkg_prepare
### default pkg_package
### build
pkg_build() {
	cd /tmp/ARPACK
	
	# patch broken etime: http://modb.oce.ulg.ac.be/mediawiki/index.php/Troubleshooting
	sed -i -e '/EXTERNAL.*ETIME/ s/^/*/' UTIL/second.f &&

	# we exclude BLAS and LAPACK from here as we've got good ones from liblapack
	rm -rf /usr/$LIBDIR/libarpack.a &&
	make $MAKEFLAGS lib home=$(pwd) BLASdir= LAPACKdir= \
	    ARPACKLIB=/usr/$LIBDIR/libarpack.a \
	    MAKE=$(which make) FC=gfortran FFLAGS="$CFLAGS -fPIC" &&
	    
	pkg_build_slackdesc
}

