1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129
  
     | 
    
      project GnatColl_Shared is
   Version := "@PACKAGE_VERSION@";
   Name    := "@PACKAGE_TARNAME@";
   for Source_Dirs use ();
   for Object_Dir use "obj";
   for Library_dir use "lib";
   type Build_Type is ("Debug", "Production");
   Build : Build_Type := External ("Gnatcoll_Build", "@BUILD_TYPE@");
   type Yes_No is ("yes", "no");
   Gtk    : Yes_No := External ("GTK", "@WITH_GTK@");
   Python : Yes_No := External ("PYTHON", "@WITH_PYTHON@");
   Syslog : Yes_No := External ("SYSLOG", "@WITH_SYSLOG@");
   Postgres : Yes_No := External ("POSTGRES", "@WITH_POSTGRES@");
   type Sqlite_Inclusion is ("yes", "no", "embedded");
   Sqlite   : Sqlite_Inclusion := External ("SQLITE", "@WITH_SQLITE@");
   Gmp      : Yes_No := External ("GMP", "@WITH_GMP@");
   Projects : Yes_No := External ("PROJECTS", "@WITH_PROJECTS@");
   PyGobject : Yes_No := External ("PYGOBJECT", "@WITH_PYGOBJECT@");
   Readline : Yes_No := External ("READLINE", "@WITH_READLINE@");
   Mmap     : Yes_No := External ("MMAP", "@WITH_MMAP@");
   Iconv : Yes_No := "@WITH_ICONV@";
   Templates : Yes_No := "no";  --  Hard-coded for now
   Postgres_Has_PQprepare : Yes_No :=
      External ("HAS_PQPREPARE", "@HAS_PQPREPARE@");
   Gnatcoll_Gmp_Version      := External ("GNATCOLL_GMP_VERSION",       Version);
   Gnatcoll_Gtk_Version      := External ("GNATCOLL_GTK_VERSION",       Version);
   Gnatcoll_Iconv_Version    := External ("GNATCOLL_ICONV_VERSION" ,    Version);
   Gnatcoll_Postgres_Version := External ("GNATCOLL_POSTGRES_VERSION",  Version);
   Gnatcoll_Python_Version   := External ("GNATCOLL_PYTHON_VERSION",    Version);
   Gnatcoll_Readline_Version := External ("GNATCOLL_READLINE_VERSION" , Version);
   Gnatcoll_Sqlite_Version   := External ("GNATCOLL_SQLITE_VERSION",    Version);
   Gnatcoll_Version          := External ("GNATCOLL_VERSION",           Version);
   So_Ext := "@SO_EXT@";
   type Library_Type_Type is ("relocatable", "static");
   Library_Type : Library_Type_Type :=
     external ("LIBRARY_TYPE", "@DEFAULT_LIBRARY_TYPE@");
   type OS_Kind is ("Windows_NT", "unix");
   OS : OS_Kind := external ("OS", "unix");
   Adaflags       := (@ADAFLAGS_GPR@);
   Cppflags       := (@CPPFLAGS_GPR@);
   Cflags         := (@CFLAGS_GPR@);
   Ldflags        := (@LDFLAGS_GPR@);
   Python_Version := "@PYTHON_VERSION@";
   Python_Base    := "@PYTHON_BASE@";
   Python_Cflags  := (@PYTHON_CFLAGS_GPR@);
   Pygtk_Include  := (@PYGTK_INCLUDE_GPR@);
   Pygobject_Include := (@PYGOBJECT_INCLUDE_GPR@);
   Python_Dir     := "@PYTHON_DIR@";
   Python_Libs    := (@PYTHON_LIBS_GPR@);
   Gtk_Include    := (@GTK_GCC_FLAGS_GPR@);
   Gtk_Libs       := (@GTK_GCC_LIBS_GPR@);
   Postgres_Dir   := "@PATH_LIBPQ@";
   Postgres_Lib   := (@LIB_PQ_GPR@);
   Sqlite_Dir     := "@PATH_LIBSQLITE@";
   Iconv_Dir      := "@PATH_ICONV@";
   Iconv_Lib      := "@LIB_ICONV@";
   Iconv_Include  := "@INCLUDE_ICONV@";
   Sqlite_Switches := (@SQLITE_CFLAGS@);
   Rss_Libs        := (@RSS_LIBS_GPR@);   --  For gnatcoll.memory
   package Compiler is
      case Build is
         when "Debug" =>
            for Switches ("Ada") use
              ("-g", "-O0", "-gnata", "-gnatVa", "-gnatQ", "-gnaty", "-gnateE",
               "-gnatwaCJe", "-gnat05");
            for Switches ("C") use ("-g", "-fdump-xref", "-Wunreachable-code");
         when "Production" =>
            for Switches ("Ada") use
              ("-O2", "-gnatn", "-gnatws", "-gnat05");
            for Switches ("C") use ("-O2", "-Wunreachable-code");
      end case;
      case Syslog is
         when "yes" =>
            for Switches ("C") use Compiler'Switches ("C") & ("-DHAVE_SYSLOG");
         when "no" =>
            null;
      end case;
      case Mmap is
         when "yes" =>
            for Switches ("C") use Compiler'Switches ("C") & ("-DHAVE_MMAP");
         when "no" =>
            null;
      end case;
      for Switches ("Ada") use Compiler'Switches ("Ada") & Adaflags;
      for Switches ("C") use Compiler'Switches ("C") & Cppflags & Cflags;
   end Compiler;
   --  Force Iconv_Dir first, so that on OSX we do not pick up macports
   --  broken libiconv, which prevents linking applications
   System_Linker_Flags := (Iconv_Dir) & (@EXTRA_LINK_SWITCHES@);
   package Linker is
      for Leading_Switches ("Ada") use Ldflags;
      for Switches ("Ada") use System_Linker_Flags;
   end Linker;
   package Binder is
      case Build is
         when "Debug" =>
            for Switches ("Ada") use ("-E");
         when "Production" =>
            null;
      end case;
   end Binder;
   package Builder is
      case Build is
         when "Debug" =>
            for Global_Configuration_Pragmas use "gnat_debug.adc";
         when "Production" =>
            null;
      end case;
   end Builder;
   package Ide is
      for VCS_Kind use "Git";
   end Ide;
end GnatColl_Shared;
 
     |