Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Compiler Visual C++ Builds but no Output Files(latest Juno CDT & visual c++ support plugin)
Compiler Visual C++ Builds but no Output Files [message #935592] Sun, 07 October 2012 05:41 Go to next message
gophercg cg is currently offline gophercg cgFriend
Messages: 3
Registered: October 2012
Junior Member
Since work uses Eclipse, I'm trying to learn Eclipse on my pc, win7 64bit.
Eclipse Juno, Build id: 20120614-1722.
I tried New hello world project, Microsoft Visual C++ toolchain.
Build can't find cl. So added cl.exe directory into PATH.
Also added CDT Visual C++ Support plugin from add-new-software.
Now it seems std, cout, endl are recognized in the editor/indexer, but not <iostream>. It says "unresolved inclusion <iostream>".

Build project seems fine below, but it doesn't generate any files, no .exe or .o:
Console:
18:25:50 **** Rebuild of configuration Debug for project helloworld_vc ****
Info: Internal Builder is used for build
cl /c /EHs /MD /Zi /nologo "/Fosrc\\helloworld_vc.obj" "..\\src\\helloworld_vc.cpp" 

18:25:50 Build Finished (took 150ms)
Re: Compiler Visual C++ Builds but no Output Files [message #935828 is a reply to message #935592] Sun, 07 October 2012 11:06 Go to previous messageGo to next message
gophercg cg is currently offline gophercg cgFriend
Messages: 3
Registered: October 2012
Junior Member
I managed to build it, with .obj & .pdb outputs. But now the linker I'm quite confused how to setup.
I don't get how to specify all/multiple libs.
Writing the directory normally causes eclipse to cut it into pieces by spaces, and give errors such as "C:\Program.obj" not found.
I had to write ""C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\lib\amd64\*.*"", double quotes to get it to escape spaces, and each time the dialog edits, it auto-removes all quotes so I need to add "" each time. Is this normal?
Manually specifying one .lib works, but link.exe is asking for many libs in the folder, but providing the directory doesn't work, so I tried adding *.*. Now it shows below error:

23:55:01 **** Incremental Build of configuration Debug for project helloworld_vc ****
Info: Internal Builder is used for build
link /debug /nologo /OUT:helloworld_vc.exe "src\\helloworld_vc.obj" "C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\lib\\amd64\\*.*" 
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\lib\amd64\libcmt.pdb : fatal error LNK1107: invalid or corrupt file: cannot read at 0x7F000

23:55:02 Build Finished (took 295ms)


I thought VC++ is a supported option and needed no tweaking. I tried minGW and it works directly. So is my setup wrong? Also I'm not sure if I should link to the files in amd64 or ia64?
Re: Compiler Visual C++ Builds but no Output Files [message #937124 is a reply to message #935828] Mon, 08 October 2012 17:38 Go to previous message
Klaus km is currently offline Klaus kmFriend
Messages: 142
Registered: November 2011
Senior Member
Maybe this article provides useful hints:

http://www.drdobbs.com/cpp/cross-platform-cc-development-with-eclip/232300575

regards,
Klaus


Previous Topic:CDT new Project Template Registration
Next Topic:mingw32-make: *** [Source/main.o] Error 1
Goto Forum:
  


Current Time: Thu Mar 28 08:57:34 GMT 2024

Powered by FUDForum. Page generated in 0.03070 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top