aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/mlib.adb
diff options
context:
space:
mode:
authorThomas Quinot <quinot@act-europe.fr>2004-10-27 15:03:38 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2004-10-27 15:03:38 +0200
commit9cc29fc6f4116e86c5b09ce2915673caec1029b8 (patch)
tree644a6bf5583a35d02fb195335ac90e6baa77489b /gcc/ada/mlib.adb
parent427024aeb0b494def455696e8c4887810799af6b (diff)
downloadgcc-9cc29fc6f4116e86c5b09ce2915673caec1029b8.zip
gcc-9cc29fc6f4116e86c5b09ce2915673caec1029b8.tar.gz
gcc-9cc29fc6f4116e86c5b09ce2915673caec1029b8.tar.bz2
g-os_lib.ads, [...] (Set_Executable, [...]): New subprograms.
2004-10-26 Thomas Quinot <quinot@act-europe.fr> * g-os_lib.ads, g-os_lib.adb (Set_Executable, Set_Writable, Set_Read_Only): New subprograms. These new routines allow the user to set or unset the Owner execute and Owner write permission flags on a file. * makegpr.adb, mlib.adb, mlib-prj.adb: Use GNAT.OS_Lib.Set_Executable instead of rolling our own. From-SVN: r89654
Diffstat (limited to 'gcc/ada/mlib.adb')
-rw-r--r--gcc/ada/mlib.adb8
1 files changed, 2 insertions, 6 deletions
diff --git a/gcc/ada/mlib.adb b/gcc/ada/mlib.adb
index 8e6d0e3..df8796f 100644
--- a/gcc/ada/mlib.adb
+++ b/gcc/ada/mlib.adb
@@ -37,8 +37,6 @@ with MLib.Utl; use MLib.Utl;
with GNAT.Directory_Operations; use GNAT.Directory_Operations;
with GNAT.OS_Lib; use GNAT.OS_Lib;
-with System;
-
package body MLib is
-------------------
@@ -107,9 +105,6 @@ package body MLib is
To_Dir : constant String := Get_Name_String (To);
Interface : Boolean := False;
- procedure Set_Readonly (Name : System.Address);
- pragma Import (C, Set_Readonly, "__gnat_set_readonly");
-
procedure Verbose_Copy (Index : Positive);
-- In verbose mode, output a message that the indexed file is copied
-- to the destination directory.
@@ -264,7 +259,8 @@ package body MLib is
Success := Status and Actual_Len = Len + 3;
if Success then
- Set_Readonly (Name_Buffer'Address);
+ Set_Read_Only (
+ Name_Buffer (1 .. Name_Len - 1));
end if;
end if;
end if;