Commit a50c3345 by Vincent Celier Committed by Arnaud Charlet

2005-03-29 Vincent Celier <celier@adacore.com>

	* mlib-tgt-vms-ia64.adb, mlib-tgt-vms-alpha.adb
	(Build_Dynamic_Library.Version_String): Return the empty string when
	Lib_Version is empty or when the symbol policy is not Autonomous.

	* symbols-vms-alpha.adb (Finalize): For symbol policy Compliant, when
	a symbol is not in the reference symbol file, increase the Major ID
	and set the Minor ID to 0.
	Use gsmatch=lequal instead of gsmatch=equal

From-SVN: r97166
parent bc5f3720
...@@ -160,8 +160,10 @@ package body MLib.Tgt is ...@@ -160,8 +160,10 @@ package body MLib.Tgt is
-- Returns Symbol_File, if not empty. Otherwise, returns "symvec.opt" -- Returns Symbol_File, if not empty. Otherwise, returns "symvec.opt"
function Version_String return String; function Version_String return String;
-- Returns Lib_Version if not empty, otherwise returns "1". -- Returns Lib_Version if not empty and if Symbol_Data.Symbol_Policy is
-- Fails gnatmake if Lib_Version is not the image of a positive number. -- not Autonomous, otherwise returns "".
-- When Symbol_Data.Symbol_Policy is Autonomous, fails gnatmake if
-- Lib_Version is not the image of a positive number.
------------------ ------------------
-- Is_Interface -- -- Is_Interface --
...@@ -215,8 +217,10 @@ package body MLib.Tgt is ...@@ -215,8 +217,10 @@ package body MLib.Tgt is
function Version_String return String is function Version_String return String is
Version : Integer := 0; Version : Integer := 0;
begin begin
if Lib_Version = "" then if Lib_Version = ""
return "1"; or else Symbol_Data.Symbol_Policy /= Autonomous
then
return "";
else else
begin begin
......
...@@ -160,8 +160,10 @@ package body MLib.Tgt is ...@@ -160,8 +160,10 @@ package body MLib.Tgt is
-- Returns Symbol_File, if not empty. Otherwise, returns "symvec.opt" -- Returns Symbol_File, if not empty. Otherwise, returns "symvec.opt"
function Version_String return String; function Version_String return String;
-- Returns Lib_Version if not empty, otherwise returns "1". -- Returns Lib_Version if not empty and if Symbol_Data.Symbol_Policy is
-- Fails gnatmake if Lib_Version is not the image of a positive number. -- not Autonomous, otherwise returns "".
-- When Symbol_Data.Symbol_Policy is Autonomous, fails gnatmake if
-- Lib_Version is not the image of a positive number.
------------------ ------------------
-- Is_Interface -- -- Is_Interface --
...@@ -215,8 +217,10 @@ package body MLib.Tgt is ...@@ -215,8 +217,10 @@ package body MLib.Tgt is
function Version_String return String is function Version_String return String is
Version : Integer := 0; Version : Integer := 0;
begin begin
if Lib_Version = "" then if Lib_Version = ""
return "1"; or else Symbol_Data.Symbol_Policy /= Autonomous
then
return "";
else else
begin begin
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- Copyright (C) 2003-2004 Free Software Foundation, Inc. -- -- Copyright (C) 2003-2005 Free Software Foundation, Inc. --
-- -- -- --
-- GNAT is free software; you can redistribute it and/or modify it under -- -- 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- -- -- terms of the GNU General Public License as published by the Free Soft- --
...@@ -36,7 +36,7 @@ package body Symbols is ...@@ -36,7 +36,7 @@ package body Symbols is
Symbol_Vector : constant String := "SYMBOL_VECTOR=("; Symbol_Vector : constant String := "SYMBOL_VECTOR=(";
Equal_Data : constant String := "=DATA)"; Equal_Data : constant String := "=DATA)";
Equal_Procedure : constant String := "=PROCEDURE)"; Equal_Procedure : constant String := "=PROCEDURE)";
Gsmatch : constant String := "gsmatch=equal,"; Gsmatch : constant String := "gsmatch=lequal,";
Symbol_File_Name : String_Access := null; Symbol_File_Name : String_Access := null;
-- Name of the symbol file -- Name of the symbol file
...@@ -668,18 +668,15 @@ package body Symbols is ...@@ -668,18 +668,15 @@ package body Symbols is
Success := False; Success := False;
return; return;
elsif Soft_Minor_ID then elsif Soft_Major_ID then
Minor_ID := Minor_ID + 1; Major_ID := Major_ID + 1;
Minor_ID := 0;
Soft_Major_ID := False;
Soft_Minor_ID := False; Soft_Minor_ID := False;
end if; end if;
Original_Symbols.Table (Index_1).Present := False; Original_Symbols.Table (Index_1).Present := False;
Free (Original_Symbols.Table (Index_1).Name); Free (Original_Symbols.Table (Index_1).Name);
if Soft_Minor_ID then
Minor_ID := Minor_ID + 1;
Soft_Minor_ID := False;
end if;
end if; end if;
end loop; end loop;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment