diff options
author | David Wells | 2018-05-13 17:48:04 -0400 |
---|---|---|
committer | David Wells | 2018-05-13 17:48:04 -0400 |
commit | 8d7c9489256041adfa0d60a18ecd5e1957937bfc (patch) | |
tree | 8189235e750f747799ac27a98e7a4540ac6b8316 | |
parent | 1a474f5a722124bce9610ad1f9bd5209814db249 (diff) | |
download | aur-8d7c9489256041adfa0d60a18ecd5e1957937bfc.tar.gz |
Fix the quicktests.
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | PKGBUILD | 28 | ||||
-rw-r--r-- | scalapack-quick-test.patch | 44 |
3 files changed, 66 insertions, 12 deletions
@@ -1,7 +1,7 @@ pkgbase = deal-ii pkgdesc = An Open Source Finite Element Differential Equations Analysis Library pkgver = 9.0.0 - pkgrel = 1 + pkgrel = 2 url = http://www.dealii.org/ install = deal-ii.install arch = i686 @@ -32,7 +32,9 @@ pkgbase = deal-ii optdepends = suitesparse: A collection of sparse matrix libraries optdepends = zlib: Compression library implementing the deflate compression method found in gzip and PKZIP source = https://github.com/dealii/dealii/releases/download/v9.0.0/dealii-9.0.0.tar.gz - sha1sums = 1454485bd4ec4ad0252d87173e7fdbdf2ebb5d86 + source = scalapack-quick-test.patch + sha1sums = ac9816053217610d622bb4f056200a46d27fcf32 + sha1sums = 9526ebad9098a9e9140b033cd919d73901215d6f pkgname = deal-ii @@ -4,7 +4,7 @@ pkgname=deal-ii _realname=dealii pkgver=9.0.0 -pkgrel=1 +pkgrel=2 pkgdesc="An Open Source Finite Element Differential Equations Analysis Library" arch=("i686" "x86_64") url="http://www.dealii.org/" @@ -36,8 +36,10 @@ optdepends=( ) makedepends=('cmake') install=deal-ii.install -source=(https://github.com/dealii/dealii/releases/download/v$pkgver/${_realname}-$pkgver.tar.gz) -sha1sums=('1454485bd4ec4ad0252d87173e7fdbdf2ebb5d86') +source=(https://github.com/dealii/dealii/releases/download/v$pkgver/${_realname}-$pkgver.tar.gz + scalapack-quick-test.patch) +sha1sums=('ac9816053217610d622bb4f056200a46d27fcf32' + '9526ebad9098a9e9140b033cd919d73901215d6f') # where to install deal.II: change to something else (e.g., /opt/deal.II/) # if desired. @@ -65,8 +67,12 @@ build() { fi done - rm -rf "${srcdir}/build" - mkdir "${srcdir}/build" + # the 9.0.0 quicktest for scalapack relies on an unincluded header: + cd ${srcdir} + patch -p0 < ${srcdir}/scalapack-quick-test.patch + + # rm -rf "${srcdir}/build" + # mkdir "${srcdir}/build" cd "${srcdir}/build" # explicitly disallow bundled packages: this disables bundled copies of boost, @@ -111,11 +117,13 @@ build() { echo "export DEAL_II_DIR=$installation_prefix" > ./deal-ii.sh } -# TODO this crashes for reasons I do not fully understand: fix this. -# check() { -# cd "${srcdir}/build" -# make test -# } +check() { + cd "${srcdir}/build" + # make test cannot handle parallelism: spawned make instances read this + # which causes trouble. + unset MAKEFLAGS + make test +} package() { cd "${srcdir}/build" diff --git a/scalapack-quick-test.patch b/scalapack-quick-test.patch new file mode 100644 index 000000000000..e3b5733a3621 --- /dev/null +++ b/scalapack-quick-test.patch @@ -0,0 +1,44 @@ +--- dealii-9.0.0/tests/quick_tests/scalapack.cc ++++ dealii-9.0.0/tests/quick_tests/scalapack.cc +@@ -14,7 +14,6 @@ + // --------------------------------------------------------------------- + + #include "../tests.h" +-#include "../lapack/create_matrix.h" + + // adaptation of /scalapack/scalapack_02.cc to a quick test + +@@ -32,6 +31,33 @@ + #include <iostream> + + ++ ++template <typename FullMatrix> ++void create_spd (FullMatrix &A) ++{ ++ const unsigned int size = A.n(); ++ Assert (size == A.m(), ExcDimensionMismatch(size,A.m())); ++ ++ for (unsigned int i = 0; i < size; ++i) ++ for (unsigned int j = i; j < size; ++j) ++ { ++ const double val = random_value<typename FullMatrix::value_type>(); ++ Assert (val >= 0. && val <= 1., ++ ExcInternalError()); ++ if (i==j) ++ // since A(i,j) < 1 and ++ // a symmetric diagonally dominant matrix is SPD ++ A(i,j) = val + size; ++ else ++ { ++ A(i,j) = val; ++ A(j,i) = val; ++ } ++ } ++} ++ ++ ++ + template <typename NumberType> + void test(const unsigned int size, const unsigned int block_size) + { |