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

Build problem. DMD version dependant ?

 
Post new topic   Reply to topic     Forum Index -> Build
View previous topic :: View next topic  
Author Message
DMINATOR



Joined: 20 Jun 2006
Posts: 15
Location: Tallinn, Estonia

PostPosted: Tue Jun 20, 2006 11:57 am    Post subject: Build problem. DMD version dependant ? Reply with quote

I have recently installed new DMD version, after that I am receiving new errors, when using build.

Here is a sample program
Code:

import std.stdio;

int main()
{
   writef(" lalal \n");
   return 0;
}


Here is build command
Quote:

build.exe main.d


Here is the result
Quote:

C:\Documents and Settings\Dmitri\My Documents\D_Samples\Four>build.exe main.d
OPTLINK (R) for Win32 Release 7.50B1
Copyright (C) Digital Mars 1989 - 2001 All Rights Reserved

C:\dmd\lib\phobos.lib(ti_double) Offset 1C75EH Record Type 0091
Error 1: Previous Definition Different : __init_10TypeInfo_d
C:\dmd\lib\phobos.lib(ti_double) Offset 1C778H Record Type 0091
Error 1: Previous Definition Different : __Class_10TypeInfo_d
C:\dmd\lib\phobos.lib(ti_double) Offset 1C791H Record Type 0091
Error 1: Previous Definition Different : __vtbl_10TypeInfo_d


Any ideas what could cause this problem ?
Back to top
View user's profile Send private message MSN Messenger
Derek Parnell



Joined: 22 Apr 2004
Posts: 408
Location: Melbourne, Australia

PostPosted: Tue Jun 20, 2006 4:55 pm    Post subject: Re: Build problem. DMD version dependant ? Reply with quote

DMINATOR wrote:
I have recently installed new DMD version, after that I am receiving new errors, when using build.

Here is a sample program
Code:

import std.stdio;

int main()
{
   writef(" lalal \n");
   return 0;
}


Here is build command
Quote:

build.exe main.d


Here is the result
Quote:

C:\Documents and Settings\Dmitri\My Documents\D_Samples\Four>build.exe main.d
OPTLINK (R) for Win32 Release 7.50B1
Copyright (C) Digital Mars 1989 - 2001 All Rights Reserved

C:\dmd\lib\phobos.lib(ti_double) Offset 1C75EH Record Type 0091
Error 1: Previous Definition Different : __init_10TypeInfo_d
C:\dmd\lib\phobos.lib(ti_double) Offset 1C778H Record Type 0091
Error 1: Previous Definition Different : __Class_10TypeInfo_d
C:\dmd\lib\phobos.lib(ti_double) Offset 1C791H Record Type 0091
Error 1: Previous Definition Different : __vtbl_10TypeInfo_d


Any ideas what could cause this problem ?

It is caused because Build is following the OptLink specs but OptLink isn't. Try using Build with the -R=No switch.

I'm about to fix this issue.
_________________
--
Derek
skype name: derek.j.parnell
Back to top
View user's profile Send private message
DMINATOR



Joined: 20 Jun 2006
Posts: 15
Location: Tallinn, Estonia

PostPosted: Wed Jun 21, 2006 12:04 pm    Post subject: Reply with quote

yep it works. Thank you.
Back to top
View user's profile Send private message MSN Messenger
JoeCoder



Joined: 29 Oct 2005
Posts: 294

PostPosted: Sat Oct 21, 2006 10:24 pm    Post subject: Reply with quote

I'm getting this same error, but with my own custom build script. Here's what it calls on the command line:
Code:
Compiling...
dmd -O -inline -release -IC:\myfiles\eric\current\yage\lib -od..\bin\obj -op -c core\all.d core\free
list.d core\horde.d core\matrix.d core\misc.d core\plane.d core\quatrn.d core\timer.d core\tree.d co
re\vector.d core\xmld\error.d core\xmld\misc.d core\xmld\xml.d core\xmld\xmlnode.d core\xmld\xmlstre
am.d main.d node\all.d node\camera.d node\graph.d node\light.d node\model.d node\node.d node\scene.d
 node\sound.d node\sprite.d resource\all.d resource\material.d resource\model.d resource\resource.d
resource\shader.d resource\sound.d resource\texture.d system\all.d system\device.d system\input.d sy
stem\log.d util\all.d util\floatingcamera.d util\misc.d yage.d
Linking...
link core\all.obj+core\freelist.obj+core\horde.obj+core\matrix.obj+core\misc.obj+core\plane.obj+core
\quatrn.obj+core\timer.obj+core\tree.obj+core\vector.obj+core\xmld\error.obj+core\xmld\misc.obj+core
\xmld\xml.obj+core\xmld\xmlnode.obj+core\xmld\xmlstream.obj+device.obj+input.obj+log.obj+main.obj+no
de\all.obj+node\camera.obj+node\graph.obj+node\light.obj+node\model.obj+node\node.obj+node\scene.obj
+node\sound.obj+node\sprite.obj+resource\all.obj+resource\material.obj+resource\model.obj+resource\r
esource.obj+resource\shader.obj+resource\sound.obj+resource\texture.obj+system\all.obj+system\device
.obj+system\input.obj+system\log.obj+util\all.obj+util\floatingcamera.obj+util\misc.obj+yage.obj,yag
e.exe,yage.map,\myfiles\eric\current\yage\lib\derelictAL.lib+\myfiles\eric\current\yage\lib\derelict
GL.lib+\myfiles\eric\current\yage\lib\DerelictGLU.lib+\myfiles\eric\current\yage\lib\DerelictOgg.lib
+\myfiles\eric\current\yage\lib\DerelictSDL.lib+\myfiles\eric\current\yage\lib\DerelictSDLImage.lib+
\myfiles\eric\current\yage\lib\DerelictUtil.lib+\myfiles\eric\current\yage\lib\DerelictVorbis.lib
OPTLINK (R) for Win32  Release 7.50B1
Copyright (C) Digital Mars 1989 - 2001  All Rights Reserved

c:\dev\env\dmd\bin\..\lib\phobos.lib(ti_double)  Offset 022FEH Record Type 0091
 Error 1: Previous Definition Different : __init_10TypeInfo_d
c:\dev\env\dmd\bin\..\lib\phobos.lib(ti_double)  Offset 02318H Record Type 0091
 Error 1: Previous Definition Different : __Class_10TypeInfo_d
c:\dev\env\dmd\bin\..\lib\phobos.lib(ti_double)  Offset 02331H Record Type 0091
 Error 1: Previous Definition Different : __vtbl_10TypeInfo_d
Link failed.  Please fix the errors and try again.


Any ideas? Thanks!
Back to top
View user's profile Send private message
Derek Parnell



Joined: 22 Apr 2004
Posts: 408
Location: Melbourne, Australia

PostPosted: Sat Oct 21, 2006 11:36 pm    Post subject: Reply with quote

I don't know what OptLink is doing here. I'd try to eliminate some of the switches to see how they might effect things. For a start, try compiling without the -O -inline -release -od switches.

Also, can you get it to compile without using Bud? If so, what is the command line you are using to do that? I'm sure if you could it would give me a hint or two.

Finally, ask Walter for the exact meaning and implication of the OptLink error message
Code:

C:\dmd\lib\phobos.lib(ti_double) Offset 1C75EH Record Type 0091
Error 1: Previous Definition Different : __init_10TypeInfo_d

_________________
--
Derek
skype name: derek.j.parnell
Back to top
View user's profile Send private message
JoeCoder



Joined: 29 Oct 2005
Posts: 294

PostPosted: Sun Oct 22, 2006 10:53 pm    Post subject: Reply with quote

I tried removing some of the compiler flags, no effect. I couldn't get Bud to build my project while specifying a lib path as you can see here:
Code:
C:\MyFiles\eric\current\yage\src>bud main.d -clean -PP../lib -LIBPATH=c:\myfiles\eric\current\yage\l
ib derelictAL.lib derelictGl.lib derelictglu.lib derelictogg.lib derelictsdl.lib derelictsdlimage.li
b derelictutil.lib derelictvorbis.lib
OPTLINK (R) for Win32  Release 7.50B1
Copyright (C) Digital Mars 1989 - 2001  All Rights Reserved

derelictAL.lib
 Warning 2: File Not Found derelictAL.lib
derelictutil.lib
 Warning 2: File Not Found derelictutil.lib
derelictsdl.lib
 Warning 2: File Not Found derelictsdl.lib
derelictogg.lib
 Warning 2: File Not Found derelictogg.lib
derelictsdlimage.lib
 Warning 2: File Not Found derelictsdlimage.lib
derelictvorbis.lib
 Warning 2: File Not Found derelictvorbis.lib
derelictglu.lib
 Warning 2: File Not Found derelictglu.lib
derelictGl.lib
 Warning 2: File Not Found derelictGl.lib

However, once I moved derelict in with the source files of my project, and called bud main.d, everything worked fine. I'm assuming that's probably due to my misuse of the LIBPATH option somehow.

I normally build my project with Code::Blocks, but keep the buildme script so anyone can build the project with minimal dependencies. After several versions of changes in Code::Blocks, I started noticing the errors I first posted about. I'd added some source modules and changed my code around some, but haven't tracked down exactly what's causing that. Thought it would be easier to just fix the buildme script.

You also mentioned before that Optlink wasn't quite following it's own spec...?
Back to top
View user's profile Send private message
JoeCoder



Joined: 29 Oct 2005
Posts: 294

PostPosted: Mon Oct 23, 2006 5:55 pm    Post subject: Reply with quote

Weird. I just realized that when this happens I can sometimes close and reopen my console window (win32) and run the script again--and it works. It always deletes everything in the temp object file directory before each run and I can't figure out any way it could be modifying environment variables.

Edit
Ok, I just updated from DMD .169 to .172 and everything works now. I keep track of all of the bug fixes and I didn't see anything related to this. Oh well.
Back to top
View user's profile Send private message
torhu



Joined: 30 Mar 2006
Posts: 56

PostPosted: Mon Oct 30, 2006 3:10 am    Post subject: Reply with quote

I have a similar problem with an app that links with DWT.

c:\prog\dm\bin\..\lib\SNN.lib(fputwc) Offset 081B4H Record Type 00C3
Error 1: Previous Definition Different : _putwc

There is no such thing as SNN.lib, by the way. This is with Bud 3.04. With 2.10 everything works just fine. I've tried both dmd 0.168 and 0.172. DWT itself builds fine with Bud 3.04.

Adding -R=No to the command line doesn't change anything. I've tried different command lines, with and without debug and release etc.
Back to top
View user's profile Send private message
Derek Parnell



Joined: 22 Apr 2004
Posts: 408
Location: Melbourne, Australia

PostPosted: Mon Oct 30, 2006 5:22 am    Post subject: Reply with quote

torhu wrote:
I have a similar problem with an app that links with DWT.

I'm not ignoring this issue, it's just that I haven't had the time to deal with it yet. I think I have to download DWT and try to get something compiled myself.
_________________
--
Derek
skype name: derek.j.parnell
Back to top
View user's profile Send private message
torhu



Joined: 30 Mar 2006
Posts: 56

PostPosted: Mon Oct 30, 2006 6:08 am    Post subject: Reply with quote

If you want to try with dwt, you might want to use a version that works with the latest versions of dmd, including 0.172. It was posted as a RAR file somewhere in the dwt forum, I think. This is the dwt version I'm currently using. I couldn't find the thread, but I haved uploaded it as a zip file here:

http://torhus.googlepages.com/dwt-dmd0168.zip
Back to top
View user's profile Send private message
un_guru



Joined: 14 Sep 2005
Posts: 32

PostPosted: Mon Oct 30, 2006 10:21 am    Post subject: Reply with quote

building dwt applications with -Xdwt throws that snn.lib error
you have to remove -Xdwt and it works,
there are cases where it builds even with -Xdwt, I tried but I couln't figure out what causes this.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> Build 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