April 30, 2005
Phlip wrote:
> Hi.
> 
> I don't have a 20-year resume covering thousands of computer science topics,
> from fractals to web sites. I just fell off a turnip truck next to a laptop.

It's okay. We're here to help. :)

> 
> How does someone as stupid as me install the D Language on Win32?

I know a lot of people have made suggestions, so this might be too much of a good thing, but you could try reading this:

http://www.prowiki.org/wiki4d/wiki.cgi?D__Tutorial/InstallingDCompiler

But you'd probably rather have some specific suggestions...

>  cd c:\
>  unzip dm.zip
>  unzip dmc.zip
> 
> add c:\dm\bin to the PATH, then get into dmd/samples/d, and:
> 
>  dmc hello.d
> 
> That produces:
>     Error: Error reading file 'object.d'

It sounds like DMD.exe isn't finding the file \dmd\src\phobos\object.d.

If you have the object.d file located where DMD.exe would typically expect it, are you missing this file: \dmd\bin\sc.ini?

-- 
jcc7
http://jcc_7.tripod.com/d/
April 30, 2005
On Fri, 29 Apr 2005 20:14:44 -0500, J C Calvarese wrote:

[snip]

> It sounds like DMD.exe isn't finding the file \dmd\src\phobos\object.d.
> 
> If you have the object.d file located where DMD.exe would typically expect it, are you missing this file: \dmd\bin\sc.ini?

Bingo! Yes this is the problem, I'm sure. And its caused by not having c:\dmd\bin in the PATH symbol. Well, that's my guess anyway ;-)

-- 
Derek Parnell
Melbourne, Australia
30/04/2005 11:16:52 AM
April 30, 2005
Derek Parnell wrote:

> >  cd c:\
> >  unzip dm.zip
> >  unzip dmc.zip
>
> I guess you left out from your message that you also unzipped the 'dmd.zip'? I only ask because dmc is the C++ compiler and dmd is the D compiler. You need both to compile D programs.

Yes. I left out the d.

> >  dmc hello.d
>
> We *are* talking about the D language, no? 'dmc' is the C++ compiler. To invoke D you need to enter "dmd hello.d"

Man, I gotta lay off that crack pipe, huh?

Between all my typos, dmd hello.d _also_ produced that error message.

> If you have the object.d file located where DMD.exe would typically
> expect it, are you missing this file: \dmd\bin\sc.ini?
> jcc7

Jah:

/cygdrive/c/dmd/bin> cat sc.ini
[Version]
version=7.51 Build 020

[Environment]
LIB="%@P%\..\lib";\dm\lib
DFLAGS="-I%@P%\..\src\phobos"
LINKCMD=%@P%\..\..\dm\bin\link.exe
/cygdrive/c/dmd/bin>

(Note I'm using that commie pinko "CygWin", not CMD.EXE like a real,
god-fearing 'Merikin. Deal.)

> Bingo! Yes this is the problem, I'm sure. And its caused by not having c:\dmd\bin in the PATH symbol. Well, that's my guess anyway ;-)

>PATH
PATH=C:\PROGRA~1\Borland\CBUILD~1\Bin;C:\PROGRA~1\Borland\CBUILD~1\Projects\ Bpl;c:\ruby2\bin;C:\Perl\bin\;C:\WINDOWS\sys tem32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Microsoft Visual Studio\Common\MSDev98\Bin;C:\Program Files\d oxygen\bin;C:\mophun\bin;C:\Program Files\Common Files\GTK\2.0\bin;C:\Program Files\Common Files\Compuware;C:\Program Fi les\Compuware\TestPartner;C:\Program Files\Compuware\TestPartner\AppExtDlls;c:\ruby\bin;C:\dm\bin;C:\dmd\bin

Maybe I should start either using or yanking some of that stuff...

Now, one more experiment:

/cygdrive/c/dmd/samples/d> cp ../../src/phobos/object.d .

/cygdrive/c/dmd/samples/d> cp ../../lib/phobos.lib .

/cygdrive/c/dmd/samples/d> dmd hello.d
link hello,,,user32+kernel32/noi;

/cygdrive/c/dmd/samples/d> ./hello.exe
hello world
args.length = 1
args[0] = 'c:\dmd\samples\d\hello.exe'

There ya go. Don't worry about explaining to me why copying the includers and libbers into every working folder might not be workable...

-- 
  Phlip
  http://www.c2.com/cgi/wiki?ZeekLand


April 30, 2005
Phlip wrote:
> Derek Parnell wrote:
> 
...
> (Note I'm using that commie pinko "CygWin", not CMD.EXE like a real,
> god-fearing 'Merikin. Deal.)

If you're that into open source, you might want to just go all out and use Linux exclusively. ;)

Seriously, though, I suspect your problem is related to cygwin. It's just a guess, and I'm no expert in cygwin so I probably can't help with that. Maybe someone (anyone who has some experience in cygwin) will chime in with a helpful suggestion.

> PATH=C:\PROGRA~1\Borland\CBUILD~1\Bin;C:\PROGRA~1\Borland\CBUILD~1\Projects\
> Bpl;c:\ruby2\bin;C:\Perl\bin\;C:\WINDOWS\sys
> tem32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Microsoft Visual
> Studio\Common\MSDev98\Bin;C:\Program Files\d
> oxygen\bin;C:\mophun\bin;C:\Program Files\Common
> Files\GTK\2.0\bin;C:\Program Files\Common Files\Compuware;C:\Program Fi
> les\Compuware\TestPartner;C:\Program
> Files\Compuware\TestPartner\AppExtDlls;c:\ruby\bin;C:\dm\bin;C:\dmd\bin
> 
> Maybe I should start either using or yanking some of that stuff...

I don't know. I've seen worst on my machine. I should warn you though that if you try running MAKE for a D library, it'll probably pick the wrong MAKE (such as Borland's MAKE) instead of the Digital Mars one and fail. The solution is either change the order in the path so that C:\dm\bin is found first or reset PATH (PATH=C:\dm\bin) right before running MAKE.

> Now, one more experiment:
> 
> /cygdrive/c/dmd/samples/d> cp ../../src/phobos/object.d .
> 
> /cygdrive/c/dmd/samples/d> cp ../../lib/phobos.lib .
> 
> /cygdrive/c/dmd/samples/d> dmd hello.d
> link hello,,,user32+kernel32/noi;
> 
> /cygdrive/c/dmd/samples/d> ./hello.exe
> hello world
> args.length = 1
> args[0] = 'c:\dmd\samples\d\hello.exe'
> 
> There ya go. Don't worry about explaining to me why copying the includers
> and libbers into every working folder might not be workable...

I guess it's workable, but I don't think I'd have the patience. Glad to see you got it to work somehow.

-- 
jcc7
http://jcc_7.tripod.com/d/
April 30, 2005
On Fri, 29 Apr 2005 19:41:01 -0700, Phlip wrote:

> Derek Parnell wrote:
> 
>>>  cd c:\
>>>  unzip dm.zip
>>>  unzip dmc.zip
>>
>> I guess you left out from your message that you also unzipped the 'dmd.zip'? I only ask because dmc is the C++ compiler and dmd is the D compiler. You need both to compile D programs.
> 
> Yes. I left out the d.
> 
>>>  dmc hello.d
>>
>> We *are* talking about the D language, no? 'dmc' is the C++ compiler. To invoke D you need to enter "dmd hello.d"
> 
> Man, I gotta lay off that crack pipe, huh?
> 
> Between all my typos, dmd hello.d _also_ produced that error message.
> 
>> If you have the object.d file located where DMD.exe would typically
>> expect it, are you missing this file: \dmd\bin\sc.ini?
>> jcc7
> 
> Jah:
> 
> /cygdrive/c/dmd/bin> cat sc.ini
> [Version]
> version=7.51 Build 020
> 
> [Environment]
> LIB="%@P%\..\lib";\dm\lib
> DFLAGS="-I%@P%\..\src\phobos"
> LINKCMD=%@P%\..\..\dm\bin\link.exe
> /cygdrive/c/dmd/bin>
> 
> (Note I'm using that commie pinko "CygWin", not CMD.EXE like a real,
> god-fearing 'Merikin. Deal.)
> 
>> Bingo! Yes this is the problem, I'm sure. And its caused by not having c:\dmd\bin in the PATH symbol. Well, that's my guess anyway ;-)
> 
>>PATH
> PATH=C:\PROGRA~1\Borland\CBUILD~1\Bin;C:\PROGRA~1\Borland\CBUILD~1\Projects\ Bpl;c:\ruby2\bin;C:\Perl\bin\;C:\WINDOWS\sys tem32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Microsoft Visual Studio\Common\MSDev98\Bin;C:\Program Files\d oxygen\bin;C:\mophun\bin;C:\Program Files\Common Files\GTK\2.0\bin;C:\Program Files\Common Files\Compuware;C:\Program Fi les\Compuware\TestPartner;C:\Program Files\Compuware\TestPartner\AppExtDlls;c:\ruby\bin;C:\dm\bin;C:\dmd\bin
> 
> Maybe I should start either using or yanking some of that stuff...
> 
> Now, one more experiment:
> 
> /cygdrive/c/dmd/samples/d> cp ../../src/phobos/object.d .
> 
> /cygdrive/c/dmd/samples/d> cp ../../lib/phobos.lib .
> 
> /cygdrive/c/dmd/samples/d> dmd hello.d
> link hello,,,user32+kernel32/noi;
> 
> /cygdrive/c/dmd/samples/d> ./hello.exe
> hello world
> args.length = 1
> args[0] = 'c:\dmd\samples\d\hello.exe'
> 
> There ya go. Don't worry about explaining to me why copying the includers and libbers into every working folder might not be workable...

It seems then that cygwin is not so compatible after all. I'm sure now that the source of your problem is cygwin. I've had other people come up with (different) problems when running under cygwin.

Just a thought, but does cygwin use the PATH entries in a case-sensitive way? You have "C:\dmd\bin" int your PATH but the current drive is "c:".

-- 
Derek Parnell
Melbourne, Australia
30/04/2005 2:17:37 PM
April 30, 2005
Derek Parnell wrote:

> It seems then that cygwin is not so compatible after all. I'm sure now
that
> the source of your problem is cygwin. I've had other people come up with (different) problems when running under cygwin.
>
> Just a thought, but does cygwin use the PATH entries in a case-sensitive way? You have "C:\dmd\bin" int your PATH but the current drive is "c:".

When cygwin invokes an EXE that invokes no cygwin*.dll, the EXE still sees a normal PATH and normal environmental variables.

When cygwin*.dll does invoke, it is forward-compatible with . dir *.q can't see *.Q, but open("file.q") _can_ see file.Q.

CygWin ain't to blame (fun though that is), because raw CMD.EXE delivers the
same error.

Contrarily, if DigitalMars saw fit to toss us a CygWin package, that would be sweet (and more stable!).

-- 
  Phlip
  http://www.c2.com/cgi/wiki?ZeekLand


April 30, 2005
"Phlip" <phlip_cpp@yahoo.com> wrote:

>I don't have a 20-year resume covering thousands of computer science topics, from fractals to web sites. I just fell off a turnip truck next to a laptop.
[...]
> (Note I'm using that commie pinko "CygWin", not CMD.EXE like a
> real, god-fearing 'Merikin. Deal.)
[...]
>>PATH
> PATH=C:\PROGRA~1\Borland\CBUILD~1\Bin;C:\PROGRA~1\Borland\CBUILD~

Wohoo! Just landed and cygwin already found, downloaded and installed? And a Borland Compiler? And how do one get the output of the windows-cmd-shell without using it? And you do not know that if the correct entries are in the windows-cmd-shell PATH, that will be taken into the cygwin-bash-shell on restart of cygwin only (so there is the need to show the output of `echo $PATH')? Or do you use *nix commands but have no idea what you are using there?

> /cygdrive/c/dmd/bin> cat sc.ini
> [Version]
> version=7.51 Build 020
>
> [Environment]
> LIB="%@P%\..\lib";\dm\lib
> DFLAGS="-I%@P%\..\src\phobos"
> LINKCMD=%@P%\..\..\dm\bin\link.exe
[...]
> /cygdrive/c/dmd/samples/d> dmd hello.d
> link hello,,,user32+kernel32/noi;
[...]

Wohoo! Again! Just landed and already found out how to change the command prompt of the cygwin bash? And how did you manage to have the digitalmars link command in c:\dmd\samples\d?

This is what the compilation command looks like with my fresh installed cygwin and dmd:

| manfred@home /cygdrive/e/dmd/samples/d
| $ dmd hello
| e:\dmd\bin\..\..\dm\bin\link.exe hello,,,user32+kernel32/noi;

Quite a difference wouldn't you say that?

So what are you telling us? That you have fringed your win32 near to collapse? That you are not able to copyPaste but to change bash prompts? Or simply that you are one of these guys filthying the usenet called trolls or caspers or what not?

-manfred
April 30, 2005
Manfred Nowak wrote:

> So what are you telling us? That you have fringed your win32 near to collapse? That you are not able to copyPaste but to change bash prompts? Or simply that you are one of these guys filthying the usenet called trolls or caspers or what not?

Welcome yourself. Next time, please read the rest of the thread first. We determined the paths are correct, CygWin is not (directly) to blame, sc.ini is correct, and nobody had any further suggestions. And please hesitate before accusing someone of trolling. That is mud that splatters easily back on the accuser.

-- 
  Phlip
  http://www.c2.com/cgi/wiki?ZeekLand


May 01, 2005
Phlip wrote:
> Manfred Nowak wrote:
> 
> 
>>So what are you telling us? That you have fringed your win32 near to
>>collapse? That you are not able to copyPaste but to change bash
>>prompts? Or simply that you are one of these guys filthying the
>>usenet called trolls or caspers or what not?
> 
> 
> Welcome yourself. Next time, please read the rest of the thread first. We
> determined the paths are correct, CygWin is not (directly) to blame, sc.ini
> is correct, and nobody had any further suggestions. And please hesitate
> before accusing someone of trolling. That is mud that splatters easily back
> on the accuser.

Have you tried that evil cmd.exe program yet? You might get some further suggestions if you'd meet us half way.

I often disagree with Manfred's style, but you're seeming more like a troll all the time.

-- 
jcc7
http://jcc_7.tripod.com/d/
May 01, 2005
On Sat, 30 Apr 2005 15:00:09 -0700, Phlip wrote:

> We determined ...CygWin is not (directly) to blame ...

Well, I'm not yet convinced of that. You told us that it's not Cygwin but I haven't got any evidence to suggest you are correct.

Would it be possible for you to use the native Windows command line instead just so we can determine if its a command processor related problem or not.

-- 
Derek Parnell
Melbourne, Australia
http://www.dsource.org/projects/build
1/05/2005 11:22:42 AM