include/ChangeLog:
[official-gcc.git] / gcc / ada / mlib-tgt.ads
bloba84a989946ea40f464d9bbaf8037d4b8f1acfc41
1 ------------------------------------------------------------------------------
2 -- --
3 -- GNAT COMPILER COMPONENTS --
4 -- --
5 -- M L I B . T G T --
6 -- --
7 -- S p e c --
8 -- --
9 -- Copyright (C) 2001, Ada Core Technologies, Inc. --
10 -- --
11 -- GNAT is free software; you can redistribute it and/or modify it under --
12 -- terms of the GNU General Public License as published by the Free Soft- --
13 -- ware Foundation; either version 2, or (at your option) any later ver- --
14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
15 -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
16 -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License --
17 -- for more details. You should have received a copy of the GNU General --
18 -- Public License distributed with GNAT; see file COPYING. If not, write --
19 -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, --
20 -- MA 02111-1307, USA. --
21 -- --
22 -- GNAT was originally developed by the GNAT team at New York University. --
23 -- It is now maintained by Ada Core Technologies Inc (http://www.gnat.com). --
24 -- --
25 ------------------------------------------------------------------------------
27 -- This package provides a set of target dependent routines to build
28 -- static, dynamic and shared libraries.
30 -- There are several versions for the body of this package.
32 -- In the default version, libraries are not supported, so function
33 -- Libraries_Are_Supported returns False.
35 with GNAT.OS_Lib; use GNAT.OS_Lib;
36 with Types; use Types;
38 package MLib.Tgt is
40 function Libraries_Are_Supported return Boolean;
41 -- Indicates if building libraries by gnatmake and gnatmlib
42 -- are supported by the GNAT implementation for the OS.
44 function Default_DLL_Address return String;
45 -- default address for non relocatable DLL
47 function Dynamic_Option return String;
48 -- gcc option to create a dynamic library
50 function Base_Option return String;
52 function Libgnat return String;
53 -- System dependent static GNAT library
55 function Archive_Ext return String;
56 -- System dependent static library extension
58 function Object_Ext return String;
59 -- System dependent object extension
61 function DLL_Ext return String;
62 -- System dependent dynamic library extension
64 function PIC_Option return String;
65 -- Position independent code option
67 function Is_Object_Ext (Ext : String) return Boolean;
68 -- Returns True iff Ext is an object file extension
70 function Is_C_Ext (Ext : String) return Boolean;
71 -- Returns True iff Ext is a C file extension.
73 function Is_Archive_Ext (Ext : String) return Boolean;
74 -- Returns True iff Ext is an extension for a library
76 procedure Copy_ALI_Files
77 (From : Name_Id;
78 To : Name_Id);
79 -- Copy all ALI files from directory From to directory To
81 function Linker_Library_Path_Option
82 (Directory : String)
83 return String_Access;
84 -- Linker option to specify the library directory path
86 procedure Build_Dynamic_Library
87 (Ofiles : Argument_List;
88 Foreign : Argument_List;
89 Afiles : Argument_List;
90 Options : Argument_List;
91 Lib_Filename : String;
92 Lib_Dir : String;
93 Lib_Address : String := "";
94 Lib_Version : String := "";
95 Relocatable : Boolean := False);
96 -- Build a dynamic/relocatable library
98 end MLib.Tgt;