Linker problem - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Linker problem

kennycheng93kennycheng93 Posts: 20Member
When I compilied a program, there are no errors. When I tried to make (link) the program, the following error occured:

linker error:
undefined symbol _main in module C0.ASM

Could you tell me how to fix it?

I'm using Turbo C++ 3.0 under Windows ME.

Comments

  • PruyquePruyque Posts: 149Member
    : When I compilied a program, there are no errors. When I tried to make (link) the program, the following error occured:
    :
    : linker error:
    : undefined symbol _main in module C0.ASM
    :
    : Could you tell me how to fix it?
    :
    : I'm using Turbo C++ 3.0 under Windows ME.
    :
    Make shure you have a main function.
    like
    [code]
    int main(void)
    {
    printf("Hello, world!
    ");
    return 0;
    }
    [/code]
    This is the entrypoint to your program.(tc makes dos programs (AFAIK), so WinMain is no good)
  • prateek1997prateek1997 dhanbadPosts: 1Member

    how to check if i have a main function or not ???
    and how to specify it ???

  • NeoNeo IndiaPosts: 1Member

    Just see your code and find if you have something written as main() anywhere..

Sign In or Register to comment.