Jump to content

Compiling Open Source Editor


Ishad Nha

Recommended Posts

I initially could not compile the Open Source Editor on Dev-C++, I got the following error:

427 dlogtool.cpp

implicit declaration of function `int atoi(...)'

The error was corrected by adding this to the

start of dlogtool.cpp:

#include "stdlib.h"

 

So far so good, but then I could not get the linking to work. Can anyone tell me what is an undefined reference and how can I correct it?

There are a few problems with the Editor that I would like to correct.

 

Linking Errors reported were as follows:

c:\dev-c++\examples\blades of exile source

code\blscened.o(.text+0x350):blscened.cpp: undefined reference to

`load_sounds(void)'

c:\dev-c++\examples\blades of exile source

code\blscened.o(.text+0x22f7):blscened.cpp: undefined reference to

`play_sound(short)'

c:\dev-c++\examples\blades of exile source

code\dlogtool.o(.text+0x949):dlogtool.cpp: undefined reference to

`play_sound(short)'

c:\dev-c++\examples\blades of exile source

code\dlogtool.o(.text+0x440d):dlogtool.cpp: undefined reference to

`play_sound(short)'

c:\dev-c++\examples\blades of exile source

code\dlogtool.o(.text+0x4771):dlogtool.cpp: undefined reference to

`play_sound(short)'

c:\dev-c++\examples\blades of exile source

code\graphics.o(.text+0x606):graphics.cpp: undefined reference to

`play_sound(short)'

c:\dev-c++\examples\blades of exile source

code\graphutl.o(.text+0xed6):graphutl.cpp: more undefined references to

`play_sound(short)' follow

Link to comment
Share on other sites

  • 5 weeks later...

I'm pretty sure "undefined reference" means that it can't find a function. Assuming the function actually is defined, this means either it needs to be declared extern or it needs a prototype (also extern I think) in the file that references it (or a file #included by that file, obviously).

 

I think I haven't missed any possibilities here...

Link to comment
Share on other sites

  • 3 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...