lanceboyle@qwest.net wrote:
(This post is related to two earlier posts by me, "Linking Ada to Pascal" and 'Where is documentation for "new argument to _p_initialize (@)" PCStrings.')
I've had some success here. The following two files (Pascal main program) and compile commands work.
Good to hear so.
<snip>
<Compile commands> gpc -c pascalcallsada.pas gnatmake -c myadapackage.adb gnatmake -c myadaprogram.adb gnatbind -n myadapackage.ali myadaprogram.ali gnatlink myadaprogram.ali pascalcallsada.o `gpc -print-file-name=libgpc.a` \ -o mypascalprogram
Without any knowledge of Ada, I am trying to understand what exactly happens here, so I have the following questions.
1. gnatmake is the command to use to compile a .adb file into a .o file ? 2. what does gnatbind do ? is it possible to add -v to see what exactly it does ? 3. same question for gnatlink. I assume it calls ld, adding Ada and OS runtime stuff ?
With this information it may be possible to add Ada support to gp, the gpc make/build utility (especially since the main program is Pascal in this example).
Regards,
Adriaan van Os