with "comfignat.gpr";

library project Build_Ahven is

   type OS_Type is ("unix", "windows");
   OS_Version : OS_Type := external ("OS_VERSION", "windows");

   Version := "24";

   for Library_Name      use "ahven";
   for Library_Kind      use "dynamic";
   for Library_Version   use "libahven.so." & Version;
   for Library_Interface use ("Ahven",
                              "Ahven.Framework",
                              "Ahven.Listeners",
                              "Ahven.Listeners.Basic",
			      "Ahven.Name_List",
                              "Ahven.AStrings",
                              "Ahven.Long_AStrings",
                              "Ahven.Results",
                              "Ahven.Parameters",
                              "Ahven.SList",
                              "Ahven.Runner",
                              "Ahven.Tap_Runner",
                              "Ahven.Temporary_Output",
                              "Ahven.Text_Runner",
                              "Ahven.XML_Runner");
   for Source_List_File  use "ahven.lgpr";
   for Object_Dir        use Comfignat.Objdir;
   for Library_Src_Dir   use Comfignat.Stage_Includedir & "/ahven";
   for Library_Dir       use Comfignat.Stage_Libdir;
   for Library_ALI_Dir   use Comfignat.Stage_Alidir & "/ahven";

   case OS_Version is
      when "unix" =>
         for Source_Dirs use ("../src", "../src/unix");
      when "windows" =>
         for Source_Dirs use ("../src", "../src/windows");
   end case;

   package Builder  is
      for Default_Switches ("Ada") use ("-g","-gnatf",
                                          "-gnatVa",
                                          "-gnato",
                                          "-gnatwe",
                                          "-gnatwa",
                                          "-gnatwl",
                                          "-gnatE",
                                          "-gnatwF", -- unreferenced formal off
                                          "-gnatyd3bmhex", "-gnat95");
      -- gnat style switches explained:
      -- 'd' - no DOS line terminators
      -- '3' - indentation level (3 spaces)
      -- 'b' - no trailing whitespace (blanks after statements)
      -- 'm' - lines less than 80 characters
      -- 'h' - no horizontal tabs
      -- 'e' - exit statements need to have labels in named loops
      -- 'x' - no unnecessary parentheses around conditions
   end Builder;
end Build_Ahven;
