aboutsummaryrefslogtreecommitdiffstats
path: root/src/ghdldrv/ghdlsynth.adb
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2021-04-05 09:05:21 +0200
committerTristan Gingold <tgingold@free.fr>2021-04-05 09:19:53 +0200
commitf3e936f0ca532fb57f2700a46ba1ff84557f7305 (patch)
treeaa7bc839d7cda359127e90a52b055f714115faf0 /src/ghdldrv/ghdlsynth.adb
parenta9f68a1d91f8ea2a74d8ad4c34f9c777746848a4 (diff)
downloadghdl-f3e936f0ca532fb57f2700a46ba1ff84557f7305.tar.gz
ghdl-f3e936f0ca532fb57f2700a46ba1ff84557f7305.tar.bz2
ghdl-f3e936f0ca532fb57f2700a46ba1ff84557f7305.zip
ghdldrv/: initial support for foreign modules
Diffstat (limited to 'src/ghdldrv/ghdlsynth.adb')
-rw-r--r--src/ghdldrv/ghdlsynth.adb18
1 files changed, 14 insertions, 4 deletions
diff --git a/src/ghdldrv/ghdlsynth.adb b/src/ghdldrv/ghdlsynth.adb
index c3101fc16..8a21169bc 100644
--- a/src/ghdldrv/ghdlsynth.adb
+++ b/src/ghdldrv/ghdlsynth.adb
@@ -277,6 +277,10 @@ package body Ghdlsynth is
-- Do not create concurrent signal assignment for inertial
-- association. They are handled directly.
Vhdl.Canon.Canon_Flag_Inertial_Associations := False;
+
+ if Ghdlcomp.Init_Verilog_Options /= null then
+ Ghdlcomp.Init_Verilog_Options.all (False);
+ end if;
end if;
-- Mark vendor libraries.
@@ -315,15 +319,21 @@ package body Ghdlsynth is
case Files_Map.Find_Language (Arg) is
when Language_Vhdl
| Language_Psl =>
- null;
+ Ghdlcomp.Compile_Load_Vhdl_File (Arg);
+ when Language_Verilog =>
+ if Ghdlcomp.Load_Verilog_File = null then
+ Error_Msg_Option
+ ("verilog file %i is not supported",
+ (1 => +Name_Table.Get_Identifier (Arg)));
+ else
+ Ghdlcomp.Load_Verilog_File (Arg);
+ end if;
when others =>
Errorout.Report_Msg
(Warnid_Library, Option, No_Source_Coord,
- "unexpected extension for vhdl file %i",
+ "unexpected extension for file %i",
(1 => +Name_Table.Get_Identifier (Arg)));
end case;
-
- Ghdlcomp.Compile_Load_File (Arg);
end if;
end;
end loop;