Remove -s binder switch.
[diouzhtu.git] / shared.gpr
blobbad8b2240f665d06d49e3ab9263d921f5ac59495
1 ------------------------------------------------------------------------------
2 --                                Diouzhtu                                  --
3 --                                                                          --
4 --                           Copyright (C) 2007                             --
5 --                            Olivier Ramonat                               --
6 --                                                                          --
7 --  This library is free software; you can redistribute it and/or modify    --
8 --  it under the terms of the GNU General Public License as published by    --
9 --  the Free Software Foundation; either version 2 of the License, or (at   --
10 --  your option) any later version.                                         --
11 --                                                                          --
12 --  This library is distributed in the hope that it will be useful, but     --
13 --  WITHOUT ANY WARRANTY; without even the implied warranty of              --
14 --  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU       --
15 --  General Public License for more details.                                --
16 --                                                                          --
17 --  You should have received a copy of the GNU General Public License       --
18 --  along with this library; if not, write to the Free Software Foundation, --
19 --  Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.       --
20 ------------------------------------------------------------------------------
22 project Shared is
24    for Source_Dirs use ();
25    --  No sources for this project
27    type Build_Type is ("Debug", "Release", "Profile");
28    Build : Build_Type := external ("PRJ_BUILD", "Debug");
30    type OS_Type is ("UNIX", "Windows_NT");
31    OS : OS_Type := external ("OS", "UNIX");
33    -------------
34    -- Builder --
35    -------------
37    package Builder is
38       case Build is
39          when "Release" | "Debug" =>
40             for Default_Switches ("ada") use ("-m", "-s");
42          when "Profile" =>
43             for Default_Switches ("ada") use
44               ("-m", "-s", "-fprofile-arcs", "-ftest-coverage");
45       end case;
46    end Builder;
48    --------------
49    -- Compiler --
50    --------------
52    Common_Options  :=
53      ("-gnat05", "-gnatwa", "-gnaty3Aabcdefhiklmnoprstux", "-Wall");
54    --  Common options used for the Debug and Release modes
56    Debug_Options   :=
57      ("-g", "-gnata", "-gnatVa", "-gnatQ", "-gnato", "-gnatwe");
59    Release_Options :=
60      ("-O2", "-gnatn");
62    package Compiler is
63       case Build is
64          when "Debug" | "Profile" =>
65             for Default_Switches ("Ada") use Common_Options & Debug_Options;
67          when "Release" =>
68             for Default_Switches ("Ada") use Common_Options & Release_Options;
69       end case;
70    end Compiler;
72    ------------
73    -- Binder --
74    ------------
76    package Binder is
77       case Build is
78          when "Debug" | "Profile" =>
79             for Default_Switches ("Ada") use ("-E", "-g");
81          when "Release" =>
82             for Default_Switches ("Ada") use ("-E");
83       end case;
84    end Binder;
86    ------------
87    -- Linker --
88    ------------
90    package Linker is
91       case Build is
92          when "Debug" =>
93             for Default_Switches ("Ada") use ("-g");
95          when "Profile" =>
96             for Default_Switches ("Ada") use ("-g", "-lgmem");
98          when "Release" =>
99             null;
100       end case;
101    end Linker;
103    ---------
104    -- Ide --
105    ---------
107    package Ide is
108       for Vcs_Kind use "Git";
109    end Ide;
111 end Shared;