pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/games/crafty Update to crafty 22.1. Always use the Net...
details: https://anonhg.NetBSD.org/pkgsrc/rev/63710fa66eb2
branches: trunk
changeset: 542690:63710fa66eb2
user: joerg <joerg%pkgsrc.org@localhost>
date: Sun May 25 15:55:27 2008 +0000
description:
Update to crafty 22.1. Always use the NetBSD rules, we can fixup issues
if they happen. Don't install the ECO classification as opening book, it
is essentially useful.
No detailed ChangeLog, but this fixes some crashes with invalid games,
brings SMP support and increases to the strength of crafty.
diffstat:
games/crafty/Makefile | 72 ++++--------------------------------------
games/crafty/PLIST | 7 +---
games/crafty/distinfo | 20 ++--------
games/crafty/patches/patch-aa | 13 +++++++
games/crafty/patches/patch-ab | 67 ----------------------------------------
games/crafty/patches/patch-ac | 22 -------------
6 files changed, 27 insertions(+), 174 deletions(-)
diffs (252 lines):
diff -r 8c94001e7ec7 -r 63710fa66eb2 games/crafty/Makefile
--- a/games/crafty/Makefile Sun May 25 15:32:51 2008 +0000
+++ b/games/crafty/Makefile Sun May 25 15:55:27 2008 +0000
@@ -1,57 +1,25 @@
-# $NetBSD: Makefile,v 1.41 2008/03/04 06:59:03 jlam Exp $
+# $NetBSD: Makefile,v 1.42 2008/05/25 15:55:27 joerg Exp $
-DISTNAME= crafty-18.15
+DISTNAME= crafty-22.1
CATEGORIES= games
-MASTER_SITES= ftp://ftp.cis.uab.edu/pub/hyatt/v18/ \
- ftp://ftp.cis.uab.edu/pub/hyatt/ \
- ftp://ftp.cis.uab.edu/pub/hyatt/common/
-DISTFILES= ${CRAFTY_DISTFILES}
-DISTFILES+= ${CRAFTY_STARTPGN} ${CRAFTY_DOCFILES}
+MASTER_SITES= ftp://ftp.cis.uab.edu/pub/hyatt/source/ \
+ http://www.craftychess.com/
+EXTRACT_SUFX= .zip
MAINTAINER= pkgsrc-users%NetBSD.org@localhost
COMMENT= Chess engine
PKG_DESTDIR_SUPPORT= user-destdir
-DIST_SUBDIR= ${DISTNAME}-1
-CRAFTY_DISTFILES= ${DISTNAME}${EXTRACT_SUFX}
-CRAFTY_STARTPGN= start.pgn
-CRAFTY_DOCFILES= read.me crafty.faq
-EXTRACT_ONLY= ${CRAFTY_DISTFILES}
-
USE_LANGUAGES= c c++
.include "../../mk/bsd.prefs.mk"
-.if !empty(MACHINE_PLATFORM:MNetBSD-*-i386)
-. if ${OBJECT_FMT} == "ELF"
-BUILD_TARGET= netbsd-i386-elf
-. else
-BUILD_TARGET= netbsd-i386
-. endif
-.elif !empty(MACHINE_PLATFORM:MNetBSD-*-sparc)
-BUILD_TARGET= netbsd-sparc
-# higher levels of optimization cause crafty to immediately segfault
-CFLAGS:= ${CFLAGS:C/-O[0-9]*/-O1/}
-.elif !empty(MACHINE_PLATFORM:MNetBSD-*-*)
-BUILD_TARGET= netbsd
-.elif !empty(MACHINE_PLATFORM:MLinux-*-i386)
-. if ${OBJECT_FMT} == "ELF"
-BUILD_TARGET= linux-elf
-. else
-BUILD_TARGET= linux
-. endif
-.elif !empty(MACHINE_PLATFORM:MSunOS-*-*)
-BUILD_TARGET= solaris-gcc
-.elif !empty(MACHINE_PLATFORM:MDragonFly-*-i386)
-BUILD_TARGET= freebsd
-.else
-BUILD_TARGET= generic
-.endif
-
CRAFTY_OPTS= -DBOOKDIR=\"${BOOKDIR:Q}\"
CRAFTY_OPTS+= -DTBDIR=\"${TBDIR:Q}\"
-MAKE_ENV+= opt=${CRAFTY_OPTS:Q}
+MAKE_ENV+= target=NetBSD
+
+BUILD_TARGET= crafty-make
BOOKDIR= ${PREFIX}/lib/crafty
TBDIR= ${PREFIX}/share/egtb
@@ -60,31 +28,7 @@
CRAFTYRC= ${WRKSRC}/.craftyrc
INSTALLATION_DIRS= bin
-post-extract:
- ${CP} ${DISTDIR}/${DIST_SUBDIR}/${CRAFTY_STARTPGN} ${WRKSRC}
- ${MV} ${WRKSRC}/Sparc.s ${WRKSRC}/Sparc.S
-
-post-patch:
- cd ${WRKSRC}; for file in Makefile; do \
- ${SED} -e "s| -O3||g" -e "s| -m486||g" \
- $${file} >> $${file}.fixed; \
- ${MV} $${file}.fixed $${file}; \
- done
-
-post-build:
- ${RM} -f ${CRAFTYRC}
- ${ECHO} "books create ${CRAFTY_STARTPGN} 60" > ${CRAFTYRC}
- ${ECHO} "quit" >> ${CRAFTYRC}
- cd ${WRKSRC} && ${WRKSRC}/crafty bookpath=.
-
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/crafty ${DESTDIR}${PREFIX}/bin
- ${INSTALL_DATA_DIR} ${DESTDIR}${BOOKDIR}
- ${INSTALL_DATA} ${WRKSRC}/books.bin ${DESTDIR}${BOOKDIR}
- ${INSTALL_DATA_DIR} ${DESTDIR}${DOCDIR}
- for file in ${CRAFTY_DOCFILES}; do \
- ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/$${file} \
- ${DESTDIR}${DOCDIR}; \
- done
.include "../../mk/bsd.pkg.mk"
diff -r 8c94001e7ec7 -r 63710fa66eb2 games/crafty/PLIST
--- a/games/crafty/PLIST Sun May 25 15:32:51 2008 +0000
+++ b/games/crafty/PLIST Sun May 25 15:55:27 2008 +0000
@@ -1,7 +1,2 @@
-@comment $NetBSD: PLIST,v 1.2 2002/01/12 05:48:15 jlam Exp $
+@comment $NetBSD: PLIST,v 1.3 2008/05/25 15:55:27 joerg Exp $
bin/crafty
-lib/crafty/books.bin
-share/doc/crafty/read.me
-share/doc/crafty/crafty.faq
-@unexec ${RMDIR} -p %D/share/doc/crafty 2>/dev/null || ${TRUE}
-@dirrm lib/crafty
diff -r 8c94001e7ec7 -r 63710fa66eb2 games/crafty/distinfo
--- a/games/crafty/distinfo Sun May 25 15:32:51 2008 +0000
+++ b/games/crafty/distinfo Sun May 25 15:55:27 2008 +0000
@@ -1,16 +1,6 @@
-$NetBSD: distinfo,v 1.12 2005/12/19 16:41:39 joerg Exp $
+$NetBSD: distinfo,v 1.13 2008/05/25 15:55:27 joerg Exp $
-SHA1 (crafty-18.15-1/crafty-18.15.tar.gz) = b0f19212643a4dffb49c8e3b1ce0be349f3ddb08
-RMD160 (crafty-18.15-1/crafty-18.15.tar.gz) = 02947cacd21533fde8f019dbeb661529166faf2e
-Size (crafty-18.15-1/crafty-18.15.tar.gz) = 363553 bytes
-SHA1 (crafty-18.15-1/start.pgn) = 09de69c698feda46c1ebafa4fa8e908296c66701
-RMD160 (crafty-18.15-1/start.pgn) = ff18923cd702ae21bb23e18fc3a28df1919681c4
-Size (crafty-18.15-1/start.pgn) = 1347 bytes
-SHA1 (crafty-18.15-1/read.me) = 6cbc94627c0d27f1a171e8c27864810532bb0e27
-RMD160 (crafty-18.15-1/read.me) = 9619e3abf3b08596af6304635e964a7f909c9cd4
-Size (crafty-18.15-1/read.me) = 7615 bytes
-SHA1 (crafty-18.15-1/crafty.faq) = 7ba5cc19e190fdcf1697e3130c679ce5e50141db
-RMD160 (crafty-18.15-1/crafty.faq) = f054393dc499627da90336b9e2b31bd753bd9954
-Size (crafty-18.15-1/crafty.faq) = 10252 bytes
-SHA1 (patch-ab) = cf686338b72b83922b23751d75011e92cf3dbe83
-SHA1 (patch-ac) = 39ca98e9cb174f9aeecbae9ddd526b20a83fa27f
+SHA1 (crafty-22.1.zip) = 4ed19f5c676035b899d82cd254eee3d391cbabbf
+RMD160 (crafty-22.1.zip) = 963ec8110617b3d1273953d03ddb974019ec26a9
+Size (crafty-22.1.zip) = 405169 bytes
+SHA1 (patch-aa) = 8efbb76aa23b3972c05dd41cde6b2c5ec8dc49b9
diff -r 8c94001e7ec7 -r 63710fa66eb2 games/crafty/patches/patch-aa
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/games/crafty/patches/patch-aa Sun May 25 15:55:27 2008 +0000
@@ -0,0 +1,13 @@
+$NetBSD: patch-aa,v 1.7 2008/05/25 15:56:02 joerg Exp $
+
+--- Makefile.orig 2008-04-20 19:11:58.000000000 +0200
++++ Makefile
+@@ -428,7 +428,7 @@ crafty-make:
+ crafty.o: *.c *.h
+
+ crafty: $(objects) egtb.o
+- $(CC) $(LDFLAGS) -o crafty $(objects) egtb.o -lm $(LIBS)
++ $(CXX) $(LDFLAGS) -o crafty $(objects) egtb.o -lm $(LIBS)
+
+ egtb.o: egtb.cpp
+ $(CXX) -c $(CXFLAGS) $(opts) egtb.cpp
diff -r 8c94001e7ec7 -r 63710fa66eb2 games/crafty/patches/patch-ab
--- a/games/crafty/patches/patch-ab Sun May 25 15:32:51 2008 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,67 +0,0 @@
-$NetBSD: patch-ab,v 1.4 2002/09/11 10:52:10 jlam Exp $
-
---- boolean.c.orig Thu May 23 10:02:28 2002
-+++ boolean.c
-@@ -61,23 +61,49 @@ int PopCnt(register BITBOARD a) {
- }
-
- int FirstOne(BITBOARD arg1) {
-+ unsigned int i, j, k;
-+
-+ j = k = 0;
- if (arg1>>48)
-- return (first_one[arg1>>48]);
-- if ((arg1>>32)&65535)
-- return (first_one[(arg1>>32)&65535]+16);
-- if ((arg1>>16)&65535)
-- return (first_one[(arg1>>16)&65535]+32);
-- return (first_one[arg1&65535]+48);
-+ i = ((BITBOARD)(arg1>>48));
-+ else if ((arg1>>32)&65535) {
-+ i = ((arg1>>32)&65535);
-+ j = 16;
-+ } else if ((arg1>>16)&65535) {
-+ i = (arg1>>16)&65535;
-+ j = 32;
-+ } else {
-+ i = arg1&65535;
-+ j = 48;
-+ }
-+ while (i >>= 1)
-+ k++;
-+ k = 16 - k;
-+ return (j + k - 1);
- }
-
- int LastOne(BITBOARD arg1) {
-- if (arg1&65535)
-- return (last_one[arg1&65535]+48);
-- if ((arg1>>16)&65535)
-- return (last_one[(arg1>>16)&65535]+32);
-- if ((arg1>>32)&65535)
-- return (last_one[(arg1>>32)&65535]+16);
-- return (last_one[arg1>>48]);
-+ unsigned int i,j,k;
-+
-+ j = k = 0;
-+ if (arg1&65535) {
-+ i = arg1&65535;
-+ j = 48;
-+ } else if ((arg1>>16)&65535) {
-+ i = (arg1>>16)&65535;
-+ j = 32;
-+ } else if ((arg1>>32)&65535) {
-+ i = (arg1>>32)&65535;
-+ j = 16;
-+ } else
-+ i = arg1>>48;
-+
-+ while ((i & 0x1) == 0) {
-+ i >>= 1;
-+ k++;
-+ }
-+ k = 16 - k;
-+ return j + k - 1;
- }
- #endif
- #endif
diff -r 8c94001e7ec7 -r 63710fa66eb2 games/crafty/patches/patch-ac
--- a/games/crafty/patches/patch-ac Sun May 25 15:32:51 2008 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,22 +0,0 @@
-$NetBSD: patch-ac,v 1.4 2005/12/19 16:41:39 joerg Exp $
-
---- Makefile 2004/01/28 14:58:48 1.1
-+++ Makefile 2004/01/28 14:59:16
-@@ -150,7 +150,7 @@ dos:
-
- freebsd:
- $(MAKE) target=FreeBSD \
-- CC=gcc CXX='$$(CC)' \
-+ CC='$(CC)' CXX='$(CXX)' \
- CFLAGS='$(CFLAGS) -fomit-frame-pointer -m486 -O3 -Wall' \
- CXFLAGS='$(CFLAGS)' \
- LDFLAGS='$(LDFLAGS)' \
-@@ -422,7 +422,7 @@ crafty-make:
- crafty
-
- crafty: $(objects)
-- $(CC) $(LDFLAGS) -o crafty $(objects) -lm $(LIBS)
-+ $(CXX) $(LDFLAGS) -o crafty $(objects) -lm $(LIBS)
- @rm -f X86-elf.S
- @rm -f X86-aout.S
-
Home |
Main Index |
Thread Index |
Old Index