Code Monkey home page Code Monkey logo

michaelb7 / crafty Goto Github PK

View Code? Open in Web Editor NEW
52.0 52.0 14.0 2.66 MB

Crafty is the "son" (direct descendent) of the chess program Cray Blitz. it is designed totally around the bit-board data structure for reasons of speed of execution, ease of adding new knowledge, and a significantly cleaner overall design. it is written totally in ANSI C with some few UNIX system calls required for I/O, etc.

Home Page: http://craftychess.com

Makefile 0.46% C 97.78% C++ 0.85% Perl 0.12% Objective-C 0.79%

crafty's People

Contributors

michaelb7 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

crafty's Issues

crafty in arena 3.5.1

Hello,
I like Crafty chess engine verry much. I have created a tournament between Crafty 25.2 and Junior 13.3 in Arena 3.5.1 chess GUI, and there is a problem: when I start the tournament Crafty worked fine, but in the second game when sides have switched after white (Junior 13.3) made the first move Crafty instead to think and play like in the first game it displayed the message Engine 1 ilegal move! Please help me.
Thanks a lot.

crafty not reading .craftyrc when started from another folder

I have copied the crafty programs to their own folder in ~/bin. If I start the program from that folder, the .craftyrc file is read, however, if I start crafty from Xboard or from the terminal in another folder, the .craftyrc is not read. I am using macOS Big Sur, and have edited the .zshrc file to include the appropriate export CRAFTY_RC_PATH.

Do I need to include the folder in the path?

Fedora 25 - compiled with unix-gcc | execution failed (Illegal operation (core dumped))

Hey,
I have some problems getting Crafty running.
I compiled it on two different machines, one with opensuse (kernel 4.4.36-8-default, gcc 4.8.5), one with Fedora 25 (kernel 4.9.5-200, gcc 6.3.1).

I compiled with
make unix-gcc
and
make unix-gcc-profile

Both versions are working with opensuse but not with Fedora.
The error is quite short after:
./crafty
Illegal instruction (core dumped)

Do you know how to deal with this?

Kind,
Sebastian

Compilation w/o popcount?

Would you mind to compile a version of the new 25.3 w/o popcount for older 64-bit hardware?
Thanks.

Crafty 25.3 Compiling with Visual Studio 2013/2015/2017 on Windows 7

When I try to use Visual Studio to compile Crafty 25.3 on a windows machine I get the following errors, any advice on how to address these issues in bulk rather than fix them manually or is this my only option? Thanks!

Error 3 error C4996: 'isatty': The POSIX name for this item is deprecated. Instead, use the ISO C++ conformant name: _isatty. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\utility.c 275 1 Crafty25_3
Error 32 error C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\thread.c 793 1 Crafty25_3
Error 38 error C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\test.c 54 1 Crafty25_3
Error 39 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 40 error C2085: 'tb_init' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 41 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 42 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 193 1 Crafty25_3
Error 43 error C2085: 'tb_probe_wdl' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 197 1 Crafty25_3
Error 44 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 197 1 Crafty25_3
Error 45 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 251 1 Crafty25_3
Error 46 error C2085: 'tb_probe_root' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 254 1 Crafty25_3
Error 47 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 254 1 Crafty25_3
Error 48 error C1083: Cannot open include file: 'unistd.h': No such file or directory c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbcore.c 11 1 Crafty25_3
Error 49 error C1083: Cannot open include file: 'unistd.h': No such file or directory c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbcore.c 11 1 Crafty25_3
Error 50 error C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\setboard.c 63 1 Crafty25_3
Error 51 error C4146: unary minus operator applied to unsigned type, result still unsigned c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\see.c 81 1 Crafty25_3
Error 52 error C4146: unary minus operator applied to unsigned type, result still unsigned c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\see.c 152 1 Crafty25_3
Error 53 error C4146: unary minus operator applied to unsigned type, result still unsigned c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\see.c 180 1 Crafty25_3
Error 54 error C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\resign.c 112 1 Crafty25_3
Error 55 error C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\ponder.c 52 1 Crafty25_3
Error 56 error C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\output.c 30 1 Crafty25_3
Error 57 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 58 error C2085: 'tb_init' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 59 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 60 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 193 1 Crafty25_3
Error 61 error C2085: 'tb_probe_wdl' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 197 1 Crafty25_3
Error 62 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 197 1 Crafty25_3
Error 63 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 251 1 Crafty25_3
Error 64 error C2085: 'tb_probe_root' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 254 1 Crafty25_3
Error 65 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 254 1 Crafty25_3
Error 89 error C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\next.c 452 1 Crafty25_3
Error 92 error C4996: 'getenv': This function or variable may be unsafe. Consider using _dupenv_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\main.c 4274 1 Crafty25_3
Error 94 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 95 error C2085: 'tb_init' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 96 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 97 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 193 1 Crafty25_3
Error 98 error C2085: 'tb_probe_wdl' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 197 1 Crafty25_3
Error 99 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 197 1 Crafty25_3
Error 100 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 251 1 Crafty25_3
Error 101 error C2085: 'tb_probe_root' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 254 1 Crafty25_3
Error 102 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 254 1 Crafty25_3
Error 114 error C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\input.c 71 1 Crafty25_3
Error 115 error C4996: '_fmode': This function or variable may be unsafe. Consider using _get_fmode instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\init.c 38 1 Crafty25_3
Error 117 error C4146: unary minus operator applied to unsigned type, result still unsigned c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\init.c 417 1 Crafty25_3
Error 119 error C4146: unary minus operator applied to unsigned type, result still unsigned c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\init.c 450 1 Crafty25_3
Error 131 error C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\evtest.c 48 1 Crafty25_3
Error 132 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 133 error C2085: 'tb_init' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 134 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 167 1 Crafty25_3
Error 135 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 193 1 Crafty25_3
Error 136 error C2085: 'tb_probe_wdl' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 197 1 Crafty25_3
Error 137 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 197 1 Crafty25_3
Error 138 error C2054: expected '(' to follow 'inline' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 251 1 Crafty25_3
Error 139 error C2085: 'tb_probe_root' : not in formal parameter list c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 254 1 Crafty25_3
Error 140 error C2143: syntax error : missing ';' before '{' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbprobe.h 254 1 Crafty25_3
Error 174 error C4146: unary minus operator applied to unsigned type, result still unsigned c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\see.c 81 1 Crafty25_3
Error 175 error C4146: unary minus operator applied to unsigned type, result still unsigned c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\see.c 152 1 Crafty25_3
Error 176 error C4146: unary minus operator applied to unsigned type, result still unsigned c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\see.c 180 1 Crafty25_3
Error 192 error C1083: Cannot open include file: 'unistd.h': No such file or directory c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\tbcore.c 11 1 Crafty25_3
Error 193 error C2059: syntax error : 'constant' c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\boolean.c 19 1 Crafty25_3
Error 202 error C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\book.c 470 1 Crafty25_3
Error 215 error C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\bench.c 124 1 Crafty25_3
Error 218 error C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\autotune.c 50 1 Crafty25_3
Error 222 error C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\annotate.c 103 1 Crafty25_3
Error 225 error C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\users\AllUsers\desktop\crafty 25.3\visual studio project\crafty25_3\source_original\analyze.c 119 1 Crafty25_3
226 IntelliSense: cannot open source file "unistd.h" c:\Users\AllUsers\Desktop\Crafty 25.3\Visual Studio Project\Crafty25_3\Source_Original\tbcore.c 11 1 Crafty25_3
227 IntelliSense: cannot open source file "sys/mman.h" c:\Users\AllUsers\Desktop\Crafty 25.3\Visual Studio Project\Crafty25_3\Source_Original\tbcore.c 18 1 Crafty25_3
228 IntelliSense: identifier "pthread_mutex_t" is undefined c:\Users\AllUsers\Desktop\Crafty 25.3\Visual Studio Project\Crafty25_3\Source_Original\tbcore.c 42 8 Crafty25_3
229 IntelliSense: cannot open source file "pthread.h" c:\Users\AllUsers\Desktop\Crafty 25.3\Visual Studio Project\Crafty25_3\Source_Original\tbcore.h 9 1 Crafty25_3
230 IntelliSense: expected a type specifier c:\Users\AllUsers\Desktop\Crafty 25.3\Visual Studio Project\Crafty25_3\Source_Original\tbcore.h 87 18 Crafty25_3

Crafty & LOG files...

I'm not an expert, and was wondering if there is a way to stop Crafty from writing various log files every time I play a game with it. I end up having to delete several files in the program's folder after every game.

crash in settc

unable to open book file [./book.bin].
book is disabled
unable to open book file [./books.bin].

Crafty v25.6

machine has 8 processors

White(1): settc 0 5 0 5
time remaining: 5:00 (white).
time remaining: 5:00 (black).
0 moves to next time control (white)
0 moves to next time control (black)
Floating point exception (core dumped)

Use /bin/sh in Makefile

In Makefile, change /bin/csh to the generic /bin/sh in the targets named profile and gcc-profile.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.