Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » Draw, Display, Images, Bitmaps, Icons » To split Images code to "h" & "cpp" file has a link error, "multiple de
To split Images code to "h" & "cpp" file has a link error, "multiple de [message #19652] Mon, 29 December 2008 10:44 Go to previous message
sevenjay is currently offline  sevenjay
Messages: 30
Registered: October 2008
Location: Taiwan
Member
I split "Image tutorial 1" code to "h" & "cpp" file and had some link error: "multiple definition".
C:/upp/out/Image01/MINGW.Debug.Debug_full.Gui.Main\main.o: In function `_ZN8MyImages3ImlEv':
C:/upp/uppsrc/Draw/iml_source.h:33: multiple definition of `MyImages::Iml()'
C:/upp/out/Image01/MINGW.Debug.Debug_full.Gui.Main\image.o:C:/upp/uppsrc/Draw/iml_source.h:33: first defined here
...
...

After executing TheIDE, compiling It was success at first time. I modify something then compile it was fail.
It both happened on Ubuntu and Windows using gcc.
The Attachment is a sample code.

But I move the definition
#define IMAGECLASS MyImages
#define IMAGEFILE  <Image01/images.iml>
#include <Draw/iml.h>

from .h to .cpp. then it is success all the time.
so...maybe this is not a bug?

Thank you for creating so useful tool.
  • Attachment: Image01.zip
    (Size: 1.66KB, Downloaded 342 times)

[Updated on: Mon, 29 December 2008 10:45]

Report message to a moderator

 
Read Message
Read Message
Read Message
Previous Topic: Compile package with iml file problem!
Next Topic: Conditional jump or move depends on uninitialised value(s)
Goto Forum:
  


Current Time: Fri Apr 26 07:31:38 CEST 2024

Total time taken to generate the page: 0.05710 seconds