Offline

Has anyone been successful building gcbflsh from source? I'm getting errors that are beyond my experience to diagnose.

src/EraseThread.cpp: In member function ‘virtual void EraseThread::run()’:
src/EraseThread.cpp:13:14: warning: variable ‘t0’ set but not used [-Wunused-but-set-variable]

src/Logic.cpp: In static member function ‘static long int Logic::file_size(FILE*)’:
src/Logic.cpp:242:22: error: ‘SEEK_END’ was not declared in this scope
src/Logic.cpp:242:30: error: ‘fseek’ was not declared in this scope
src/Logic.cpp:243:21: error: ‘ftell’ was not declared in this scope
src/Logic.cpp:244:22: error: ‘SEEK_SET’ was not declared in this scope
make: *** [Logic.o] Error 1

This is on Linux Mint 14 64bit and all dependencies are met. I find it hard to believe the source has errors in it too. I really don't feel like installing wine or windows in a vm.

Offline

All errors have been solved. With some internet searching I found a post by someone backing up their Gameboy Camera photos on their Linux box.

So what’s the problem? gbcflsh is only distributed as source, and the source fails to compile under recent releases of Ubuntu. I contacted the developers of gbcflsh, and one gave me some suggestions for fixing the source code. They have yet to publish the fixed source, so I’ll document how I got it to compile.

Focus on the following files:
src/Logic.cpp
src/ReadFlashThread.cpp
src/ReadRamThread.cpp
src/WriteFlashThread.cpp
src/WriteRamThread.cpp
Add the following to the bottom of the #include section of each file:

#include <cstdio>

That’s it! Compile it like you already know how to do (which I won’t get into here).

Remember to use sudo when you run gbcflsh or you won't be able to access the cartridge.