From ba69ebc5f7831562f0fb83fac6ea68e023bb907f Mon Sep 17 00:00:00 2001 From: wenlibin02 Date: Mon, 28 Oct 2019 11:31:10 +0800 Subject: [PATCH] Add dependency and patch for perl-dbfile (#13261) * Add dependency and patch perl-dbfile There are two problems for the building of `perl-dbfile`: 1) this package depends on the package `berkeley-db` 2) fix the building using a patch, which locates the position of `berkeley-db` and modify the configuration file for the building * Update and reformat the script package.py * Simplify the patch * Update package.py * Update package.py --- var/spack/repos/builtin/packages/perl-dbfile/package.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/var/spack/repos/builtin/packages/perl-dbfile/package.py b/var/spack/repos/builtin/packages/perl-dbfile/package.py index c56d98f842..19cc9410c1 100644 --- a/var/spack/repos/builtin/packages/perl-dbfile/package.py +++ b/var/spack/repos/builtin/packages/perl-dbfile/package.py @@ -20,3 +20,8 @@ class PerlDbfile(PerlPackage): version('1.840', sha256='b7864707fad0f2d1488c748c4fa08f1fb8bcfd3da247c36909fd42f20bfab2c4') depends_on('perl-extutils-makemaker', type='build') + depends_on('berkeley-db', type='build') + + def patch(self): + filter_file('/usr/local/BerkeleyDB', + self.spec['berkeley-db'].prefix, 'config.in')