www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - Code::Blocks

reply nobody <not possible.de> writes:
Hello,

i try to intall Code::Blocks under Windows because i want work with
ddbg. The ddbg work an a Console but i didn't understand the usage
from the command line. I can't find any example, anyway. 

I get the error message:

dmd.exe -g  -IC:\dd\dmd\src\phobos -IC:\dd  -c C:\dd\hello.d -ofC:\dd\hello.obj
link.exe C:\dd\hello.exe  C:\dd\hello.obj phobos.lib kernel32.lib user32.lib 
OPTLINK (R) for Win32  Release 7.50B1
Copyright (C) Digital Mars 1989 - 2001  All Rights Reserved
   
C:\dd\hello.exe
 Error 2: File Not Found C:\dd\hello.exe
Process terminated with status 1 (0 minutes, 0 seconds)
1 errors, 0 warnings


The compiler works, only the linker make problems.

My Path:
PATH=C:\dd\dmd\bin;C:\dd\dm\bin  and more...

Linker Settings: phobos.lib kernel32.lib user32.lib

Search Directory für Compiler: C:\dd\dmd\src\phobos
Search Directory for Linker C:\dd\dmd\lib  and C:\dd\dmd\dm
Toolchain executables -> Linker for dynymic libs  : link.exe

Compilers installition directory: c:\dd\dmd

Version svn 4145


Thanks
Jun 25 2007
next sibling parent reply Daniel Keep <daniel.keep.lists gmail.com> writes:
nobody wrote:
 Hello,
 
 i try to intall Code::Blocks under Windows because i want work with
 ddbg. The ddbg work an a Console but i didn't understand the usage
 from the command line. I can't find any example, anyway. 
 
 I get the error message:
 
 dmd.exe -g  -IC:\dd\dmd\src\phobos -IC:\dd  -c C:\dd\hello.d -ofC:\dd\hello.obj
 link.exe C:\dd\hello.exe  C:\dd\hello.obj phobos.lib kernel32.lib user32.lib 
 OPTLINK (R) for Win32  Release 7.50B1
 Copyright (C) Digital Mars 1989 - 2001  All Rights Reserved
    
 C:\dd\hello.exe
  Error 2: File Not Found C:\dd\hello.exe
 Process terminated with status 1 (0 minutes, 0 seconds)
 1 errors, 0 warnings
Although I'm not sure what it *should* be, I'm fairly certain that your link.exe arguments are completely wrong. Whatever is creating that command line is screwing up something awful. I haven't used Code::Blocks in a while, however what I can remember was this: 1) You set the linker command to be dmd.exe, not link.exe. dmd will call link.exe to link everything together. 2) You may need to fiddle with the exact command line settings to get it to work. For instance, the link command for the above should be: dmd -ofC:\dd\hello.exe C:\dd\hello.obj kernel32.lib user32.lib Hope that helps. -- Daniel
Jun 25 2007
parent nobody <not possible.de> writes:
Daniel Keep Wrote:

 
 
 nobody wrote:
 Hello,
 
 i try to intall Code::Blocks under Windows because i want work with
 ddbg. The ddbg work an a Console but i didn't understand the usage
 from the command line. I can't find any example, anyway. 
 
 I get the error message:
 
 dmd.exe -g  -IC:\dd\dmd\src\phobos -IC:\dd  -c C:\dd\hello.d -ofC:\dd\hello.obj
 link.exe C:\dd\hello.exe  C:\dd\hello.obj phobos.lib kernel32.lib user32.lib 
 OPTLINK (R) for Win32  Release 7.50B1
 Copyright (C) Digital Mars 1989 - 2001  All Rights Reserved
    
 C:\dd\hello.exe
  Error 2: File Not Found C:\dd\hello.exe
 Process terminated with status 1 (0 minutes, 0 seconds)
 1 errors, 0 warnings
Although I'm not sure what it *should* be, I'm fairly certain that your link.exe arguments are completely wrong. Whatever is creating that command line is screwing up something awful. I haven't used Code::Blocks in a while, however what I can remember was this: 1) You set the linker command to be dmd.exe, not link.exe. dmd will call link.exe to link everything together. 2) You may need to fiddle with the exact command line settings to get it to work. For instance, the link command for the above should be: dmd -ofC:\dd\hello.exe C:\dd\hello.obj kernel32.lib user32.lib Hope that helps. -- Daniel
I change the link.exe to dmd.exe. Thank you very much.
Jun 25 2007
prev sibling next sibling parent Jascha Wetzel <firstname mainia.de> writes:
nobody wrote:
 The ddbg work an a Console but i didn't understand the usage
 from the command line. I can't find any example, anyway. 
damn, some inner voice told me that it wasn't a good idea to remove that example from the docs ;) so here is the old example again. i hope you can find out everything beyond that from the help and the docs. i'll improve them sometime soon. C:\ddbg> ddbg debuggee.exe Ddbg v0.0.6 alpha - D Debugger Copyright (c) 2007 Jascha Wetzel http://ddbg.mainia.de/ ->arg asdf qwer 1234 ->lsm debugees\debuggee.d segs=1 lines=85 ->bp deb:190 Breakpoint set: debugees\debuggee.d:190 0x40261a ->r ntdll.dll loaded KERNEL32.dll loaded USER32.dll loaded GDI32.dll loaded IMM32.dll loaded ADVAPI32.dll loaded RPCRT4.dll loaded LPK.dll loaded USP10.dll loaded msvcrt.dll loaded Hello world, here are my args: Breakpoint 0 hit debugees\debuggee.d:190 0x40261a uint num_chars = printArgs(args); ->= (cast(char[][])args)[0][3..12] "ddbg\debu" ->= (cast(char[][uint])testhash)[345] "asdf" ->in debugees\debuggee.d:79 0x4020cc uint printArgs(char[][] _D4argsAAa) -> debugees\debuggee.d:81 0x4020d2 uint numchars; ->dal debugees\debuggee.d:81 uint numchars; 004020d2: c745d800000000 mov dword [ebp-0x28], 0x0 ->out Unhandled D Exception (std.array.ArrayBoundsError "ArrayBoundsError debuggee(65)") at KERNEL32.dll (0x7c812a5b) ->us 0x0012ff3400000004) at debugees\debuggee.d:103 debugees\debuggee.d:190 ->q
 I get the error message:
 
 dmd.exe -g  -IC:\dd\dmd\src\phobos -IC:\dd  -c C:\dd\hello.d -ofC:\dd\hello.obj
you don't need to call the linker separately unless you really know why. all you need to do is: cd c:\dd dmd -g hello.d
Jun 25 2007
prev sibling parent reply Chris Nicholson-Sauls <ibisbasenji gmail.com> writes:
nobody wrote:
 Hello,
 
 i try to intall Code::Blocks under Windows because i want work with
 ddbg. The ddbg work an a Console but i didn't understand the usage
 from the command line. I can't find any example, anyway. 
 
 I get the error message:
 
 dmd.exe -g  -IC:\dd\dmd\src\phobos -IC:\dd  -c C:\dd\hello.d -ofC:\dd\hello.obj
 link.exe C:\dd\hello.exe  C:\dd\hello.obj phobos.lib kernel32.lib user32.lib 
 OPTLINK (R) for Win32  Release 7.50B1
 Copyright (C) Digital Mars 1989 - 2001  All Rights Reserved
    
 C:\dd\hello.exe
  Error 2: File Not Found C:\dd\hello.exe
 Process terminated with status 1 (0 minutes, 0 seconds)
 1 errors, 0 warnings
 
 
 The compiler works, only the linker make problems.
 
 My Path:
 PATH=C:\dd\dmd\bin;C:\dd\dm\bin  and more...
 
 Linker Settings: phobos.lib kernel32.lib user32.lib
 
 Search Directory für Compiler: C:\dd\dmd\src\phobos
 Search Directory for Linker C:\dd\dmd\lib  and C:\dd\dmd\dm
 Toolchain executables -> Linker for dynymic libs  : link.exe
 
 Compilers installition directory: c:\dd\dmd
 
 Version svn 4145
 
 
 Thanks
There was a GUI frontend project for ddbg called Flower... unfortunately it appears to be abandoned. If anyone has a copy and is willing to share, you might find it useful at least at first. -- Chris Nicholson-Sauls
Jun 25 2007
parent Myron Alexander <someone somewhere.com> writes:
Chris Nicholson-Sauls wrote:
 There was a GUI frontend project for ddbg called Flower... unfortunately 
 it appears to be abandoned.  If anyone has a copy and is willing to 
 share, you might find it useful at least at first.
 
 -- Chris Nicholson-Sauls
Taken from the newsgroup announcement: http://www.flowerplatform.com/files/flower.zip http://www.flowerplatform.com/files/flower_older.zip http://www.flowerplatform.com/files/thirdparty.zip Regards, Myron.
Jun 25 2007