GNADE User's Guide: GNADE, The GNat Ada Database Environment; Version 1.5.0; Document Revision $Revision: 1.42 $ | ||
---|---|---|
Prev | Next |
After installation of the GNADE components a typical project file for a project could look like as shown below:
with "/GNADE/gnade"; project Nobel is for Languages use ("Ada"); for Source_Dirs use ("."); for Object_Dir use "."; for Main use ("nobel_co.adb" ); IncludeOpt := "-I" & gnade.ROOT & "/" & gnade.ARCH &"-include" ; LibOpt := "-L" & gnade.ROOT & "/" & gnade.ARCH & "-lib" ; Target := gnade.ROOT & "/" & gnade.ARCH & "-bin"; for Exec_Dir use "."; package Linker is for Default_Switches ("ada") use ("-g", LibOpt, "-lgnadeaux", "-lgnadeodbc", "-L" & gnade.DMLOC, "-l" & gnade.DMLIB ); end Linker; package Binder is for Default_Switches ("ada") use ("-static"); end Binder; package Compiler is for Default_Switches ("ada") use ("-g", IncludeOPT ); end Compiler; package Builder is for Default_Switches ("ada") use ("-s", "-m", "-g", "-gnatQ", IncludeOPT); end Builder; package Ide is for Vcs_Kind use "CVS"; end Ide; end Nobel;
Most of the common defintions are taken from the common GNADE project files. If your are developing a pure ODBC Option it will be sufficient to execute "Build" "Make" "Project" from the GPS Menu.
If you are developing SW involving the esql translator a preprocessing run on the embedded SQL source is needed before compiling the source. Unfortunatly the GPS does not allow to execute preprocessor runs. Therefore you have to rely on a Makefile doing the job. This can be done by means of "Build" "Make" "Custom Make".