我在uvm-systemc-1.0-alpha1库的objdir中的make check
中收到以下错误。
../configure
make
make install
命令工作正常。另外,我已经安装了SystemC-2.3.1,它工作正常。来自
make check
makecheck.log的详细日志 CXXLD simple/callbacks/basic/test
../../src/uvmsc/.libs/libuvm-systemc.so: undefined reference to `sc_core::sc_time::to_string[abi:cxx11]() const'
../../src/uvmsc/.libs/libuvm-systemc.so: undefined reference to `sc_dt::convert_to_fmt(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, sc_dt::sc_numrep, bool)'
../../src/uvmsc/.libs/libuvm-systemc.so: undefined reference to `sc_dt::sc_uint_base::to_string[abi:cxx11](sc_dt::sc_numrep, bool) const'
../../src/uvmsc/.libs/libuvm-systemc.so: undefined reference to `sc_dt::sc_uint_base::to_string[abi:cxx11](sc_dt::sc_numrep) const'
collect2: error: ld returned 1 exit status
Makefile:1064: recipe for target 'simple/callbacks/basic/test' failed
make[3]: *** [simple/callbacks/basic/test] Error 1
make[3]: Leaving directory '/home/mayur/DV/SystemC/uvm-systemc-1.0/objdir/examples/uvmsc'
Makefile:1637: recipe for target 'check-am' failed
make[2]: *** [check-am] Error 2
make[2]: Leaving directory '/home/mayur/DV/SystemC/uvm-systemc-1.0/objdir/examples/uvmsc'
Makefile:310: recipe for target 'check-recursive' failed
make[1]: *** [check-recursive] Error 1
make[1]: Leaving directory '/home/mayur/DV/SystemC/uvm-systemc-1.0/objdir/examples'
Makefile:341: recipe for target 'check-recursive' failed
make: *** [check-recursive] Error 1
最佳答案
看起来链接器无法找到与SystemC相关的变量。这可能是因为您的SystemC-2.3.1的路径对于调用检查相关测试用例的uvm-systemc-1.0-alpha脚本不可用。
用系统中的SystemC-2.3.1路径重新运行configure
。
../configure --with-systemc=/path/to/your/systemc-2.3.1
e.g.
../configure --with-systemc=/home/mayur/DV/SystemC/SystemC-2.3.1
uvm-systemc-1.0 /中的文件
INSTALL
包含必需的说明。一旦重新运行脚本,请确保在
objdir/Makefile
中将以下变量设置为SystemC-2.3.1库路径。SYSTEMC_CFLAGS = -I<your path>/systemc-2.3.1/include
SYSTEMC_LIBS = -L<your path>/systemc-2.3.1/lib -lsystemc
关于c++ - UVM-SystemC库“进行检查”错误,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/38509369/