OSDN Git Service

2009-11-30 Robert Dewar <dewar@adacore.com>
[pf3gnuchains/gcc-fork.git] / gcc / ada / osint.ads
index 38ae795..eeba801 100644 (file)
@@ -147,13 +147,17 @@ package Osint is
    --  Strips the suffix (the last '.' and whatever comes after it) from Name.
    --  Returns the stripped name.
 
-   function Executable_Name (Name : File_Name_Type) return File_Name_Type;
+   function Executable_Name
+     (Name              : File_Name_Type;
+      Only_If_No_Suffix : Boolean := False) return File_Name_Type;
    --  Given a file name it adds the appropriate suffix at the end so that
    --  it becomes the name of the executable on the system at end. For
    --  instance under DOS it adds the ".exe" suffix, whereas under UNIX no
    --  suffix is added.
 
-   function Executable_Name (Name : String) return String;
+   function Executable_Name
+     (Name              : String;
+      Only_If_No_Suffix : Boolean := False) return String;
    --  Same as above, with String parameters
 
    function File_Stamp (Name : File_Name_Type) return Time_Stamp_Type;
@@ -269,6 +273,9 @@ package Osint is
    function File_Time_Stamp
      (Name : C_File_Name;
       Attr : access File_Attributes) return OS_Time;
+   function File_Time_Stamp
+     (Name : Path_Name_Type;
+      Attr : access File_Attributes) return Time_Stamp_Type;
    --  Return the time stamp of the file
 
    function Is_Readable_File
@@ -728,7 +735,7 @@ private
    --  detected, the file being written is deleted, and a fatal error is
    --  signalled.
 
-   File_Attributes_Size : constant Integer := 50;
+   File_Attributes_Size : constant Natural := 24;
    --  This should be big enough to fit a "struct file_attributes" on any
    --  system. It doesn't matter if it is too big (which avoids the need for
    --  either mapping the struct exactly or importing the sizeof from C, which