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

Existing Symbols not found in a lib ( symbol undefined )

 
Post new topic   Reply to topic     Forum Index -> Visual D
View previous topic :: View next topic  
Author Message
ParticlePeter



Joined: 19 Nov 2011
Posts: 49
Location: Germany

PostPosted: Thu Nov 24, 2011 8:44 am    Post subject: Existing Symbols not found in a lib ( symbol undefined ) Reply with quote

Hi,

I am new to D but I think I've done my homework, nevertheless must have screwed up some VisualD settings.

The library I am talking about is Derelict2, as well as the build Objectfile. The libs themselves are found on the lib path ( othervise linker would complain, been there ). The imports are properly set as well ( othervise ... well compiler error ). The SDL.dll is in a System Path. I am using DMD2.
Meanwhile I tried with codeblocks, and everything is working fine ther. But I would prefere VisualD. Here is the Linker Error, maybe somebody can tell me what I might have set wrong, or which setting I could tweak to fix the issue.

Thx, cheers, ParticlePeter !


Object Errors:

OPTLINK (R) for Win32 Release 8.00.12
Copyright (C) Digital Mars 1989-2010 All rights reserved.
http://www.digitalmars.com/ctg/optlink.html
Release\Derelict_01.obj(Derelict_01)
Error 42: Symbol Undefined _D8derelict4util6compat9toDStringFPxaZAya
Release\Derelict_01.obj(Derelict_01)
Error 42: Symbol Undefined _D8derelict6opengl2gl10DerelictGLC8derelict6opengl2gl16DerelictGLLoader
Release\Derelict_01.obj(Derelict_01)
Error 42: Symbol Undefined _D8derelict4util6compat12__ModuleInfoZ
Release\Derelict_01.obj(Derelict_01)


Lib Error:

Error 42: Symbol Undefined _D8derelict6opengl2gl12__ModuleInfoZ
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader19isAutoUnloadEnabledFZb
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader4loadMFZv
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader10loadSymbolMFAyaZPv
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader4loadMFAyaZv
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader7__ClassZ
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader6unloadMFZv
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader8isLoadedMFZb
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader4loadMFAAyaZv
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader3libMFZC8derelict4util9sharedlib9SharedLib
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader12__ModuleInfoZ
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader8bindFuncMFPPvAyabZv
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdltypes)
Error 42: Symbol Undefined _D8derelict4util8wintypes12__ModuleInfoZ
F:\Code\D\Derelict2\lib\DerelictSDL.lib(sdl)
Error 42: Symbol Undefined _D8derelict4util6loader15SharedLibLoader6__ctorMFAyaAyaAyaZC8derelict4util6loader15SharedLibLoader
--- errorlevel 17
Building Release\Derelict_01.exe failed!
_________________
Cheers, searching for the Pivot of my Soul, PP
Back to top
View user's profile Send private message
sagitario



Joined: 03 Mar 2007
Posts: 292

PostPosted: Fri Nov 25, 2011 1:18 am    Post subject: Reply with quote

Hi,

I haven't tried to compile derelict lately, but from the errors you receive I suspect that either some libraries are not specified (e.g. DerelictUtil.lib and something related to OpenGL - just guessing from the derelict2 source tree), or that you are building the library with different version switches than the executable.

BTW: If you are unfamiliar with the D name mangling, you can check the Error List Window, the symbols shown by the linker are demangled there.

Rainer
Back to top
View user's profile Send private message
ParticlePeter



Joined: 19 Nov 2011
Posts: 49
Location: Germany

PostPosted: Sun Nov 27, 2011 2:47 pm    Post subject: Reply with quote

Hi,

thx for your reply. Thats a cool feature in the error list window Smile

I found my mistake, I added the libraries in the VisualD Project Pref window this way:
DerelictSDL.lib;DerelictGL.lib;DerelictUtil.lib

Instead of this way, which is the right way.
DerelictSDL.lib DerelictGL.lib DerelictUtil.lib
_________________
Cheers, searching for the Pivot of my Soul, PP
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> Visual D 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