aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/gnatlink.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2016-04-21 10:57:30 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2016-04-21 10:57:30 +0200
commit9b7924dd177330167865a83f5696a9ae34554972 (patch)
treee6df3b6071ce3b9eab7023eaa8fbbbd5ce15c051 /gcc/ada/gnatlink.adb
parentd74716b313b967b8a9406d86bae41d8843180505 (diff)
downloadgcc-9b7924dd177330167865a83f5696a9ae34554972.zip
gcc-9b7924dd177330167865a83f5696a9ae34554972.tar.gz
gcc-9b7924dd177330167865a83f5696a9ae34554972.tar.bz2
[multiple changes]
2016-04-21 Eric Botcazou <ebotcazou@adacore.com> * gnatlink.adb (Gnatlink): Robustify detection of Windows target. * alloc.ads: Minor comment fixes. * einfo.ads: Fix typo. 2016-04-21 Arnaud Charlet <charlet@adacore.com> * exp_aggr.adb (Component_Not_OK_For_Backend): Redo previous changes to handle all cases of components depending on the discriminant, not just string literals. 2016-04-21 Ed Schonberg <schonberg@adacore.com> * sem_ch3.adb (Analyze_Subtype_Declaration): If the subtype declaration is the generated declaration for a generic actual, inherit predicates from the actual if it is a predicated subtype. 2016-04-21 Ed Schonberg <schonberg@adacore.com> * exp_ch6.adb (Rewrite_Function_Call_For_C): If the function is inherited and its result is controlling, introduce a conversion on the actual for the corresponding procedure call, to avoid spurious type errors. 2016-04-21 Jerome Lambourg <lambourg@adacore.com> * krunch.adb (Krunch): Fix krunching of i-vxworks. From-SVN: r235317
Diffstat (limited to 'gcc/ada/gnatlink.adb')
-rw-r--r--gcc/ada/gnatlink.adb13
1 files changed, 7 insertions, 6 deletions
diff --git a/gcc/ada/gnatlink.adb b/gcc/ada/gnatlink.adb
index a46580a..7417093 100644
--- a/gcc/ada/gnatlink.adb
+++ b/gcc/ada/gnatlink.adb
@@ -154,6 +154,8 @@ procedure Gnatlink is
Base_Command_Name : String_Access;
+ Target_Debuggable_Suffix : String_Access;
+
Tname : Temp_File_Name;
Tname_FD : File_Descriptor := Invalid_FD;
-- Temporary file used by linker to pass list of object files on
@@ -1646,12 +1648,14 @@ begin
Write_Header;
+ Target_Debuggable_Suffix := Get_Target_Debuggable_Suffix;
+
-- If no output name specified, then use the base name of .ali file name
if Output_File_Name = null then
Output_File_Name :=
new String'(Base_Name (Ali_File_Name.all)
- & Get_Target_Debuggable_Suffix.all);
+ & Target_Debuggable_Suffix.all);
end if;
Linker_Options.Increment_Last;
@@ -1711,12 +1715,9 @@ begin
FN (J) := Csets.Fold_Lower (FN (J));
end loop;
- -- For now we detect windows by an output executable name ending with
- -- the suffix .exe.
+ -- For now we detect Windows by its executable suffix of .exe
- if FN'Length > 5
- and then FN (FN'Last - 3 .. FN'Last) = ".exe"
- then
+ if Target_Debuggable_Suffix.all = ".exe" then
Check_File_Name ("install");
Check_File_Name ("setup");
Check_File_Name ("update");