Welcome! Log In Create A New Profile

Advanced

Compiling Hackmii Libfat.... errors

Posted by fishears 
Compiling Hackmii Libfat.... errors
December 23, 2008 10:58AM
I just got the latest libfat from Hackmii but no matter what I do I get errors when I try to 'make ogc-release'

In file included from /home/jb/developer/devkitPro/libogc/include/ogc/usbstorage.h:12,
                 from /home/jb/developer/devkitPro/libogc/include/gccore.h:76,
                 from /home/jb/developer/src/libfat/libogc/../source/lock.h:36,
                 from /home/jb/developer/src/libfat/libogc/../source/fatdir.c:68:
/home/jb/developer/devkitPro/libogc/include/ogc/disc_io.h:46: error: redefinition of typedef 'FN_MEDIUM_STARTUP'
/home/jb/developer/src/libfat/libogc/../source/disc.h:65: error: previous declaration of 'FN_MEDIUM_STARTUP' was here
/home/jb/developer/devkitPro/libogc/include/ogc/disc_io.h:47: error: redefinition of typedef 'FN_MEDIUM_ISINSERTED'
/home/jb/developer/src/libfat/libogc/../source/disc.h:66: error: previous declaration of 'FN_MEDIUM_ISINSERTED' was here
/home/jb/developer/devkitPro/libogc/include/ogc/disc_io.h:48: error: redefinition of typedef 'FN_MEDIUM_READSECTORS'
/home/jb/developer/src/libfat/libogc/../source/disc.h:67: error: previous declaration of 'FN_MEDIUM_READSECTORS' was here
/home/jb/developer/devkitPro/libogc/include/ogc/disc_io.h:49: error: redefinition of typedef 'FN_MEDIUM_WRITESECTORS'
/home/jb/developer/src/libfat/libogc/../source/disc.h:68: error: previous declaration of 'FN_MEDIUM_WRITESECTORS' was here
/home/jb/developer/devkitPro/libogc/include/ogc/disc_io.h:50: error: redefinition of typedef 'FN_MEDIUM_CLEARSTATUS'
/home/jb/developer/src/libfat/libogc/../source/disc.h:69: error: previous declaration of 'FN_MEDIUM_CLEARSTATUS' was here
/home/jb/developer/devkitPro/libogc/include/ogc/disc_io.h:51: error: redefinition of typedef 'FN_MEDIUM_SHUTDOWN'
/home/jb/developer/src/libfat/libogc/../source/disc.h:70: error: previous declaration of 'FN_MEDIUM_SHUTDOWN' was here
make[2]: *** [fatdir.o] Error 1
make[1]: *** [wii_release] Error 2
make[1]: Leaving directory `/home/jb/developer/src/libfat/libogc'
make: *** [wii-release] Error 2

Can someone tell me what I'm missing here? libogc compiles OK on my setup...
Re: Compiling Hackmii Libfat.... errors
December 23, 2008 11:25AM
You have two installs of two different versions of the sdk, and they are conflicting with each other, fix your setup to only use one at a time.
Re: Compiling Hackmii Libfat.... errors
December 23, 2008 03:04PM
Not sure why you say that. I've got only got one dev environment and it is at /home/jb/developer/devkitPro/ with a /libogc/ below that. Like I said, I can compile libogc from source without any problems so I'm pretty sure it's nothing to do with the environment.

I've downloaded the libfat source to /home/jb/developer/src/libfat/ and that's where I'm compiling from

The conflicts you see in my output (above) are between the disc_io.h in my dev environment and the disc.h in the libfat source directory - NOT two dev environments
Re: Compiling Hackmii Libfat.... errors
December 23, 2008 04:04PM
If you read the paths, it's quite obvious that there is a copy of libogc in the libfat folder.
Re: Compiling Hackmii Libfat.... errors
December 23, 2008 05:06PM
Quote
henke37
If you read the paths, it's quite obvious that there is a copy of libogc in the libfat folder.
No it isn't obvious. Libfat has libogc directory which contains wii/gc specific stuff, nds directory which contains nds specific stuff and gba directory which contains gba specific stuff. And following path /home/jb/developer/src/libfat/libogc/../source/disc.h is exactly same as /home/jb/developer/src/libfat/source/disc.h because .. means parent directory of current directory.



Edited 1 time(s). Last edit at 12/23/2008 05:06PM by Dande.
Re: Compiling Hackmii Libfat.... errors
December 23, 2008 10:11PM
Ignore henke37, he doesn't know what he's talking about. libfat has recently been updated, and the disc interfaces have been moved out of libfat and into libogc. Neither project is officially maintained on git, so you're not guaranteed what you download from git is a sane copy. Not all changes have been merged. You can either modify the git version as required, or download from the devkitpro SVN.
Re: Compiling Hackmii Libfat.... errors
December 24, 2008 10:15AM
Thanks Tantric. I thought disc.h and disc_io.h looked like they were trying to be the same thing. I'll keep trying GIT until I get a copy that's fixed. Nice to know I'm not going mad.

Happy Christmas to you all
Re: Compiling Hackmii Libfat.... errors
January 17, 2009 03:41PM
I solved the same problem of mine just changing the order of libogc and libfat in the makefile so that libfat precedes libogc (-lfat -logc)


but now getting not implemented error for a system fopen call in runtime..... fopen("sd:/hede.txt", "rb")
ps: with the latest devkitpro
Re: Compiling Hackmii Libfat.... errors
January 17, 2009 04:18PM
The trouble is that the Hackmii branch of libfat can't be compiled with the DevkitPro branch of libogc or even with the Hackmii branch of libogc.
I just can't see why Hackmii haven't made the necessary changes in their branch of libogc when this has been a problem for weeks now.
There are some things you just can't do with the DevkitPro libogc/libfat....
Sorry, only registered users may post in this forum.

Click here to login