The first thing you want to do is to remove the clean
call from the all
target in your project makefile
. This call is often found in the code templates and demo projects which come along with HAM. For small projects it does not make a significant difference.
Next thing I have seen many times is the inclusion of graphics! Incuding graphic-data makes no sense at all! Imagine you include your uber large image, which is probably even in C/C++ sourcecode format, and is about 3 MB. Now you change something totally trivial in the file that includes the graphic. Now the graphic gets compiled again and this requires a lot of time.
It makes much more sense to compile them once and then only link the compiled file. This way they get only compiled when they have changed. To gain even for time, do not convert the your data into a C array. GCC generates an assembler file from all C/C++ sources it compiles. Having it as a huge C array, it's first 'converted' into assembler code and then into an object file (*
.o). A faster method is to convert the graphics into assembler code. This works quite good and is a lot(!) faster than the C/C++ approach.
Personally I use a tool to concatenate all resources into one huge datablob and create an assembler file from it. The program is called Katie and available on my website at http://www.console-dev.de ! It offers some advanced features to help with the resource management process. Do not miss to take a look at the program and its documentation.