GNAT GPS无法确定要构建的目标

时间:2015-01-23 07:51:36

标签: ada gnat-gps

我正在努力使用将构建和执行的自定义项目文件,但我收到了这组警告(或错误,我不确定)。在全部清除之后,然后单击 Build - >项目 - > Build All 以显示 Build All 对话框:

[2015-01-22 23:30:39] Could not determine the target to build.
[2015-01-22 23:30:39] Could not expand argument in command line: %T
[2015-01-22 23:30:39] Build command not launched.

在单击“执行”开始构建之前,这些在“消息”窗口中显示(红色文本)。单击“执行”时,构建成功完成,程序将运行。

“全部构建”对话框在选项对话框中显示:

  

%builder%eL -P%PP%X -k -s -d

这是什么意思,为什么会这样做?

如果有帮助,这是项目文件:

  project LogBuffer01 is

  for Source_Dirs use ("src", "src\utilities");
  for Object_Dir use "obj";
  for Exec_Dir use "exe";
  for Main use ("abt_log_buffer_main_b.ada");

  package Naming is
     for Spec_Suffix ("ada") use "_s.ada";
     for Body_Suffix ("ada") use "_b.ada";
     for Spec ("abt_mirror_specs") use "abt_mirror_specs_s.ada";
     for Spec ("abt_log_buffer_types") use "abt_log_buffer_types_s.ada";
     for Spec ("abt_log_buffer") use "abt_log_buffer_s.ada";
     for Body ("abt_log_buffer") use "abt_log_buffer_b.ada";
     for Spec ("abt_log_buffer_rom_acess") use "abt_log_buffer_rom_access_s.ada";
     for Body ("abt_log_buffer_rom_acess") use "abt_log_buffer_rom_access_b.ada";
     for Spec ("screen_output") use "screen_output_s.ada";
     for Body ("screen_output") use "screen_output_b.ada";
  end Naming;

  package Pretty_Printer is
     for Default_Switches ("ada") use ("-i5");
  end Pretty_Printer;

  package Compiler is
        for Default_Switches ("ada") use ("-gnat83");
  end Compiler;

  package Builder is
     for Default_Switches ("ada") use ("");
  end Builder;

  package Check is
     for Default_Switches ("ada") use ("-d");
  end Check;

  end LogBuffer01;

1 个答案:

答案 0 :(得分:0)

构建器的含义定义为here。在我翻译你的命令字符串时没有意义,只需说%builder转换为gnatmake,因为你只编译了Ada。描述了gnatmake的开关here

顺便说一句,我对包构建器有这个:

for Default_Switches ("ada") use ("-g", "-C", "-s");

但在另一个正常工作的项目中我有

for Default_Switches ("ada") use ();