473,799 Members | 3,329 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problem with linker

When I go to compile a project I see this error

[Linker error] undefined reference to
`_imp___ZN3irr1 2createDeviceEN S_5video13E_DRI VER_TYPEERKNS_4 core11dimension 2dIiEEjbbbPNS_1 4IEventReceiver EPKw'

someone knows how can I do for delete this error???
Thanks

Nov 23 '05 #1
6 2475
Sampei120 wrote:
When I go to compile a project I see this error

[Linker error] undefined reference to
`_imp___ZN3irr1 2createDeviceEN S_5video13E_DRI VER_TYPEERKNS_4 core11dimension 2dIiEEjbbbPNS_1 4IEventReceiver EPKw'

someone knows how can I do for delete this error???
Thanks


You are missing a function possibly with the name createDevice. Perhaps
the function is just not found by the linker (did you include all the
correct files?), perhaps the parameter types differ between the
prototype/class declaration and the implementation, perhaps the
constness of the function is different. There could be any number of
problems, but we'd need to see some code to figure out what is the
cause of the error.

Cheers! --M

Nov 23 '05 #2
Sampei120 wrote:
When I go to compile a project I see this error

[Linker error] undefined reference to
`_imp___ZN3irr1 2createDeviceEN S_5video13E_DRI VER_TYPEERKNS_4 core11dimension 2dIiEEjbbbPNS_1 4IEventReceiver EPKw'

someone knows how can I do for delete this error???


You need to tell your linker where to find that function. If it is your
function, and you forgot to define it, you need to define it somewhere.

V
Nov 23 '05 #3

mlimber wrote:
You are missing a function possibly with the name createDevice. Perhaps
the function is just not found by the linker (did you include all the
correct files?), perhaps the parameter types differ between the
prototype/class declaration and the implementation, perhaps the
constness of the function is different. There could be any number of
problems, but we'd need to see some code to figure out what is the
cause of the error.

Cheers! --M

Thank you! This is the code...

#include <irrlicht.h>
using namespace irr;
using namespace core;
using namespace scene;
using namespace video;
using namespace io; // Serve per I/O
using namespace gui;
#pragma comment(lib, "Irrlicht.l ib")

int main()
{
// Creation of device
IrrlichtDevice *device = createDevice(ED T_DIRECTX8,
dimension2d<s32 >(640,480),
// ERROR
16,false,false, false,0);

// Creatio scene manager e GUI
IVideoDriver* driver = device->getVideoDriver ();
IGUIEnvironment * guienv = device->getGUIEnvironm ent();
ISceneManager* smgr=device->getSceneManage r();

// Screen
device->setWindowCapti on(L"Irrlicht 1.1");
guienv->addStaticText( L"Ciao Mondo!", rect<int>(10, 10, 70, 22), false,
true,
0, -1, true);

// mesh 3D
IAnimatedMesh* mesh = smgr->getMesh("earth .x");

// Apply the mesh
IAnimatedMeshSc eneNode* node = smgr->addAnimatedMes hSceneNode(mesh );
node->setScale(vecto r3df(40.0,40.0, 40.0));

// Light
smgr->addLightSceneN ode(0, vector3df(0,100 ,-200),
SColor(0,200,20 0,200), 10000.0f,-1);

// Static Camera
smgr->addCameraScene Node(0, vector3df(0,70,-100),
vector3df(0,10, 0));

// Scene
while (device->run())
{
driver->beginScene(tru e, true, SColor(0,0,0,0) );
smgr->drawAll();
guienv->drawAll();
driver->endScene();
}

// risource
device->drop();
return 0;
}

but I don't miss the function... I think...

Nov 23 '05 #4
Sampei120 wrote:
mlimber wrote:
You are missing a function possibly with the name createDevice. Perhaps
the function is just not found by the linker (did you include all the
correct files?), perhaps the parameter types differ between the
prototype/class declaration and the implementation, perhaps the
constness of the function is different. There could be any number of
problems, but we'd need to see some code to figure out what is the
cause of the error.

Cheers! --M
Thank you! This is the code...

#include <irrlicht.h>
using namespace irr;
using namespace core;
using namespace scene;
using namespace video;
using namespace io; // Serve per I/O
using namespace gui;
#pragma comment(lib, "Irrlicht.l ib")


Is this library being linked with your project when you compile and link it?
int main()
{
// Creation of device
IrrlichtDevice *device = createDevice(ED T_DIRECTX8, dimension2d<s32 >(640,480),


Here you call a function, that is not defined in the sources you show,
so presumably you must link with the library mentioned above.

Ben Pope
Nov 23 '05 #5
Ed
Did you check that your lib file "Irrlicht.l ib" is in your default lib
path? If not, I would try adding the path to that library in your
pragma.

#pragma comment(lib, "somepath/Irrlicht.lib")

Ed

Nov 23 '05 #6
Sampei120 wrote:
When I go to compile a project I see this error

[Linker error] undefined reference to
`_imp___ZN3irr1 2createDeviceEN S_5video13E_DRI VER_TYPEERKNS_4 core11dimension 2dIiEEjbbbPNS_1 4IEventReceiver EPKw'

someone knows how can I do for delete this error???
Thanks


Sometimes, the order of the linked libraries makes a difference when the
linker should find what is needed...

Regards,
Peter Jansson
Nov 23 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
8682
by: Georg | last post by:
Hello, I must be doing something wrong, but I don't get it: - compile gcc -c -O -Iinc src/hello.c -o obj/hello.o gcc -c -O -Iinc src/msg_1.c -o obj/msg_1.o gcc -c -O -Iinc src/msg_2.c -o obj/msg_2.o - make library
2
2129
by: Joske | last post by:
Hi, I'm having a similar problem as Scott. A static library with managed C++ functions fails to link in. See http://groups.google.be/groups?q=managed+C%2B% 2B+static+library&start=10&hl=en&lr=&ie=UTF-8&oe=UTF- 8&selm=uXE2ZMiqDHA.2644%40TK2MSFTNGP09.phx.gbl&rnum=14 (BTW why can I find scott's post with Google and not using the msdn web-interface? It seems to have vanished)
3
1481
by: Eric W | last post by:
MS VC++ 7.1 - I have a project with static libs A, B and C where A depends on B anc C, also B depends on C. If I set this up in the project dependency dialog for A the Build environment puts B and C in the command line (seen in the Librarian view of the project settings for A) an as a result I get LNK4006 warnings all over the place. So I am trying to establish dependencies such that A gets rebuilt if source in B or C changes. What I...
4
1309
by: Erik Leunissen | last post by:
Hello all, I want to distribute a shared library (lets call it "parent.so"), which, in turn, is used to create shared libs by invoking the GNU linker (lets call these shared libs "child.so"). When creating "child.so", some code which needs to be incorporated into each "child.so" comes from "parent.so" itself. I fully control how "parent.so" is built, but the problem is that I want to strip all symbols from "parent.so" before...
6
2703
by: John | last post by:
I have 5 native static libraries that are being compiled in Visual Studio 2005 with the /MDd C Runtime option. I have 2 CLR DLLs (all managed code) in Visual Studio 2005 and the /MDd C Runtime setting. They are in the same solution, and compile/link without problems (Debug configuration). I also have 1 mixed-mode CLR DLL that consumes both the static libraries and managed DLLs. It is configured to use the /MDd C Runtime library. When...
3
2123
by: michael | last post by:
Hi All, Not sure if this is a c++ issue or a compiler issue. I have the following in a class: template<class T> bool Utility::getInput(T& i, T low, T up){ bool result = false; if(cin >i){
11
2588
by: ZMY | last post by:
Dear all, I am a real newbie for both python and QNX, but I am still trying to compile Numeric-24.2 under QNX4.25 with python 2.2. I got following error message: $ sudo python setup.py install Password: running install
1
4165
by: Deepath G | last post by:
This is deepath.. I am getting some linker error when i am trying to connect Websphere MQ using Borland C++ Builder 2006 using imqi.hpp on windows. Error Message ----------------------- Error: Unresolved external 'ImqMgr::~ImqMgr()' referenced from C:\DOCUMENTS AND SETTINGS\228753\MY DOCUMENTS\BORLAND STUDIO PROJECTS\DLLEXERCISE\DEBUG_BUILD\MANI.OBJ Error: Unresolved external 'ImqObj::~ImqObj()' referenced from C:\DOCUMENTS AND...
0
1359
by: DevEng | last post by:
Hi all, I am new to Python and trying to embed it into a c/c++ application. I started with examples from the documentation pages and go to the Pure Embedding example (http://docs.python.org/ext/pure-embedding.html). I can compile and run this example on wxDevC++ with a mingwin compiler. However when I tried this with Borland C++ Builder 5 I get linker errors. The code is the same exactly (the same main.c file), the only
6
197
by: vaib | last post by:
hi all , i am facing a funny problem in C . i am using turbo's compiler - the 16 bit compiler for dos . i made a file maximum.h which contains a function declaration , and includes files such as stdio.h . i then made a maximum.c which contains the definition of the function declared in maximum.h . maximum.c also includes maximum.h . then i made a main.c which includes maximum.h and calls the function declared in maximum.h . all the 3...
0
9541
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10485
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10252
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10231
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9073
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7565
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5463
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5585
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4141
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.