Developer forums (C::B DEVELOPMENT STRICTLY!) > Development
BUG : Compiler Fight
killerbot:
It seems that different compilers influence one another in CB.
Using the following setup :
1) MingW GCC (3.4.4)
2) MsVC ToolKit 2003
3) Digital Mars
Attached is a project that creates a simple library, just one stupid file in it.
When you remove Digital Mars target, you can build both the default (with gnu compiler) and the MsVC (with M$ compiler) targets. No problem at all. Rebuild through all targets, or each target independently, everything is ok.
The moment you add the dm target (using digital mars), the M$ VC is broken. It seems that Digital Mars settings already have been applied, though it's not Dm's turn yet.
This is the error output during the M$VC target being build :
--- Quote ----------------- Build: MsVc in Lib1 ---------------
sample.cpp
Linking static library: MsVc\libLib1.a
OPTLINK (R) for Win32 Release 7.50B1
Copyright (C) Digital Mars 1989 - 2001 All Rights Reserved
OPTLINK : Warning 9: Unknown Option : LIB
OPTLINK : Warning 9: Unknown Option : LIBPATH
OPTLINK : Warning 9: Unknown Option : OUT
:C:\Program Files\Microsoft Visual C.obj
Error 2: File Not Found :C:\Program Files\Microsoft Visual C.obj
Process terminated with status 1 (0 minutes, 0 seconds)
0 errors, 0 warnings
--- End quote ---
for some reason the Digital Mars programs are running 'or found or mounted or ..' when it should be the M$ programs. Could it be the paths ?? My normal PATH only contains C:\Ming\bin and none of the others. Off course CB adds some, maybe to many too early ??
Lieven
PS : there's seems to be also a problem with the linking step of digital mars, will look into that later.
[attachment deleted by admin]
killerbot:
The second problem, for the digital mars is because the command is incorrect.
For example we have here :
lib Dm\libLib1.a Dm\src\sample.obj
this should be :
lib -c Dm\libLib1.a Dm\src\sample.obj
In the advanced option for the compiler we see :
Link object files to static library :
$lib_linker $link_options $static_output $link_objects
So either that -c should be added here (but then in the Cb source code), or it should be part of $link_options (also in Cb source ;-) )
As a work around the user could do these changes himself in the compiler settings.
mandrav:
OK, it's not serious :)
The compiler paths are set all in one go, when they should be set just before a target is built.
killerbot:
Well, even a minor third issue :
I also found an inconsistency. In the cbp file it is said for example that M$VC should generate a lib with the .a extension, the output in the message pane is talking about that .a, but in reality a .lib is created, since the advanced compiler options specify that as the default extension for that compiler.
Which one should win, the one from the project, the one from the compiler, and certainly if it's the one or the other, the reporting then should also use the winner.
mandrav:
Fixed in revision 1920.
Navigation
[0] Message Index
[#] Next page
Go to full version