Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Linker Problems  (Read 2380 times)

0 Members and 1 Guest are viewing this topic.

Odori no Tsuki

  • Newbie
  • *
  • Posts: 5
    • View Profile
Linker Problems
« on: January 30, 2014, 04:29:05 pm »
Cannot find lsfml-system lsfml-window lsfml-graphics

Not sure what's wrong, the search directory in the linker settings points correctly to the SFML lib folder. I'm using Code::Blocks Linux.
« Last Edit: January 30, 2014, 05:27:23 pm by Odori no Tsuki »

Azaral

  • Full Member
  • ***
  • Posts: 110
    • View Profile
Re: Linker Problems
« Reply #1 on: January 30, 2014, 05:33:19 pm »
Did you put .lib or .a when you listed the libraries? You must exclude them in Code::Blocks. Instead of sfml-graphics.lib, it is just sfml-graphics

Odori no Tsuki

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: Linker Problems
« Reply #2 on: January 30, 2014, 05:44:03 pm »
Here's the screenshots of my linker settings and path.



Azaral

  • Full Member
  • ***
  • Posts: 110
    • View Profile
Re: Linker Problems
« Reply #3 on: January 30, 2014, 05:56:57 pm »
Try just sfml-system instead of libsfml-system.

Odori no Tsuki

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: Linker Problems
« Reply #4 on: January 30, 2014, 06:00:59 pm »
Still cannot find it. I'm so confused, I've checked to make sure that the files are in the lib folder too and everything checks out. ._.

Odori no Tsuki

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: Linker Problems
« Reply #5 on: January 30, 2014, 06:09:16 pm »
Wow I forgot this is a 32 bit install. I used this image for a friends 32 bit comp and when I didn't realize when I installed it ._.  I was using the 64bit SFML. Sorry for wasting your time, thanks for the help.

If I statically link it (proper terminology?) I get this in the build logs:

g++ -L/home/odori/SFML-2.1/lib  -o bin/Debug/theMoonRisingSMFL obj/Debug/main.o    /home/odori/SFML-2.1/lib/libsfml-system.so
/home/odori/SFML-2.1/lib/libsfml-system.so: error adding symbols: File in wrong format
collect2: error: ld returned 1 exit status
Process terminated with status 1 (0 minutes, 0 seconds)
0 errors, 0 warnings (0 minutes, 0 seconds)

 
« Last Edit: January 30, 2014, 06:19:57 pm by Odori no Tsuki »

Azaral

  • Full Member
  • ***
  • Posts: 110
    • View Profile
Re: Linker Problems
« Reply #6 on: January 30, 2014, 06:27:34 pm »
Are you using the -s extension, ie sfml-system-s ? Are you also including the SFML_STATIC command in the Build Options, #define tab?

Odori no Tsuki

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: Linker Problems
« Reply #7 on: January 30, 2014, 06:31:07 pm »
Everything is working just fine now that I switched to 32bit SFML.

 

anything