Compilation Error

Joined
Sep 26, 2006
Messages
1
Reaction score
0
Hi, I am new to C++ and I am writing a code for SUSE Linux 10. I would like to compile my file "program.cpp" to "program.so" but I get the following error message:

/usr/lib64/gcc/x86_64-suse-linux/4.0.2/../../../../lib64/crt1.o: In function `_start':
../sysdeps/x86_64/elf/start.S:109: undefined reference to `main'
collect2: ld returned 1 exit status

What I did was:

g++ program.cpp -o program.so

Please can anyone help as I have no idea where the problem is. Many thanks for your time.

ysc32
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top