diff options
author | Adrian Petrescu | 2017-09-05 11:27:18 -0400 |
---|---|---|
committer | Adrian Petrescu | 2017-09-05 11:27:18 -0400 |
commit | 24902939dd309a25b62d1de2be8920e6cb505445 (patch) | |
tree | 742fa6fac83c9434cb93ceaaff9df4d3cdca8d28 | |
parent | a558cf8879bbef185f64c1d1b25dfc2345ecda61 (diff) | |
download | aur-24902939dd309a25b62d1de2be8920e6cb505445.tar.gz |
pkgrel 2: include mohex data files
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | PKGBUILD | 19 | ||||
-rw-r--r-- | mohex-paths.patch | 43 |
3 files changed, 62 insertions, 4 deletions
@@ -1,7 +1,7 @@ pkgbase = benzene-mohex pkgdesc = Computer Hex engine by UAlberta. Winner of 2015 ICGA Olympiad. pkgver = 1.0.1 - pkgrel = 1 + pkgrel = 2 url = http://benzene.sourceforge.net arch = i686 arch = x86_64 @@ -11,8 +11,10 @@ pkgbase = benzene-mohex depends = db source = https://github.com/apetresc/benzene/archive/v1.0.1.tar.gz source = https://github.com/apetresc/fuego/archive/v1.1.tar.gz + source = mohex-paths.patch md5sums = 517c202987706c6f3dd70dbf57fe67fa md5sums = 90a3e6c46f5a418f9fe5bdab46ca6b90 + md5sums = e4862df92f36e9f404617678cc2131c5 pkgname = benzene-mohex @@ -3,7 +3,7 @@ pkgname=benzene-mohex pkgver=1.0.1 -pkgrel=1 +pkgrel=2 pkgdesc='Computer Hex engine by UAlberta. Winner of 2015 ICGA Olympiad.' arch=('i686' 'x86_64') url='http://benzene.sourceforge.net' @@ -11,9 +11,18 @@ license=('GPL3') depends=('boost-libs' 'db') makedepends=('boost') source=("https://github.com/apetresc/benzene/archive/v$pkgver.tar.gz" - 'https://github.com/apetresc/fuego/archive/v1.1.tar.gz') + 'https://github.com/apetresc/fuego/archive/v1.1.tar.gz' + 'mohex-paths.patch') md5sums=('517c202987706c6f3dd70dbf57fe67fa' - '90a3e6c46f5a418f9fe5bdab46ca6b90') + '90a3e6c46f5a418f9fe5bdab46ca6b90' + 'e4862df92f36e9f404617678cc2131c5') + +prepare() { + cd $srcdir/benzene-$pkgver/ + patch -p1 -i $srcdir/mohex-paths.patch + mv share/ice-patterns.txt share/mohex-ice-patterns.txt + mv share/vc-captured-set.txt share/mohex-vc-captured-set.txt +} build() { cd fuego-1.1/ @@ -34,7 +43,11 @@ check() { package() { mkdir -p $pkgdir/usr/bin + mkdir -p $pkgdir/usr/local/share/benzene cp $srcdir/benzene-$pkgver/src/mohex/mohex $pkgdir/usr/bin/mohex + cp $srcdir/benzene-$pkgver/share/mohex-ice-patterns.txt $pkgdir/usr/local/share/benzene/ + cp $srcdir/benzene-$pkgver/share/mohex-vc-captured-set.txt $pkgdir/usr/local/share/benzene/ + cp $srcdir/benzene-$pkgver/share/mohex-patterns.txt $pkgdir/usr/local/share/benzene/ } diff --git a/mohex-paths.patch b/mohex-paths.patch new file mode 100644 index 000000000000..ea232d070d98 --- /dev/null +++ b/mohex-paths.patch @@ -0,0 +1,43 @@ +diff -ura benzene-1.0.1.old/share/Makefile.am benzene-1.0.1.new/share/Makefile.am +--- benzene-1.0.1.old/share/Makefile.am 2017-09-05 10:59:56.082342636 -0400 ++++ benzene-1.0.1.new/share/Makefile.am 2017-09-05 11:11:14.846424488 -0400 +@@ -1,6 +1,6 @@ + # data files to be installed in ${prefix}/share/benzene/ directory + dist_pkgdata_DATA = \ +-ice-patterns.txt \ ++mohex-ice-patterns.txt \ + induced-domination.txt \ + induced-equivalence.txt \ + induced-inferior.txt \ +@@ -9,6 +9,6 @@ + mohex-patterns.txt \ + swap-moves.txt \ + unique-probe.txt \ +-vc-captured-set.txt \ ++mohex-vc-captured-set.txt \ + vc-patterns.txt \ + mohex-cache-book.txt +diff -ura benzene-1.0.1.old/src/hex/ICEngine.cpp benzene-1.0.1.new/src/hex/ICEngine.cpp +--- benzene-1.0.1.old/src/hex/ICEngine.cpp 2017-09-05 10:59:56.109007956 -0400 ++++ benzene-1.0.1.new/src/hex/ICEngine.cpp 2017-09-05 11:00:22.281037283 -0400 +@@ -521,7 +521,7 @@ + /** Loads local patterns from "ice-pattern-file". */ + void ICEngine::LoadPatterns() + { +- m_patterns.LoadPatterns("ice-patterns.txt"); ++ m_patterns.LoadPatterns("mohex-ice-patterns.txt"); + } + + //---------------------------------------------------------------------------- +diff -ura benzene-1.0.1.old/src/hex/VCBuilder.cpp benzene-1.0.1.new/src/hex/VCBuilder.cpp +--- benzene-1.0.1.old/src/hex/VCBuilder.cpp 2017-09-05 10:59:56.112341121 -0400 ++++ benzene-1.0.1.new/src/hex/VCBuilder.cpp 2017-09-05 11:01:03.332395435 -0400 +@@ -44,7 +44,7 @@ + { + std::ifstream inFile; + try { +- std::string file = MiscUtil::OpenFile("vc-captured-set.txt", inFile); ++ std::string file = MiscUtil::OpenFile("mohex-vc-captured-set.txt", inFile); + LogConfig() << "VCBuilder: reading captured set patterns from '" + << file << "'.\n"; + } |