mirror of
https://github.com/verilator/verilator.git
synced 2025-07-31 07:56:10 +00:00
Add error when use --exe with --lib-create. (#3785)
This commit is contained in:
parent
68e1b473e2
commit
e569ff2752
@ -133,6 +133,7 @@ Victor Besyakov
|
||||
William D. Jones
|
||||
Wilson Snyder
|
||||
Xi Zhang
|
||||
Yinan Xu
|
||||
Yoda Lee
|
||||
Yossi Nivin
|
||||
Yuri Victorovich
|
||||
|
@ -761,6 +761,10 @@ void V3Options::notify() {
|
||||
cmdfl->v3error("--make cannot be used together with --build. Suggest see manual");
|
||||
}
|
||||
|
||||
if (m_exe && !v3Global.opt.libCreate().empty()) {
|
||||
cmdfl->v3error("--exe cannot be used together with --lib-create. Suggest see manual");
|
||||
}
|
||||
|
||||
// Make sure at least one make system is enabled
|
||||
if (!m_gmake && !m_cmake) m_gmake = true;
|
||||
|
||||
|
@ -18,6 +18,7 @@ compile (
|
||||
"--timing",
|
||||
],
|
||||
verilator_make_gcc => 0,
|
||||
make_main => 0,
|
||||
fails => 1,
|
||||
expect_filename => $Self->{golden_filename},
|
||||
);
|
||||
|
2
test_regress/t/t_lib_prot_exe_bad.out
Normal file
2
test_regress/t/t_lib_prot_exe_bad.out
Normal file
@ -0,0 +1,2 @@
|
||||
%Error: --exe cannot be used together with --lib-create. Suggest see manual
|
||||
%Error: Exiting due to
|
25
test_regress/t/t_lib_prot_exe_bad.pl
Executable file
25
test_regress/t/t_lib_prot_exe_bad.pl
Executable file
@ -0,0 +1,25 @@
|
||||
#!/usr/bin/env perl
|
||||
if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); die; }
|
||||
# DESCRIPTION: Verilator: Verilog Test driver/expect definition
|
||||
#
|
||||
# Copyright 2022 by Yinan Xu. This program is free software; you
|
||||
# can redistribute it and/or modify it under the terms of either the GNU
|
||||
# Lesser General Public License Version 3 or the Perl Artistic License
|
||||
# Version 2.0.
|
||||
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
|
||||
|
||||
scenarios(vlt => 1);
|
||||
|
||||
compile (
|
||||
verilator_flags2 => ["--protect-lib",
|
||||
"secret",
|
||||
"--protect-key",
|
||||
"secret-key",
|
||||
],
|
||||
verilator_make_gcc => 0,
|
||||
fails => 1,
|
||||
expect_filename => $Self->{golden_filename},
|
||||
);
|
||||
|
||||
ok(1);
|
||||
1;
|
@ -17,6 +17,7 @@ compile (
|
||||
"secret-key"
|
||||
],
|
||||
verilator_make_gcc => 0,
|
||||
make_main => 0,
|
||||
fails => 1,
|
||||
expect_filename => $Self->{golden_filename},
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user