April 09, 2002
Ok, I've read the websites and I'm sold. I'm willing to give it a shot
anyways. I've downloaded the D alpha and am trying to get it cooking, but
when I try to compile wc.d I get this error message from dmd.exe:
Error: Error reading file 'object.d'

By the way, my command line was this:
dmd wc.d

I downloaded the 2 files listed under "Requirements" (dmdalpha.zip, dm825c.zip ), unzipped the files, and added the bin folder to my path.

Also, how do you link? The docs say this: "The programs must be linked with the D runtime library phobos.lib, followed by the C runtime library snn.lib."

But I don't see a compiler switch or syntax for linking, such as -l with gcc.

Thanks!
Patrick



April 09, 2002
Patrick wrote:

> Ok, I've read the websites and I'm sold. I'm willing to give it a shot
> anyways. I've downloaded the D alpha and am trying to get it cooking, but
> when I try to compile wc.d I get this error message from dmd.exe:
> Error: Error reading file 'object.d'
>
> By the way, my command line was this:
> dmd wc.d
>
> I downloaded the 2 files listed under "Requirements" (dmdalpha.zip, dm825c.zip ), unzipped the files, and added the bin folder to my path.
>
> Also, how do you link? The docs say this: "The programs must be linked with the D runtime library phobos.lib, followed by the C runtime library snn.lib."
>
> But I don't see a compiler switch or syntax for linking, such as -l with gcc.
>
> Thanks!
> Patrick

I had this problem when I first started. I solved this with the following batch file which I call dmdc.bat and keep in the same directory as the D sample files:

dmd -I\dmd\src\phobos %1.d
sc %1.obj

Then to compile and run a file I type

dmdc hello

remembering to leave off .d

Cheers

John