Jump to content

How can I pass definition in command line into sc_main

Recommended Posts

I have got an error when I was running a test.

My bench has been constructed by system C on cadence incisive 14.20.


The run command is like this:

irun -sysc -uvmtop "SC:top" -top dut -f list.f -DTV_PATH=\\\"/home/test0/\\\"


In sc_main.cpp, there is a line like this:

cout << "TV_PATH: " << TV_PATH <<endl;


But when I was running, there is a compile error like this:

line 12: error:

expected an expression

cout << "TV_PATH: " << TV_PATH <<endl;


extra text after expected end of number

cout << "TV_PATH: " << TV_PATH <<endl;



Hi nice guys, How can I solve this problem?




Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now