通过设置VCS的编译选项,采用下载的lib库,包含了uvm_pkg.sv和dpi,以及设置了VCS_UVM_HOME指向下载的uvm库路径;可是编译完成之后不能运行,报下面的错误:
g++ -o ../simv -Wl,-whole-archive -Wl,-no-whole-archive _vcsobj_1_1.o 5NrI_d.o 5NrIB_d.o SIM_l.o rmapats_mop.o rmapats.o /opt/synopsys/E-2011.03/amd64/lib/libvirsim.so /opt/synopsys/E-2011.03/amd64/lib/liberrorinf.so /opt/synopsys/E-2011.03/amd64/lib/libsnpsmalloc.so /opt/synopsys/E-2011.03/amd64/lib/libvcsnew.so /opt/synopsys/E-2011.03/amd64/lib/libuclinative.so /opt/synopsys/E-2011.03/amd64/lib/vcs_save_restore_new.o -ldl -lc -lm -lpthread -ldl
_vcsobj_1_1.o: In function `F_VCSgd_uvm_pkg_R4kEp_1_414_0':
(.text+0x1a544): undefined reference to `dpi_get_next_arg_c'
_vcsobj_1_1.o: In function `F_VCSgd_uvm_pkg_R4kEp_1_756_0':
(.text+0x55a53): undefined reference to `uvm_glob_to_re'
_vcsobj_1_1.o: In function `F_VCSgd_uvm_pkg_R4kEp_1_758_0':
(.text+0x55d68): undefined reference to `uvm_re_match'
_vcsobj_1_1.o: In function `T_VCSgd_uvm_pkg_R4kEp_1_767_0':
(.text+0x5737f): undefined reference to `uvm_glob_to_re'
_vcsobj_1_1.o: In function `T_VCSgd_uvm_pkg_R4kEp_1_767_0':
(.text+0x573ff): undefined reference to `uvm_re_match'
_vcsobj_1_1.o: In function `F_VCSgd_uvm_pkg_R4kEp_1_854_0':
(.text+0x72430): undefined reference to `uvm_glob_to_re'
_vcsobj_1_1.o: In function `F_VCSgd_uvm_pkg_R4kEp_1_854_0':
(.text+0x724a4): undefined reference to `uvm_re_match'
_vcsobj_1_1.o: In function `T_VCSgd_uvm_pkg_R4kEp_1_858_0':
(.text+0x731d0): undefined reference to `dpi_regcomp'
_vcsobj_1_1.o: In function `T_VCSgd_uvm_pkg_R4kEp_1_858_0':
(.text+0x735b8): undefined reference to `dpi_regexec'
_vcsobj_1_1.o: In function `T_VCSgd_uvm_pkg_R4kEp_1_858_0':
(.text+0x73bf5): undefined reference to `dpi_regfree'
collect2: ld returned 1 exit status
make: *** [product_timestamp] Error 1
Make exited with status 2 cpu time: 3.530 seconds to compile + .010 seconds to elab + .110 seconds to link