Short: AMOSPro GUI Compiler V2 - Phoenix Author: Pietro Ghizzoni (ghizzo@agonet.it) Uploader: Pietro Ghizzoni (ghizzo@agonet.it) Type: dev/amos Introduction ------------ How does the GUI compiler work? What's the difference? The main difference between the GUI and AMOSPro compilers is that the compiled code generated by the GUI compiler hides all the AMOS "system unfriendly" code. If you zap the code you'll see nothing AMOS related. If you zap the code generated by the standard AMOSPro compiler, you'll find tons of AMOS stuff, like the names of all the extensions installed in your system and other preferences. If you trace an AMOS compiled program using SnoopDOS or other programs, you'll notice other activities like search for and freeze any other running AMOS programs, search for the mysterious AMOS_Switcher and other stuff. The GUI Compiler removes these useless operations. If you run a virus checker together with AMOS, it will probably pop up a warning message because some system functions have been modified. For experts: - Graphics.library LoadView() only on AGA machines - Intuition.library EasyRequestArgs() - Intuition.library AutoRequest() ....the GUI Compiler removes them as well. So essentially the GUI compiler: - hides the AMOS rubbish in the code. - makes your AMOS programs able to run in multitasking with the other AMOS programs. As you know you can't run two or more AMOS programs together, because only the last one will run while the others will be freezed. Now you can! - makes your programs more "clean" and virus checkers warnings free. Since so many AMOS tags have been removed from the code, it is not a good idea to use it in AMOS games, for example. The GUI Compiler is specifically designed for Workbench applications. If your program runs in the Workbench environment, it doesn't need the AMOS patches and hacks.. for this reason i've created the GUI Compiler. If you need to open AMOS screens and related stuffs, use the AMOSPro compiler. If you're creating a nice Workbench application, use the GUI compiler. See also the Gui Amiga Os command for extra bonus in your programs! How to use it ------------- The new phoenix version of the GUI Compiler works in a different way respect its older versions. Now the compiler is fully integrated with the editor, and so you can use it like all the other C++/Asm compilers. How? Very simple... now the GUI compiler is able to read the compiling options directly from your source code! Example: ' OPT DEST Ram:Test NOLIB DEBUG You just need to put at the start of your source code a line like the above example... a Rem followed by the OPT keyword and your options for the compiler. The supported options are: DEST - the destination path of the executable created by the compiler INCLIB - includes the gui.library in the executable (DEFAULT) NOLIB - the gui.library is not included in the executable DEBUG - enable the debug output. While your program is runnnig, in the amiga shell will be printed the line number currently executed. LONG - use LONGword Jumps (jsr) in the executable NOLONG - use short jumps (bsr) in the executable (DEFAULT) LINE - save the source code informations in the executable, so when a error occurs, a message like "Illegal function call at line xxx" will appears. IMPORTANT: the GUI compiler will save the currently loaded source code before compile it!!