• Advertisement
Sign in to follow this  

main.o syntax error

This topic is 4007 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Awhile back I got curious about assembly language and decided to enable assembly code generation using -S under Build Options -> Other options (this is with Code::Blocks and MingW). Now when I build the program, the linker gives me a "syntax error" message and the .o file opens up in Code::Blocks showing assembly code. The problem is I can't disable this. I've reinstalled both MingW and Code::Blocks and I've tried editing the config file for CB (and of course I've deleted -S from the other options box) and it still does this. Heres the error message: Linking console executable: bin\Debug\hgeGame.exe C:\MinGW\bin\..\lib\gcc\mingw32\3.4.2\..\..\..\..\mingw32\bin\ld.exe:obj\Debug\main.o: file format not recognized; treating as linker script C:\MinGW\bin\..\lib\gcc\mingw32\3.4.2\..\..\..\..\mingw32\bin\ld.exe:obj\Debug\main.o:1: syntax error collect2: ld returned 1 exit status Process terminated with status 1 (0 minutes, 0 seconds) 1 errors, 0 warnings Any ideas?

Share this post


Link to post
Share on other sites
Advertisement
Do you mean that the error occurred when you disabled assembly again? If so, make sure that you make a full rebuild of the entire project. It's possible that main.o wasn't recompiled when it should have been.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement