You can play chess against a machine on just about any computer, but that's not nearly as fun as playing with real pieces. If you want to build a robot to play against for yourself, Maxim shows off a Raspberry Pi powered board.
The idea here is pretty simple and works similarly to something like a Revelation or Mephisto chess board. The computer runs Stockfish, an open source chess engine. Each piece has a magnet attached to it. When you move a piece, the computer responds to tell you where to move your opponents piece (sorry, it can't magically move pieces on its own). While the video demonstration shows off a Raspberry Pi and Arduino combo, that's no longer needed — a newer version of the guide cuts out the Arduino entirely. Now, you'll just need a Raspberry Pi, a reed switch, a set of LEDs, a small screen, a handful of smaller components and your own chess board.
This isn't an easy project by any means, but if you're a chess player who prefers real pieces and AI opponents, it's well worth the trouble. You'll find the guide for making one at the link below.
Design for easy to build one system Chess Computer [Arduino & Raspberry Pi Chess Computer via Raspberry Pi Pod]