Howdy, Stranger!

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

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

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 ???

Sign In or Register to comment.