c++ - Problem with DM Build
- john russell (15/15) Aug 18 2002 I am new to DM so I am trying an easy programe.
- Jan Knepper (7/22) Aug 18 2002 Are you using the IDDE?
- john russell (9/38) Aug 19 2002 Thanks it builds now.
I am new to DM so I am trying an easy programe. #include <stdio.h> int main(void) { printf("This is a short C programme."); return 0; } This compiles and runs in the DOS command window. However when I run DM it compiles OK but when I try to build it keeps giving me the following error. link /NOI /DE /PACKF /XN /NT /ENTRY:WinMainCRTStartup /BAS:4194304 /A:512 tst.LNK Error: c:\dm\lib\SNN.lib(winstart) : Symbol Undefined _WinMain 16 Errors: 1 Warnings: 0 Build failed I am running DM on XP. Has anybody got an answer.
Aug 18 2002
Are you using the IDDE? The problem is you are linking the program as a GUI program which means that your main entry point would be WinMain, not main! If you want this to work, you should remove the /ENTRY:WinMainCRTStartup part from the Link command line. In the IDDE you do this by selecting "Console" as target. john russell wrote:I am new to DM so I am trying an easy programe. #include <stdio.h> int main(void) { printf("This is a short C programme."); return 0; } This compiles and runs in the DOS command window. However when I run DM it compiles OK but when I try to build it keeps giving me the following error. link /NOI /DE /PACKF /XN /NT /ENTRY:WinMainCRTStartup /BAS:4194304 /A:512 tst.LNK Error: c:\dm\lib\SNN.lib(winstart) : Symbol Undefined _WinMain 16 Errors: 1 Warnings: 0 Build failed I am running DM on XP. Has anybody got an answer.
Aug 18 2002
Thanks it builds now. "Jan Knepper" <jan smartsoft.cc> wrote in message news:3D5FC49F.ACDA3512 smartsoft.cc...Are you using the IDDE? The problem is you are linking the program as a GUI program which meansthatyour main entry point would be WinMain, not main! If you want this to work, you should remove the /ENTRY:WinMainCRTStartuppartfrom the Link command line. In the IDDE you do this by selecting "Console"astarget. john russell wrote:itI am new to DM so I am trying an easy programe. #include <stdio.h> int main(void) { printf("This is a short C programme."); return 0; } This compiles and runs in the DOS command window. However when I run DMerror.compiles OK but when I try to build it keeps giving me the following/A:512link /NOI /DE /PACKF /XN /NT /ENTRY:WinMainCRTStartup /BAS:4194304tst.LNK Error: c:\dm\lib\SNN.lib(winstart) : Symbol Undefined _WinMain 16 Errors: 1 Warnings: 0 Build failed I am running DM on XP. Has anybody got an answer.
Aug 19 2002