I’m using SDL2 and I’ve just been adding some SDL2_gfx functionality to my program. In Windows, I’m using the pre-built 2.0.0 SDL2, and I’ve compiled R5 of SDL2_gfx. That works fine.
So I’ve started adding it to Linux. I built SDL2 from source using the 2.0.0 stable source release. I built R5 of SDL2_gfx. However, my program compiles but then fails to link, saying there are multiple definitions of several functions. These are:
If I comment out those 3 function calls it links fine, of course.
As far as I can tell, everything is identical between the two setups (same linking order and everything), so what on earth is causing the Linux version to freak out? How can this problem only occur in Linux and not Windows? How can I fix it?
Do the error messages point you to the definitions that are conflicting?
Turn on or install debugging symbols if they don’t.
Is it possible that you’re including the wrong headers? If an older
version of SDL_gfx (say, for SDL 1.2) is installed and your compiler
includes those headers, you may get some interference if the functions are
defined inline, etc.
Jonny DOn Sun, Oct 20, 2013 at 7:09 PM, Dark_Oppressor wrote:
**
I’m using SDL2 and I’ve just been adding some SDL2_gfx functionality to my
program. In Windows, I’m using the pre-built 2.0.0 SDL2, and I’ve compiled
R5 of SDL2_gfx. That works fine.
So I’ve started adding it to Linux. I built SDL2 from source using the
2.0.0 stable source release. I built R5 of SDL2_gfx. However, my program
compiles but then fails to link, saying there are multiple definitions of
several functions. These are:
If I comment out those 3 function calls it links fine, of course.
As far as I can tell, everything is identical between the two setups (same
linking order and everything), so what on earth is causing the Linux
version to freak out? How can this problem only occur in Linux and not
Windows? How can I fix it?
**
I’m using SDL2 and I’ve just been adding some SDL2_gfx functionality to my
program. In Windows, I’m using the pre-built 2.0.0 SDL2, and I’ve compiled
R5 of SDL2_gfx. That works fine.
So I’ve started adding it to Linux. I built SDL2 from source using the
2.0.0 stable source release. I built R5 of SDL2_gfx. However, my program
compiles but then fails to link, saying there are multiple definitions of
several functions. These are:
If I comment out those 3 function calls it links fine, of course.
As far as I can tell, everything is identical between the two setups (same
linking order and everything), so what on earth is causing the Linux
version to freak out? How can this problem only occur in Linux and not
Windows? How can I fix it?
On Sun, Oct 20, 2013 at 4:09 PM, Dark_Oppressor <DarkOppressor at gmail.com (DarkOppressor at gmail.com)> wrote:
I'm using SDL2 and I've just been adding some SDL2_gfx functionality to my program. In Windows, I'm using the pre-built 2.0.0 SDL2, and I've compiled R5 of SDL2_gfx. That works fine.
So I’ve started adding it to Linux. I built SDL2 from source using the 2.0.0 stable source release. I built R5 of SDL2_gfx. However, my program compiles but then fails to link, saying there are multiple definitions of several functions. These are:
If I comment out those 3 function calls it links fine, of course.
As far as I can tell, everything is identical between the two setups (same linking order and everything), so what on earth is causing the Linux version to freak out? How can this problem only occur in Linux and not Windows? How can I fix it?
On Sun, Oct 20, 2013 at 4:09 PM, Dark_Oppressor <> wrote:
Quote:
I’m using SDL2 and I’ve just been adding some SDL2_gfx functionality to
my program. In Windows, I’m using the pre-built 2.0.0 SDL2, and I’ve
compiled R5 of SDL2_gfx. That works fine.
So I’ve started adding it to Linux. I built SDL2 from source using the
2.0.0 stable source release. I built R5 of SDL2_gfx. However, my program
compiles but then fails to link, saying there are multiple definitions of
several functions. These are:
If I comment out those 3 function calls it links fine, of course.
As far as I can tell, everything is identical between the two setups (same
linking order and everything), so what on earth is causing the Linux
version to freak out? How can this problem only occur in Linux and not
Windows? How can I fix it?
On Sun, Oct 20, 2013 at 4:09 PM, Dark_Oppressor <> wrote:
Quote:
I’m using SDL2 and I’ve just been adding some SDL2_gfx functionality to
my program. In Windows, I’m using the pre-built 2.0.0 SDL2, and I’ve
compiled R5 of SDL2_gfx. That works fine.
So I’ve started adding it to Linux. I built SDL2 from source using the
2.0.0 stable source release. I built R5 of SDL2_gfx. However, my program
compiles but then fails to link, saying there are multiple definitions of
several functions. These are:
If I comment out those 3 function calls it links fine, of course.
As far as I can tell, everything is identical between the two setups
(same linking order and everything), so what on earth is causing the Linux
version to freak out? How can this problem only occur in Linux and not
Windows? How can I fix it?