1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119
|
<HTML>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<!-- Created on May, 22 2008 by texi2html 1.64-gnat-1 -->
<!--
Written by: Lionel Cons <Lionel.Cons@cern.ch> (original author)
Karl Berry <karl@freefriends.org>
Olaf Bachmann <obachman@mathematik.uni-kl.de>
and many others.
Maintained by: Olaf Bachmann <obachman@mathematik.uni-kl.de>
Send bugs and suggestions to <texi2html@mathematik.uni-kl.de>
-->
<HEAD>
<TITLE>ASIS-for-GNAT User's Guide: Compiling Binding and Linking Applications with ASIS-for-GNAT</TITLE>
<META NAME="description" CONTENT="ASIS-for-GNAT User's Guide: Compiling Binding and Linking Applications with ASIS-for-GNAT">
<META NAME="keywords" CONTENT="ASIS-for-GNAT User's Guide: Compiling Binding and Linking Applications with ASIS-for-GNAT">
<META NAME="resource-type" CONTENT="document">
<META NAME="distribution" CONTENT="global">
<META NAME="Generator" CONTENT="texi2html 1.64-gnat-1">
</HEAD>
<BODY LANG="" BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#800080" ALINK="#FF0000">
<A NAME="SEC52"></A>
<TABLE CELLPADDING=1 CELLSPACING=1 BORDER=0>
<TR><TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_10.html#SEC51"> < </A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_12.html#SEC53"> > </A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_3.html#SEC9"> << </A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug.html#SEC_Top"> Up </A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_12.html#SEC53"> >> </A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug.html#SEC_Top">Top</A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_toc.html#SEC_Contents">Contents</A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_15.html#SEC56">Index</A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_abt.html#SEC_About"> ? </A>]</TD>
</TR></TABLE>
<H1> 10. Compiling, Binding and Linking Applications with ASIS-for-GNAT </H1>
<!--docid::SEC52::-->
<P>
If you have installed ASIS-for-GNAT as an Ada library and added the directory
containing all source, <TT>`ALI'</TT> and library files of this library to the values
of the <CODE>ADA_INCLUDE_PATH</CODE> and <CODE>ADA_OBJECTS_PATH</CODE> environment
variables (which is a recommended way to install ASIS-for-GNAT), you do not
need to supply any ASIS-specific options for <CODE>gcc</CODE>
or for <CODE>gnatbind</CODE> when working with your ASIS applications.
However for <CODE>gnatlink</CODE> you have to provide an additional parameter
<SAMP>`-lasis'</SAMP>:
<A NAME="IDX159"></A>
</P><P>
<TABLE><tr><td> </td><td class=smallexample><FONT SIZE=+0><pre>$ gnatlink my_application -lasis
</FONT></pre></td></tr></table></P><P>
When using <CODE>gnatmake</CODE>, you also have to provide this linker parameter
whenever a call to <CODE>gnatmake</CODE> invokes <CODE>gnatlink</CODE>:
</P><P>
<TABLE><tr><td> </td><td class=smallexample><FONT SIZE=+0><pre>$ gnatmake ... my_application -largs -lasis
</FONT></pre></td></tr></table></P><P>
You do not need these linker parameters if a call to <CODE>gnatmake</CODE> is not
creating the executable:
</P><P>
<TABLE><tr><td> </td><td class=smallexample><FONT SIZE=+0><pre>$ gnatmake -c ... my_application
</FONT></pre></td></tr></table></P><P>
If you have installed ASIS-for-GNAT without building an ASIS library, then you
have to do the following when working with your ASIS application code:
</P><P>
<UL>
<LI>
When compiling, you have to put catalogs with ASIS-for-GNAT implementation
sources
(<CODE>asis-[version#]-src/asis</CODE> and <CODE>asis-[version#]-src/gnat</CODE>) in the
search path for the source files. You may do this either by the <SAMP>`-I'</SAMP>
option to <CODE>gcc</CODE> or by adding these directories to the <CODE>ADA_INCLUDE_PATH</CODE>
<A NAME="IDX160"></A>
environment variable.
<P>
<LI>
When binding, you have to put the directory where all the object and <TT>`ALI'</TT>
files for the ASIS-for-GNAT components were created
(<CODE>asis-[version#]-src/obj</CODE>, if you followed the manual installation procedure
described in the top-level ASIS <TT>`README'</TT> file) in the search path for
<CODE>gnatbind</CODE>. You can do this either with the <SAMP>`-aO'</SAMP> option to
<CODE>gnatbind</CODE> or by
adding this directory to the <CODE>ADA_OBJECTS_PATH</CODE> environment variable.
<A NAME="IDX161"></A>
</UL>
<P>
If you have added directories with ASIS-for-GNAT source, object and <TT>`ALI'</TT> files
to the values of the GNAT-specific environment variables, you do not
have to provide any ASIS-specific parameter when using <CODE>gnatmake</CODE> for your
ASIS application.
</P><P>
<A NAME="ASIS-for-GNAT Warnings"></A>
<HR SIZE="6">
<TABLE CELLPADDING=1 CELLSPACING=1 BORDER=0>
<TR><TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_3.html#SEC9"> << </A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_12.html#SEC53"> >> </A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug.html#SEC_Top">Top</A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_toc.html#SEC_Contents">Contents</A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_15.html#SEC56">Index</A>]</TD>
<TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="asis_ug_abt.html#SEC_About"> ? </A>]</TD>
</TR></TABLE>
<BR>
<FONT SIZE="-1">
This document was generated
by <I>Mail Server</I> on <I>May, 22 2008</I>
using <A HREF="http://www.mathematik.uni-kl.de/~obachman/Texi2html/"><I>texi2html</I></A>
</BODY>
</HTML>
|