The Xentral is an open source example of a CPU that can be synthesized into an inexpensive Spartan FPGA.
The HDL source code (written in VHDL) and Xilinx ISE files are here. The project is still at the beginning, the CPU is very simple (e.g. no pipeline) and there’s no assembler to create your own program from text. Still, it’s a nice demonstration of the possibilities of hardware design, and could be used to teach the basics of processor architecture.