home | |||
links |
|
||
developer's mag main page article part 1 part 2 part 3 part 4 part 5 part 6 part 7 part 8 |
4 - More Commandsmake - The workhorse of your efforts under Cygwin, this actually runs the programming tools on your project. Makefiles work under the principle of least effort - the makefile tries to do the minimal amount of compilation to give you a working program. To do this, entries in the makefiles describe dependencies. If the date of the resulting object file is older than the source file, it's a sure sign that the object file needs recompiling. Otherwise, the compiler assumes the object files are up to date. By compiling only the changes, large projects can see real time savings.Some options you'll find yourself using include make by itself to do the optimized compile described above, 'make clean' to clean up and start fresh (all files recompiled), and 'make seb', to compile the .SEB file for the ebm (the default is creating the .FXE file for the emulator). ./sGDB - Runs the emulator with the .FXE file in the current directory. If you're feeling cocky, you can run both make and the debugger call in one line, by using a semicolon to separate commands:
However if there are compile errors the debugger will still run, which is clearly not what we want. For this, Linux offers a conditional separator, running the second command only if the first is successful:
This combined syntax works especially well with the Cygwin window, which has a history list. You access it with the up and down arrows, and so can review old commands and rerun with just a few keystrokes. For instance, when I build a project, I often can do quick recompiling by entering this compound line, and then just going back to it over and over. Using these commands should take care of the majority of your needs under the Linux/Cygwin environment, and the man command gives you a way to learn about the rest. Previous Section Next Section |
||
Copyright © 2001-2006 ebmDevMag.com - Legal Notice |