libgeck is a very small lib that you can link your programs with that should aid in debugging. Just link this in the makefile with -lgeck and put the .a and .h files in their directories in your devkit folder. Since this is a wrapper for the libogc functions, you need to link that as well. Or you can just copy the .c and .h files to your project and #include them. The Gecko must be in slot B.

http://wiibrew.org/wiki/Geckoreader