If you're careful about it, its not that hard to write a program with portability in mind. But, you have to keep it in mind throughout the whole process. Also, you have to realize that the Dreamcast is a whole lot more limited than your PC is, so you have to keep the limitations in mind.
All in all, writing games for the Dreamcast isn't that hard, assuming you know how to program. Writing portable programs is a bit more difficult, but still not that hard.