I am trying to use GPS IDE as my alternative development tool on OS X El Capitan (moving away from OS X 10.5 Xcode 3.0). But I have stumbled on one strange error:
gnat bind myprog.bexch
gnatbind: Cannot find: myprog.bexch.ali
gprbuild: unable to bind myprog.adb [2016-01-20 18:49:07] process
exited with status 4, 100% (13/13), elapsed time: 04.77s
In my directory, I can only find myprog.bexch. Looks like gnatbind does not produce myprog.bexch.ali
My GPR looks like this:
project Amygdala_Cortex is
for Object_Dir use "Build/";
for Exec_Dir use "Build/Debug/";
for Library_Name use "";
for Library_Ali_Dir use "";
for Library_Kind use "static";
package Compiler is
for Default_Switches ("ada") use ("-g", "-O2", "-I/opt/local/include/aws", "-I/opt/local/include/aws/components");
end Compiler;
package Binder is
for Driver ("ada") use "/usr/local/gnat/bin/gnatbind";
end Binder;
package Linker is
for Linker_Options use ();
end Linker;
for Main use ("amygdala_cortex.adb");
end Amygdala_Cortex;
Apparently, I don't have gprbind in my directories.
Have I done something wrong or missed something in the GPR?
I am using gnat-gpl-2015-x86_64-darwin (GNAT GPL 2015 (20150428-49)) on El Capitan (10.11.2).
Thanks.
I think you should try to comment out the Binder'Driver
attribute. Let gprbuild find and run gnatbind on its own as needed. It will find it on your PATH, via a tool named gprconfig
, which generates a configuration file (generally auto.cgpr
).
You are using AWS. Do not use -I
switches to the compiler, instead simply add
with "aws";
in your project, which will add the relevant switches for the compiler, linker,...