[gtkada] Hello world with glade 3

Bertus Dries bertus.dries at planet.nl
Tue Sep 18 16:34:41 CEST 2012


I have tried to implement the example in a very similar program on my 
system.
The problem is that I get the following messages:
gnatmake -d -PE:\ada\project\Algemeen\algemeen.gpr -XLIBRARY_TYPE=static 
Algemeen.adb -j4 -s
gcc -c -gnatf -I- -gnatA E:\ada\project\Algemeen\Algemeen.adb
gnatbind -r -I- -x E:\ada\project\Algemeen\build\algemeen.ali
error: "glib.ali" not found, "glib.adb" must be compiled

For creating a good maintenance on my system I use
C: for operating system files and office system
D: for all other programs
E: for documents
F: for data

All my programs are located in the files D:\Program Files
GPS 2012 is located  in D:\Program Files\GNAT\2012
GTKAda in D:\Program Files\GNAT\GTKAda
My sample program is located in E:\ada\project\Algemeen

This means that I had to change one line in gtkada.gpr to avoid errors
for Source_Dirs use ("D:\Program Files\GNAT\Gtkada\include\gtkada");

My project file algemeen.gpr is at the moment

with "D:\Program Files\GNAT\Gtkada\lib\gnat\gtkada.gpr";

project Algemeen is

   type Gtkada_Kind_Type is
      ("static", "relocatable");
   Library_Type : Gtkada_Kind_Type := external ("LIBRARY_TYPE", "static");
   for Object_Dir use "build";
   for Exec_Dir use ".";
   for Main use ("Algemeen.adb");

   case Library_Type is

      when "static" =>
         for Source_Dirs use (".", "..\..\Standaarden\Standaard 
Packages\Init");

      when "relocatable" =>
         for Source_Dirs use (".", "..\..\Standaarden\Standaard 
Packages\Init", "D:\Program Files\GNAT\GTKADA\lib\gtkada\relocatable");
   end case;

   package Builder is
      for Default_Switches ("ada") use ("-s", "-j4", "-m");
   end Builder;

   package Compiler is
      for Default_Switches ("ada") use ("-gnatf");
   end Compiler;

   package Binder is
      for Default_Switches ("ada") use ("-r");
   end Binder;

   package Linker is
      -- for Windows production only ;; remove for Linux / Mac / Win debug
      for Default_Switches ("ada") use ("-mwindows");
   end Linker;

end Algemeen;

I think that somewhere in the combination of the two gpr files there must be 
an extra line, but till now I cannot find what it should be.
In some cases I get message that I cannot have the same reference twoce in 
one project.
Can anyone help me, or must I combine the two gpr files to one to avoid 
doubles in the project

L. Dries
-----Oorspronkelijk bericht----- 
From: François Fabien
Sent: Monday, September 17, 2012 8:31 PM
To: gtkada at lists.adacore.com
Subject: [gtkada] Hello world with glade 3

Hello,

I read on this list some posts for starting with glade 3. ("hello world"
with glade 3).
To gain more visibiltity on the web, I put a summary on Ada-DK wiki
http://wiki.ada-dk.org/building_gui_with_glade_3

Regards

François

_______________________________________________
gtkada mailing list
gtkada at lists.adacore.com
http://lists.adacore.com/mailman/listinfo/gtkada 



More information about the gtkada mailing list