gnu-chess 6.0.1

master
Adam Vandenberg 2012-02-13 19:50:25 -08:00
parent 08eb58aa9e
commit 7d76bfc7b0
1 changed files with 5 additions and 31 deletions

View File

@ -1,28 +1,16 @@
require 'formula'
class GnuChess < Formula
url 'http://ftpmirror.gnu.org/chess/gnuchess-5.07.tar.gz'
mirror 'http://ftp.gnu.org/gnu/chess/gnuchess-5.07.tar.gz'
homepage 'http://www.gnu.org/software/chess/'
md5 '259da00aa559e5624c65279484fccaf7'
def patches
# v4 of the gcc compiler uncovered an error in the code that should be corrected in
# the 5.08 version of gnuchess.
#
# The error:
# input.c:95: error: static declaration of input_thread follows non-static declaration
#
# The patch removes 'static' from the declaration in input.c. See msg at
# http://www.mail-archive.com/bug-gnu-chess@gnu.org/msg00218.html
DATA
end
url 'http://ftpmirror.gnu.org/chess/gnuchess-6.0.1.tar.gz'
mirror 'http://ftp.gnu.org/gnu/chess/gnuchess-6.0.1.tar.gz'
md5 '041888218f73886f146fa7fbf92190de'
def install
# Opening book for gnuchess. This can be put in the doc directory and the
# user can optionally add the opening book. The README has details on
# adding the opening book.
book_url = "http://ftpmirror.gnu.org/chess/book_1.01.pgn.gz"
book_url = "http://ftpmirror.gnu.org/chess/book_1.02.pgn.gz"
ohai "Downloading #{book_url}"
curl book_url, "-O"
@ -30,8 +18,7 @@ class GnuChess < Formula
system "make"
ENV.j1 # Prevents a "file already exists" warning
system "make install"
doc.install Dir['doc/*']
doc.install ['TODO', 'book_1.01.pgn.gz', 'book']
doc.install Dir['doc/*', 'TODO', 'book_1.02.pgn.gz', 'book']
end
def caveats; <<-EOS.undent
@ -45,16 +32,3 @@ class GnuChess < Formula
EOS
end
end
__END__
diff --git a/src/input.c b/src/input.c
index 1fb9be3..5f0ff79 100644
--- a/src/input.c
+++ b/src/input.c
@@ -92,7 +92,7 @@ void getline_standard(char *p)
fgets(inputstr, MAXSTR, stdin);
}
-static pthread_t input_thread;
+pthread_t input_thread;
/* Mutex and condition variable for thread communication */