summaryrefslogtreecommitdiff
path: root/recipes/phalanx
diff options
context:
space:
mode:
authorDenys Dmytriyenko <denis@denix.org>2009-03-17 14:32:59 -0400
committerDenys Dmytriyenko <denis@denix.org>2009-03-17 14:32:59 -0400
commit709c4d66e0b107ca606941b988bad717c0b45d9b (patch)
tree37ee08b1eb308f3b2b6426d5793545c38396b838 /recipes/phalanx
parentfa6cd5a3b993f16c27de4ff82b42684516d433ba (diff)
rename packages/ to recipes/ per earlier agreement
See links below for more details: http://thread.gmane.org/gmane.comp.handhelds.openembedded/21326 http://thread.gmane.org/gmane.comp.handhelds.openembedded/21816 Signed-off-by: Denys Dmytriyenko <denis@denix.org> Acked-by: Mike Westerhof <mwester@dls.net> Acked-by: Philip Balister <philip@balister.org> Acked-by: Khem Raj <raj.khem@gmail.com> Acked-by: Marcin Juszkiewicz <hrw@openembedded.org> Acked-by: Koen Kooi <koen@openembedded.org> Acked-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com>
Diffstat (limited to 'recipes/phalanx')
-rw-r--r--recipes/phalanx/phalanx/capabilities18
-rw-r--r--recipes/phalanx/phalanx/description10
-rw-r--r--recipes/phalanx/phalanx/gcc3.patch73
-rw-r--r--recipes/phalanx/phalanx_22.bb27
4 files changed, 128 insertions, 0 deletions
diff --git a/recipes/phalanx/phalanx/capabilities b/recipes/phalanx/phalanx/capabilities
new file mode 100644
index 0000000000..703cf84f3c
--- /dev/null
+++ b/recipes/phalanx/phalanx/capabilities
@@ -0,0 +1,18 @@
+[GENERAL]
+NAME=Phalanx
+VERSION=0.1.2
+exec=phalanx
+cmd=-l- -P /opt/QtPalmtop/chess/engines/Phalanx -S /opt/QtPalmtop/chess/engines/Phalanx
+
+[CAPABILITIES]
+UNDO=1
+EDIT=1
+BOOK=1
+
+[DIFFICULTY]
+level_very_easy_cmd=-e 100
+level_easy_cmd=-e 75
+level_moderate_cmd=-e 42
+level_hard_cmd=-e 15
+level_very_hard_cmd=-e 0
+
diff --git a/recipes/phalanx/phalanx/description b/recipes/phalanx/phalanx/description
new file mode 100644
index 0000000000..945d103565
--- /dev/null
+++ b/recipes/phalanx/phalanx/description
@@ -0,0 +1,10 @@
+<qt>
+<b>Phalanx</b>
+<hr>
+Phalanx chess engine was written by Dusan Dobes and it is one of the youngest of the
+free chess programs.
+Despite this fact it has managed to become quite strong approaching the level of some
+modern commercial chess software.
+<br>
+This engine supports differing difficulty levels
+</qt>
diff --git a/recipes/phalanx/phalanx/gcc3.patch b/recipes/phalanx/phalanx/gcc3.patch
new file mode 100644
index 0000000000..3502a691d0
--- /dev/null
+++ b/recipes/phalanx/phalanx/gcc3.patch
@@ -0,0 +1,73 @@
+
+#
+# Patch managed by http://www.holgerschurig.de/patcher.html
+#
+
+--- Phalanx-XXII/phalanx.c~gcc3.patch
++++ Phalanx-XXII/phalanx.c
+@@ -11,30 +11,30 @@
+
+ void badoptions(void)
+ {
+-printf("\
+-Usage: phalanx [options] [<moves> <minutes> [<increment in seconds>]]
+- phalanx [options] [<seconds per move>]
+- phalanx bench
+- phalanx bcreate [options]
+-Options: -t <transposition table size in kilobytes>
+- -f <fixed search time in seconds>
+- -x <+/-> xboard mode on/off default: on
+- -p <+/-> permanent brain on/off default: off
+- -s <+/-> show thinking on/off default: off
+- -c <+/-> cpu time default: off
+- -o <+/-> polling input default: on
+- -b <+/-> opening book default: on
+- -r <resign value in centipawns> default: 0 (no resigning)
+- -e <easy level 0...100> default: 0 (best play)
+- -l <+/-> learning on/off default: on
+- -v print version and exit
+- -P <primary book directory>
+- -S <secondary book directory>
+- -L <learning file directory>
+- -g <log file name>
+-Examples: phalanx -c+ -s+ -o - -x- -f 60 -t4000
+- xboard -fcp \"phalanx -l+ -r800\"
+-");
++printf("\n"
++"Usage: phalanx [options] [<moves> <minutes> [<increment in seconds>]]\n"
++" phalanx [options] [<seconds per move>]\n"
++" phalanx bench\n"
++" phalanx bcreate [options]\n"
++"Options: -t <transposition table size in kilobytes>\n"
++" -f <fixed search time in seconds>\n"
++" -x <+/-> xboard mode on/off default: on\n"
++" -p <+/-> permanent brain on/off default: off\n"
++" -s <+/-> show thinking on/off default: off\n"
++" -c <+/-> cpu time default: off\n"
++" -o <+/-> polling input default: on\n"
++" -b <+/-> opening book default: on\n"
++" -r <resign value in centipawns> default: 0 (no resigning)\n"
++" -e <easy level 0...100> default: 0 (best play)\n"
++" -l <+/-> learning on/off default: on\n"
++" -v print version and exit\n"
++" -P <primary book directory>\n"
++" -S <secondary book directory>\n"
++" -L <learning file directory>\n"
++" -g <log file name>\n"
++"Examples: phalanx -c+ -s+ -o - -x- -f 60 -t4000\n"
++" xboard -fcp \"phalanx -l+ -r800\n"
++"");
+ exit(0);
+ }
+
+--- Phalanx-XXII/io.c~gcc3.patch
++++ Phalanx-XXII/io.c
+@@ -894,7 +894,7 @@
+ { case 0: puts("off"); break;
+ case 1: puts("on"); break;
+ case 2: puts("on (pondering)"); break;
+- default:
++ default:;
+ }
+
+ printf(" Transposition table ... ");
diff --git a/recipes/phalanx/phalanx_22.bb b/recipes/phalanx/phalanx_22.bb
new file mode 100644
index 0000000000..a59a696809
--- /dev/null
+++ b/recipes/phalanx/phalanx_22.bb
@@ -0,0 +1,27 @@
+DESCRIPTION = "Phalanx is a chess playing engine."
+SECTION = "opie/libs"
+PRIORITY = "optional"
+PR = "r4"
+LICENSE = "GPL"
+SRC_URI = "http://ftp.debian.org/debian/pool/main/p/phalanx/phalanx_22.orig.tar.gz \
+ file://gcc3.patch;patch=1 \
+ file://capabilities \
+ file://description"
+S = "${WORKDIR}/phalanx-22.orig"
+
+do_compile() {
+ oe_runmake CC="${CC}" CFLAGS="${CFLAGS}" STRIP=echo LD="${CC}"
+}
+
+do_install() {
+ install -d ${D}${palmtopdir}/chess/engines/Phalanx
+ install -D -m 755 phalanx ${D}${palmtopdir}/chess/engines/Phalanx/phalanx
+ install -D -m 755 pbook.phalanx ${D}${palmtopdir}/chess/engines/Phalanx/pbook.phalanx
+ >${D}${palmtopdir}/chess/engines/Phalanx/sbook.phalanx
+ >${D}${palmtopdir}/chess/engines/Phalanx/learn.phalanx
+ install -D -m 755 ${WORKDIR}/capabilities ${D}${palmtopdir}/chess/engines/Phalanx/capabilities
+ install -D -m 755 ${WORKDIR}/description ${D}${palmtopdir}/chess/engines/Phalanx/description
+}
+
+FILES_${PN} = "${palmtopdir}/chess"
+FILES_${PN}-dbg += "${palmtopdir}/chess/engines/Phalanx/.debug"