rdmd

Adam D. Ruppe destructionator at gmail.com
Sun Jul 5 16:46:27 PDT 2009


Almost there, but not quite. Once again, it compiles without error, but
we have errors.

A quick note: you can leave auto off if you write const? like

const variable = whatever;

Cool!

On topic now.

First problem is the path separator again:

=======

c:\Users\me\Desktop>rdmd --chatty hello.d
chdir "." && dmd  -v -o- "hello.d" >hello.d.deps
dmd  -of"C:\Users\me\AppData\Local\Temp;.rdmd\hello.d.ED85692521C0A87990BB1B70BE
E0046C.exe" -od"C:\Users\me\AppData\Local\Temp;.rdmd\rdmd-hello.d-ED85692521C0A8
7990BB1B70BEE0046C" "hello.d"
OPTLINK (R) for Win32  Release 8.00.1
Copyright (C) Digital Mars 1989-2004  All rights reserved.
C:\Users\me\AppData\Local\Temp.obj
 Error 2: File Not Found C:\Users\me\AppData\Local\Temp.obj
--- errorlevel 1

=======

Notice how it is a semicolon. Changing pathsep to just sep on line 207 fixes
this. (Perhaps the names in std.path should be changed. pathsep and sep are
a bit too similar. pathsep is the character to separate multiple paths, 
like in /bin:/usr/bin. sep is the directory separator.)

Fixing that brings us back to almost the same problem as before.. but it
is opposite now:

whatever: file not found

Coming out of link.exe. The file is created with the .obj extension, but
now link is looking for the file without it :S


(I wish Windows would stop bugging me about rebooting for updates. I'll
 do it when I get around to it! Bah!)

=====

Sidetrack:

That weird exception thrown about the operation completing successfully
is a bug in Phobos's rmdir() function. The reason, from MSDN RemoveDirectory():

Return Value
If the function succeeds, the return value is nonzero. If the function fails, the return value is zero.



Yeah.... silly Microsoft. (Now I understand why this is so common on
The Daily WTF!)

Anyway, to fix it, I just stuck a ! before the
functions in std.file lines 689 and 690. There might be other little
problems like that. Next weekend or something I'll see about going through
the Windows calls and making sure they are all correct.


===========

OK, back to the disappearing .obj. I don't understand why it's doing that...

Let me copy/paste the output again:

c:\Users\me\Desktop>rdmd -v --chatty hello.d
chdir "." && dmd -v -v -o- "hello.d" >hello.d.deps
dmd -v -of"C:\Users\me\AppData\Local\Temp\.rdmd\hello.d.ED85692521C0A87990BB1B70
BEE0046C.exe" -od"C:\Users\me\AppData\Local\Temp\.rdmd\rdmd-hello.d-ED85692521C0
A87990BB1B70BEE0046C" "hello.d"
*snip*
c:\dm\bin\link.exe "C:\Users\me\AppData\Local\Temp\.rdmd\rdmd-hello.d-ED85692521
C0A87990BB1B70BEE0046C\hello.d.ED85692521C0A87990BB1B70BEE0046C","C:\Users\me\Ap
pData\Local\Temp\.rdmd\hello.d.ED85692521C0A87990BB1B70BEE0046C.exe",,user32+ker
nel32/noi;
OPTLINK (R) for Win32  Release 8.00.1
Copyright (C) Digital Mars 1989-2004  All rights reserved.
C:\Users\me\AppData\Local\Temp\.rdmd\rdmd-hello.d-ED85692521C0A87990BB1B70BEE004
6C\hello.d.ED85692521C0A87990BB1B70BEE0046C
 Error 2: File Not Found C:\Users\me\AppData\Local\Temp\.rdmd\rdmd-hello.d-ED856
92521C0A87990BB1B70BEE0046C\hello.d.ED85692521C0A87990BB1B70BEE0046C
--- errorlevel 1




Do you have any idea what's going on there?



=============


Finally, on a tangential note, I'm part owner of a young VPS company.
If I can talk the other owners into letting you have access to a Windows
Server 2003 machine that you can log into remotely and use for some
D testing, would that be useful to you?

Windows remote desktop performs pretty well, and with the Linux rdesktop
program, you can integrate your clipboard and files from your Linux
box. (That's actually how I use my Vista computer when I'm home. I just
rdesktop into it from Linux, and have access to both systems.)

Wine is great, but for some of these cases, having a real Windows machine
is a real help. 2k3 is very similar to XP, so it would make a decent testbed
for D development.

If you're interested, I'll see if I can get it set up tomorrow and email
you privately with the access details.


-- 
Adam D. Ruppe
http://arsdnet.net



More information about the Digitalmars-d mailing list