This is very strange.
I no, this might be no help for you, but:
I just installed DMC on my machine to give it a try. I downloaded the two ZIP archives (http://ftp.digitalmars.com/Digital_Mars_C++/Patch/dm845c.zip and http://ftp.digitalmars.com/Digital_Mars_C++/STL/stlport.zip) and extracted it into a folder. Then I run Code::Blocks and created a new console project. I setup the DMC environment under Settings->Compiler as follows: Changed the path to the include and lib folder accordiung to my installation; added the path to [DMC]\stlport\stlport to the compiler includes and setup the path to the binaries (tab "Programs") accordingly. Nothing else. Then I switched back to the console project. In it's project options now I chose the DMC compiler. Code::Blocks gave me a warning that I should better fully recompile the project due to this (very cool!!!). So I did and it just worked from scratch.
The compiler output was:
Switching to target: default
dmc.exe -mn -c -I"D:\Devel\DMC\stlport\stlport" -I"D:\Devel\DMC\include" -o.objs\main.o main.cpp
link.exe /NOLOGO .objs\main.o , "D:\RemoveMe\console.exe", ,
Process terminated with status 0 (0 minutes, 0 seconds)
0 errors, 0 warnings
No I have another idea for you to try: The compiler seems to work for you. That's fine. So in my opinion the only bad thing can be the linker "link.exe". Are you sure that the one from the DMC installation is called? Could you please verify this? I recommend to use "filemon" by SysInternals for that (http://www.sysinternals.com/Utilities/Filemon.html). Does this help?
Morten.
link.exe /NOLOGO .objs\main.o , "D:\RemoveMe\console.exe", ,
Process terminated with status 0 (0 minutes, 0 seconds)
0 errors, 0 warnings
After writing this: Did you notice that the message from "my" link.exe is different to yours? Why?
Where does this:
OPTLINK (R) for Win32 Release 7.50B1
Copyright (C) Digital Mars 1989 - 2001 All Rights Reserved
come from in your case???
Morten.