Commit 9c069f83 authored by yoogx's avatar yoogx
Browse files

* Extend VPATH in the case of source code defined in other

          directories.

          For openaadl/ocarina#255
parent b6cb7913
......@@ -2005,8 +2005,6 @@ package body Ocarina.Backends.Build_Utils is
---------------------
procedure Compile_C_Files (C_Sources : Name_Tables.Instance) is
pragma Unreferenced (C_Sources);
begin
-- Define VPATH, search path for All Prerequisites
......@@ -2014,8 +2012,15 @@ package body Ocarina.Backends.Build_Utils is
if Scenario_Dir /= null then
Write_Str (":" & Scenario_Dir.all);
end if;
Write_Eol;
Write_Eol;
if Length (C_Sources) > 0 then
for J in Name_Tables.First .. Name_Tables.Last (C_Sources) loop
Write_Str (":");
Write_Str
(Dir_Name (Get_Name_String (C_Sources.Table (J))));
exit when J = Name_Tables.Last (C_Sources);
end loop;
end if;
-- Generic rule for compiling C files
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment