When trying to build a simple helloworld
program, the next error shows up
LINK : fatal error LNK1561: entry point must be defined
I'm trying to use the systemc library in Visual Studio 2015, maybe thats the problem because, I couldn't find any help configuring this VS for systemc only for VS2010. The program is the following:
// All systemc modules should include systemc.h header file
#include "systemc.h"
// Hello_world is module name
SC_MODULE (hello_world) {
SC_CTOR (hello_world) {
// Nothing in constructor
}
void say_hello() {
//Print "Hello World" to the console.
cout << "Hello World.\n";
}
};
// sc_main in top level function like in C++ main
int sc_main(int argc, char* argv[]) {
hello_world hello("HELLO");
// Print the hello world
hello.say_hello();
return(0);
}
The curious thing is that if I exchange the sc_main
for main it builds but doesn't work.