* opt.ads (Unchecked_Shared_Lib_Imports): New Boolean flag.
* prj-nmsc.adb (Check_Library): No error for imports by shared library
projects, when --unchecked-shared-lib-imports is used.
2009-04-24 Robert Dewar <dewar@adacore.com>
* sem_ch7.adb: Minor reformatting
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@146693
138bc75d-0d04-0410-961f-
82ee72b054a4
+2009-04-24 Vincent Celier <celier@adacore.com>
+
+ * opt.ads (Unchecked_Shared_Lib_Imports): New Boolean flag.
+
+ * prj-nmsc.adb (Check_Library): No error for imports by shared library
+ projects, when --unchecked-shared-lib-imports is used.
+
+2009-04-24 Robert Dewar <dewar@adacore.com>
+
+ * sem_ch7.adb: Minor reformatting
+
2009-04-24 Tristan Gingold <gingold@adacore.com>
* s-osinte-darwin.adb, s-osinte-darwin.ads: lwp_self now returns the
-- the other hand, most such blowups will be caught cleanly and simply
-- say compilation abandoned. This flag is set to True by -gnatq or -gnatQ.
+ Unchecked_Shared_Lib_Imports : Boolean := False;
+ -- GPRBUILD
+ -- Set to True when shared library projects are allowed to import projects
+ -- that are not shared library projects. Set by switch
+ -- --unchecked-shared-lib-imports.
+
Undefined_Symbols_Are_False : Boolean := False;
-- GNAT, GNATPREP
-- Set to True by switch -u of gnatprep or -u in the preprocessing data
Continuation := Continuation_String'Access;
end if;
- elsif Data.Library_Kind /= Static then
+ elsif (not Unchecked_Shared_Lib_Imports)
+ and then Data.Library_Kind /= Static
+ then
Error_Msg
(Project, In_Tree,
Continuation.all &
"shared library project %% cannot extend static " &
"library project %%",
Data.Location);
+ Continuation := Continuation_String'Access;
- else
+ elsif not Unchecked_Shared_Lib_Imports then
Error_Msg
(Project, In_Tree,
Continuation.all &
"shared library project %% cannot import static " &
"library project %%",
Data.Location);
+ Continuation := Continuation_String'Access;
end if;
- Continuation := Continuation_String'Access;
end if;
end if;
end Check_Library;
-- --
-- B o d y --
-- --
--- Copyright (C) 1992-2008, Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2009, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
then
if not Has_Private_Declaration (Etype (Id)) then
- -- We assume that the user did not intend a deferred
- -- constant declaration, and the expression is just missing.
+ -- We assume that the user did not intend a deferred constant
+ -- declaration, and the expression is just missing.
Error_Msg_N
("constant declaration requires initialization expression",