The old GCC 3.4.4 for OpenRISC defined three constants, OR1K, or1k and OR1K, allowing users to bracket OpenRISC dependent code with #ifdef OR1K. These are not at present defined in the current GCC 4.2.2 by default, so users must explicitly set them by hand.
It looks like the defaults in the file gcc/config/or32/default.h was changed in the patch for gcc-4.2.2