Include the invalid path in the error message.
gcc/ada/
* make.adb (Scan_Make_Arg): Adjust error message.
* gnatls.adb (Search_RTS): Likewise.
* switch-b.adb (Scan_Debug_Switches): Likewise.
end if;
if Lib_Path /= null then
- Osint.Fail ("RTS path not valid: missing adainclude directory");
+ Osint.Fail
+ ("RTS path """ & Name
+ & """ not valid: missing adainclude directory");
elsif Src_Path /= null then
- Osint.Fail ("RTS path not valid: missing adalib directory");
+ Osint.Fail
+ ("RTS path """ & Name
+ & """ not valid: missing adalib directory");
end if;
-- Try to find the RTS on the project path. First setup the project path
end if;
Osint.Fail
- ("RTS path not valid: missing adainclude and adalib directories");
+ ("RTS path """ & Name
+ & """ not valid: missing adainclude and adalib directories");
end Search_RTS;
-------------------
RTS_Switch := True;
declare
+ RTS_Arg_Path : constant String := Argv (7 .. Argv'Last);
Src_Path_Name : constant String_Ptr :=
Get_RTS_Search_Dir
- (Argv (7 .. Argv'Last), Include);
+ (RTS_Arg_Path, Include);
Lib_Path_Name : constant String_Ptr :=
Get_RTS_Search_Dir
- (Argv (7 .. Argv'Last), Objects);
+ (RTS_Arg_Path, Objects);
begin
if Src_Path_Name /= null
and then Lib_Path_Name = null
then
Make_Failed
- ("RTS path not valid: missing adainclude and adalib "
+ ("RTS path """ & RTS_Arg_Path
+ & """ not valid: missing adainclude and adalib "
& "directories");
elsif Src_Path_Name = null then
Make_Failed
- ("RTS path not valid: missing adainclude directory");
+ ("RTS path """ & RTS_Arg_Path
+ & """ not valid: missing adainclude directory");
else pragma Assert (Lib_Path_Name = null);
Make_Failed
- ("RTS path not valid: missing adalib directory");
+ ("RTS path """ & RTS_Arg_Path
+ & """ not valid: missing adalib directory");
end if;
end;
end if;
Opt.RTS_Switch := True;
declare
+ RTS_Arg_Path : constant String :=
+ Switch_Chars (Ptr + 1 .. Max);
Src_Path_Name : constant String_Ptr :=
Get_RTS_Search_Dir
- (Switch_Chars (Ptr + 1 .. Max),
+ (RTS_Arg_Path,
Include);
Lib_Path_Name : constant String_Ptr :=
Get_RTS_Search_Dir
- (Switch_Chars (Ptr + 1 .. Max),
+ (RTS_Arg_Path,
Objects);
begin
and then Lib_Path_Name = null
then
Osint.Fail
- ("RTS path not valid: missing adainclude and "
+ ("RTS path """ & RTS_Arg_Path
+ & """ not valid: missing adainclude and "
& "adalib directories");
elsif Src_Path_Name = null then
Osint.Fail
- ("RTS path not valid: missing adainclude directory");
+ ("RTS path """ & RTS_Arg_Path
+ & """ not valid: missing adainclude directory");
else pragma Assert (Lib_Path_Name = null);
Osint.Fail
- ("RTS path not valid: missing adalib directory");
+ ("RTS path """ & RTS_Arg_Path
+ & """ not valid: missing adalib directory");
end if;
end;
end if;