FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Help... Windows Build Failed

 
Post new topic   Reply to topic     Forum Index -> Derelict
View previous topic :: View next topic  
Author Message
gamerChad



Joined: 13 Aug 2005
Posts: 21
Location: Cydonia, Mars

PostPosted: Sat Aug 13, 2005 12:44 pm    Post subject: Help... Windows Build Failed Reply with quote

Hello. I am a newbie with a problem, and a question.
The problem is that when I try to build Derelict, it gives me some errors, or something like that, I am not sure but the .lib files won't show up. .lib files are supposed to show up after building right? Smile So I have Derek's build tool, and I set it up so that build.exe on the command line from any location will use the build tool (windows path thing). I run buildme.bat and the command line dumps the following on me:

BUILDING DerelictAL...
DerelictAL\derelict\openal\al.d(223): !(TemplateArgumentList) expected following
TemplateIdentifier


BUILDING DerelictGL...
DerelictGL\derelict\opengl\internal.d(14): !(TemplateArgumentList) expected foll
owing TemplateIdentifier


BUILDING DerelictGLFW...
DerelictGLFW\derelict\glfw\glfw.d(55): !(TemplateArgumentList) expected followin
g TemplateIdentifier


BUILDING DerelictGLU...
DerelictGLU\derelict\opengl\glu.d(113): !(TemplateArgumentList) expected followi
ng TemplateIdentifier


BUILDING DerelictSDL...
DerelictSDL\derelict\sdl\sdl.d(305): !(TemplateArgumentList) expected following
TemplateIdentifier


BUILDING DerelictSDLImage...
DerelictSDLImage\derelict\sdl\image.d(125): !(TemplateArgumentList) expected fol
lowing TemplateIdentifier


BUILDING DerelictSDLMixer...
DerelictSDLMixer\derelict\sdl\mixer.d(327): !(TemplateArgumentList) expected fol
lowing TemplateIdentifier


BUILDING DerelictSDLNet...
DerelictSDLNet\derelict\sdl\net.d(97): !(TemplateArgumentList) expected followin
g TemplateIdentifier
DerelictSDLNet\derelict\sdl\net.d(102): !(TemplateArgumentList) expected followi
ng TemplateIdentifier
DerelictSDLNet\derelict\sdl\net.d(256): !(TemplateArgumentList) expected followi
ng TemplateIdentifier


BUILDING DerelictSDLttf...
DerelictSDLttf\derelict\sdl\ttf.d(218): !(TemplateArgumentList) expected followi
ng TemplateIdentifier


BUILDING DerelictUtil...
DerelictUtil\derelict\util\loader.d(29): !(TemplateArgumentList) expected follow
ing TemplateIdentifier
DerelictUtil\derelict\util\loader.d(3Cool: !(TemplateArgumentList) expected follow
ing TemplateIdentifier
DerelictUtil\derelict\util\loader.d(3Cool: !(TemplateArgumentList) expected follow
ing TemplateIdentifier
DerelictUtil\derelict\util\loader.d(45): !(TemplateArgumentList) expected follow
ing TemplateIdentifier
DerelictUtil\derelict\util\loader.d(46): !(TemplateArgumentList) expected follow
ing TemplateIdentifier
DerelictUtil\derelict\util\exception.d(106): !(TemplateArgumentList) expected fo
llowing TemplateIdentifier

Any ideas on how to fix this?

As for the question:

I am having trouble understanding how D handles some of the library stuff (.DLLs and .libs). So if I use this library, will I no longer need to have the original .dll files (like SDL.DLL, sdlgfx.dll, etc) in the same directory with my final executable?
Back to top
View user's profile Send private message
JJR



Joined: 22 Feb 2004
Posts: 1104

PostPosted: Sat Aug 13, 2005 1:32 pm    Post subject: Re: Help... Windows Build Failed Reply with quote

gamerChad wrote:
Any ideas on how to fix this?


Not sure. Which version of dmd are you using? What operating system are you using?

gamerChad wrote:
As for the question:

I am having trouble understanding how D handles some of the library stuff (.DLLs and .libs). So if I use this library, will I no longer need to have the original .dll files (like SDL.DLL, sdlgfx.dll, etc) in the same directory with my final executable?


The D *.lib files generated from building derelict are necessary to give you access to the actual *.dll files.

You can think of the derelict*.lib files as the D side of things. The dll's, on the other hand, contain the C code for the actual libraries: SDL, GLFW, etc. These dll's are usually provided separately. The derelict *.lib files contain D code that load the C dll and its symbols and allow you to access the C graphics functions in a pain-free manner.

The benefit of Derelict is that you just have to link with the small Derelict *.lib file when building your own program. There is no need to link up with an import library or figure out how to load the dll. That's all taken care of for you within the Derelict*.lib. The only requirement is that you know that the particular dll exists somewhere in your systems search path. If it doesn't exist somewhere, Derelict knows how to catch this error gracefully.

-JJR
Back to top
View user's profile Send private message
gamerChad



Joined: 13 Aug 2005
Posts: 21
Location: Cydonia, Mars

PostPosted: Sat Aug 13, 2005 5:21 pm    Post subject: Reply with quote

The DMD is version 7.51 build 020
The OS is Windows XP Home Ed SP1... Win32.

Just for convenience I'll toss in some of the code that wasn't happy from one of the files (loader.d).

BUILDING DerelictUtil...
Code:
DerelictUtil\derelict\util\loader.d(29): !(TemplateArgumentList) expected following TemplateIdentifier
26: SharedLib Derelict_LoadSharedLib(char[] libName)
27: in
28: {
29:    assert(libName !is null);
30: }
31: body
32: {
33:    return Platform_LoadSharedLib(libName);   
34: }


Code:
DerelictUtil\derelict\util\loader.d(38): !(TemplateArgumentList) expected following TemplateIdentifier
DerelictUtil\derelict\util\loader.d(38): !(TemplateArgumentList) expected following TemplateIdentifier
36: void Derelict_UnloadSharedLib(SharedLib lib)
37: {
38:    if(lib !is null && lib._handle !is null)
39:       Platform_UnloadSharedLib(lib);
40: }


Code:
DerelictUtil\derelict\util\loader.d(45): !(TemplateArgumentList) expected following TemplateIdentifier
42: void* Derelict_GetProc(SharedLib lib, char[] procName)
43: in
44: {
45:    assert(lib !is null);
46:    assert(procName !is null);
47: }
48: body
49: {
50:    if(lib._handle is null)
51:       throw new InvalidSharedLibHandleException(lib._name);
52:    return Platform_GetProc(lib, procName);   
53: }
Back to top
View user's profile Send private message
aldacron



Joined: 05 May 2004
Posts: 1322
Location: Seoul, South Korea

PostPosted: Sat Aug 13, 2005 6:33 pm    Post subject: Reply with quote

gamerChad wrote:
The DMD is version 7.51 build 020


There's no such thing as DMD 7.51. The current version is 0.129, and I just verified again that it builds Derelict just fine (as I did when it was released). Something seems amiss on your end.
Back to top
View user's profile Send private message Send e-mail
JJR



Joined: 22 Feb 2004
Posts: 1104

PostPosted: Sat Aug 13, 2005 7:24 pm    Post subject: Reply with quote

The error appears to be occurring at the "!is" statement. I would check what version of dmd you have (like Mike said, the version you mention is non existant).

It appears the dmd version that you are using doesn't understand the fairly new "!is" statement. It seems to be mistaking it for a template instantiation statement (which also uses the exclamation point). That certainly shouldn't be happening with an up to date dmd compiler (0.129).

Can you try running "dmd" at the command prompt and see what it prints out?

-JJR
Back to top
View user's profile Send private message
gamerChad



Joined: 13 Aug 2005
Posts: 21
Location: Cydonia, Mars

PostPosted: Sat Aug 13, 2005 8:07 pm    Post subject: Reply with quote

Ah! I was looking in the wrong place for the version number. Running dmd at command gives me v0.125.

OK I've redownloaded the D compiler, linker, and such. Now it shows v0.129. Those error messages went away, but were replaced by the following :

BUILDING DerelictAL...
DerelictAL\derelict\openal\al.d(146): module loader cannot read file 'derelict\u
til\loader.d'


BUILDING DerelictGL...
DerelictGL\derelict\opengl\internal.d(3): module loader cannot read file 'dereli
ct\util\loader.d'


BUILDING DerelictGLFW...
DerelictGLFW\derelict\glfw\glfw.d(44): module loader cannot read file 'derelict\
util\loader.d'


BUILDING DerelictGLU...
DerelictGLU\derelict\opengl\glu.d(35): module gltypes cannot read file 'derelict
\opengl\gltypes.d'


BUILDING DerelictSDL...
DerelictSDL\derelict\sdl\sdl.d(25): module loader cannot read file 'derelict\uti
l\loader.d'


BUILDING DerelictSDLImage...
DerelictSDLImage\derelict\sdl\image.d(2Cool: module sdl cannot read file 'derelict
\sdl\sdl.d'


BUILDING DerelictSDLMixer...
DerelictSDLMixer\derelict\sdl\mixer.d(27): module types cannot read file 'dereli
ct\sdl\types.d'


BUILDING DerelictSDLNet...
DerelictSDLNet\derelict\sdl\net.d(27): module sdl cannot read file 'derelict\sdl
\sdl.d'


BUILDING DerelictSDLttf...
DerelictSDLttf\derelict\sdl\ttf.d(33): module sdl cannot read file 'derelict\sdl
\sdl.d'


BUILDING DerelictUtil...
Digital Mars Librarian Version 8.00n
Copyright (C) Digital Mars 2000-2002 All Rights Reserved www.digitalmars.com

Error: cannot open response file
Back to top
View user's profile Send private message
aldacron



Joined: 05 May 2004
Posts: 1322
Location: Seoul, South Korea

PostPosted: Sun Aug 14, 2005 2:39 am    Post subject: Reply with quote

I'm trying to reproduce this on my end and I just can't. It now looks like the import paths aren't getting set correctly, which they should be since it's all set in the scripts. Did you move anything around? Do me a favor and let me know your directory tree srtucture for Derelict, as well as what you are doing step-by-step to compile.

My initial thought was that you were calling buildme.bat from outside the Derelict tree, but trying that on my system produces different results.
Back to top
View user's profile Send private message Send e-mail
gamerChad



Joined: 13 Aug 2005
Posts: 21
Location: Cydonia, Mars

PostPosted: Sun Aug 14, 2005 12:10 pm    Post subject: Reply with quote

To my knowledge, I didn't move anything around. What I suspect (though unlikely) is that my SVN browser did at checkout. One problem with that is that the files all seem to be there.

Step 1: I check out the files from the repository. The util I am using is TortoiseSVN.
Step 2: I run command prompt.
Step 3: CD C:\Loadz\D Language\Derelict\
Step 4: buildme
Step 5: Sad

I also tried entering "buildconfig" just before entering "buildme", and that didn't seem to do anything.

Here is my directory structure:


C:\Loadz\D language\Derelict
build_dbg.brf
build_release.brf
buildconfig.bat
buildme.bat
cleanlib.bat
README

6 files; 2,087 bytes

C:\Loadz\D language\Derelict\DerelictAL
buildme.bat
example.d
Makefile.linux
README

4 files; 6,958 bytes

C:\Loadz\D language\Derelict\DerelictAL\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictAL\derelict\openal
al.d
alctypes.d
altypes.d
alu.d

4 files; 17,831 bytes

C:\Loadz\D language\Derelict\DerelictGL
buildme.bat
example.d
license.txt
Makefile.linux
README

5 files; 8,232 bytes

C:\Loadz\D language\Derelict\DerelictGL\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictGL\derelict\opengl
gl.d
glfuncs.d
gltypes.d
glx.d
internal.d
wgl.d
wingdi.d

7 files; 114,172 bytes

C:\Loadz\D language\Derelict\DerelictGLFW
buildme.bat
example.d
Makefile.linux
README

4 files; 10,723 bytes

C:\Loadz\D language\Derelict\DerelictGLFW\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictGLFW\derelict\glfw
glfw.d

1 file; 30,115 bytes

C:\Loadz\D language\Derelict\DerelictGLU
buildme.bat
example.d
Makefile.linux
README

4 files; 6,944 bytes

C:\Loadz\D language\Derelict\DerelictGLU\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictGLU\derelict\opengl
glu.d

1 file; 22,707 bytes

C:\Loadz\D language\Derelict\DerelictSDL
buildme.bat
example.d
Makefile.linux
README

4 files; 9,979 bytes

C:\Loadz\D language\Derelict\DerelictSDL\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictSDL\derelict\sdl
active.d
audio.d
byteorder.d
cdrom.d
cpuinfo.d
endian.d
error.d
events.d
joystick.d
keyboard.d
keysym.d
loadso.d
mouse.d
mutex.d
rwops.d
sdl.d
sdlversion.d
syswm.d
thread.d
timer.d
types.d
video.d

22 files; 83,436 bytes

C:\Loadz\D language\Derelict\DerelictSDLImage
buildme.bat
example.d
Makefile.linux
README

4 files; 7,106 bytes

C:\Loadz\D language\Derelict\DerelictSDLImage\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictSDLImage\derelict\sdl
image.d

1 file; 5,506 bytes

C:\Loadz\D language\Derelict\DerelictSDLMixer
buildme.bat
example.d
Makefile.linux
README

4 files; 7,107 bytes

C:\Loadz\D language\Derelict\DerelictSDLMixer\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictSDLMixer\derelict\sdl
mixer.d

1 file; 16,043 bytes

C:\Loadz\D language\Derelict\DerelictSDLNet
buildme.bat
example.d
Makefile.linux
README

4 files; 7,023 bytes

C:\Loadz\D language\Derelict\DerelictSDLNet\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictSDLNet\derelict\sdl
net.d

1 file; 10,378 bytes

C:\Loadz\D language\Derelict\DerelictSDLttf
buildme.bat
example.d
Makefile.linux
README

4 files; 6,880 bytes

C:\Loadz\D language\Derelict\DerelictSDLttf\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictSDLttf\derelict\sdl
ttf.d

1 file; 11,026 bytes

C:\Loadz\D language\Derelict\DerelictUtil
buildme.bat
Makefile.linux

2 files; 968 bytes

C:\Loadz\D language\Derelict\DerelictUtil\derelict
0 files; 0 bytes

C:\Loadz\D language\Derelict\DerelictUtil\derelict\util
exception.d
loader.d

2 files; 5,281 bytes

C:\Loadz\D language\Derelict\docs
al.html
build.html
credit.html
gl.html
glfw.html
glu.html
index.html
index_a.html
loading.html
sdl.html
sdlimg.html
sdlmix.html
sdlnet.html
sdlttf.html
selective.html
toc.html
util.html

17 files; 65,409 bytes

C:\Loadz\D language\Derelict\examples
sdl_ex1.d

1 file; 3,400 bytes

C:\Loadz\D language\Derelict\lib
0 files; 0 bytes
Back to top
View user's profile Send private message
aldacron



Joined: 05 May 2004
Posts: 1322
Location: Seoul, South Korea

PostPosted: Mon Aug 15, 2005 12:41 am    Post subject: Reply with quote

I'm stumped. I haven't the slightest idea what could be causing this, and anything I can think of is just a wild guess. The only thing that comes to mind now is that maybe some of the files are corrupt. Perhaps you should try checking out the trunk again. I'll have to think about this some more and experiment on my end to try and reproduce what you are seeing.
Back to top
View user's profile Send private message Send e-mail
gamerChad



Joined: 13 Aug 2005
Posts: 21
Location: Cydonia, Mars

PostPosted: Mon Aug 15, 2005 2:49 am    Post subject: Reply with quote

Whoa. I think I found the evil bug. notice my directory was
C:\Loadz\D Language\Derelict
I wondered if maybe the space in "D Language" was causing the problem - so I moved the files into C:\Loadz\Derelict. Build success.
I'd place my bet on the problem being with how either Derelict or Build parses file paths. One of them doesn't like spaces.
Anyhow, thanks for all of the help! I probably would have never caught that compiler version thing, or it would have taken me a looong time.
Back to top
View user's profile Send private message
aldacron



Joined: 05 May 2004
Posts: 1322
Location: Seoul, South Korea

PostPosted: Mon Aug 15, 2005 5:15 am    Post subject: Reply with quote

Good catch. It's a dmd issue, not Derelict or Build.
Back to top
View user's profile Send private message Send e-mail
lemon



Joined: 11 Nov 2005
Posts: 4

PostPosted: Mon Nov 14, 2005 12:49 pm    Post subject: Reply with quote

I was having the same problem.

Unfortunately my files are under:

C:\Documents and Settings\dwl\My Documents\code\Derelict\

Throw organization out the window! Also, I wonder if the spaces thing was keeping dmd from working when it was under the "Program Files" directory.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> Derelict All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group