On Jun 12, 2013, at 4:22 AM, Jerry <lancebo...@qwest.net> wrote:

> I'm a little bleary-eyed right now but I can't figure this problem out.
> 
> I just replaced my GPL GNAT (Ada) compiler with the new 2013 edition and am 
> now getting a link error. I made a few trivial changes to my build script to 
> account for some directory changes and I think it should be doing the same 
> thing as it did with the old (2011 edition) compiler. But I'm getting this. 
> "install_name" seems to be getting embedded in some funny places including 
> several occurrences that appeared in the output before this, specifically as 
> "-headerpad_max_install_names", as well as those shown below.
> 
> 
> 
> Linking Ada shared library libplplotadad.dylib
> cd /usr/local/plplot_build_dir/bindings/ada && /opt/local/bin/cmake -E 
> cmake_link_script CMakeFiles/plplotadad.dir/link.txt --verbose=1
> /usr/local/adacore-gnat-2013/bin/gcc  -fPIC  -single_module -dynamiclib 
> -Wl,-headerpad_max_install_names -install_namelibplplotadad.0.dylib -o 
> libplplotadad.0.0.0.dylib CMakeFiles/plplotadad.dir/plplot.o 
> CMakeFiles/plplotadad.dir/plplot_thin.o 
> CMakeFiles/plplotadad.dir/plplot_traditional.o 
> CMakeFiles/plplotadad.dir/plplot_auxiliary.o 
> ../../src/libplplotd.11.0.0.dylib 
> /usr/local/adacore-gnat-2013/lib/gcc/x86_64-apple-darwin12.2.0/4.7.4/adalib/libgnat.dylib
>   -lgcc_s.1
> gcc: error: unrecognized command line option 
> '-install_namelibplplotadad.0.dylib'
> make[2]: *** [bindings/ada/libplplotadad.0.0.0.dylib] Error 1
> make[1]: *** [bindings/ada/CMakeFiles/plplotadad.dir/all] Error 2
> make: *** [all] Error 2
> 
> 
> Jerry

I've finally gotten a chance to revisit this. I should mention that right 
before I updated GNAT from the 2011 edition to the 2013 edition I also updated 
my OS from Lion to Mountain Lion, or 10.7.5 to 10.8.4. I know this is dumb to 
make two changes more or less at once but I was under the impression that the 
2011 GNAT might not work under 10.8.4, but this is wrong as noted below.

Here's a subset of what I've learned.

(1) If I disable Ada and build with GNAT 2013, there are no problems (other 
than not having the Ada library built).

(2) If I enable Ada and build with GNAT 2013, the above problem exists.

(3) If I enable Ada and build with GNAT 2011, there are no problems.

In the case of (1), I can still have a main program that works with PLplot 
because the GNAT make facility, gnatmake, notices that it can see some source 
files (the various PLplot Ada things) that that it needs but which have not 
been compiled and compiles them on its own, sort of "on the side," if you will, 
and then links to them. (I don't know if other make facilities do this sort of 
thing.)

My build scripts for 2011 and 2013 are identical except for minor path 
adjustments since AdaCore likes to make some edition-specific paths in their 
annual releases.

Jerry



------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to