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

Author Topic: SFML download help  (Read 3009 times)

0 Members and 1 Guest are viewing this topic.

Thenightfoe

  • Newbie
  • *
  • Posts: 9
    • View Profile
SFML download help
« on: January 03, 2014, 12:13:11 am »
This is my first time on this forum so please forgive me if this is in the wrong section but I can't seem to find a solution anywhere. I want to know how to properly download SFML 2.1 on Ubuntu **Linux**. I've tried following the command prompt option: "sudo apt-get install libsfml-dev" but that only has 1.6 and I want 2.1. So then I tried the next option of downloading the SDK but I don't know were to put it, I don't want to have a "personal path" I want to have it work like all the other library's. Is there a way I can download SFML so that it can be used normally? Also if I need to put the SDK somewhere, were do I put it? Also I can't really move files in certain places it says "access denied". I'm very new to this any help would be awesome.

Daddi

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
    • http://foxdev.de/
    • Email
Re: SFML download help
« Reply #1 on: January 03, 2014, 12:36:01 am »
On http://www.sfml-dev.org/download/sfml/2.1/ you download the Linux GCC - 64 bits libs.

Inside you will find an "include" and a "lib" folder. The content of the include folder goes into /usr/local/include/ while the lib folders content goes to /usr/local/lib/. After that, gcc should be able to find the headers and libraries :)

Thenightfoe

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: SFML download help
« Reply #2 on: January 03, 2014, 12:40:43 am »
Thanks. But there's also a "share" folder, what do I do with that? And also how to I give myself permission to move these folders?

Daddi

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
    • http://foxdev.de/
    • Email
Re: SFML download help
« Reply #3 on: January 03, 2014, 12:43:24 am »
The permission can be aquired via "sudo" (sudo cp -r ./lib/* /usr/share/lib/).
I'm not sure about the share folder as you don't need it to use sfml.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 10824
    • View Profile
    • development blog
    • Email
Re: SFML download help
« Reply #4 on: January 03, 2014, 12:47:13 am »
I rather suggest to either add Sonkun's package to aptitude and update SFML that way or build from source.

Also if you don't know "basic" Linux things, such as permissions, you'll have a really hard time with Linux and it might be good to read a bit on it first. :)
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Thenightfoe

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: SFML download help
« Reply #5 on: January 03, 2014, 12:50:41 am »
When I use this it says that it cannot stat './lib/*': no such file or directory. Yah I'm still new to Linux command line.

Daddi

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
    • http://foxdev.de/
    • Email
Re: SFML download help
« Reply #6 on: January 03, 2014, 12:53:01 am »
My "code" was just to show how to use sudo, it wasn't meant for you to use, sorry :)
But like eXpl0it3r said, maybe you should start learning Shell-Basics before you head into compiling / linking.

Thenightfoe

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: SFML download help
« Reply #7 on: January 03, 2014, 12:59:26 am »
So really I just need to learn how to move files in command line using sudo. Then I can move the files to the proper locations and then I can finally use SFML.

Daddi

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
    • http://foxdev.de/
    • Email
Re: SFML download help
« Reply #8 on: January 03, 2014, 01:02:05 am »
A better way would be eXpl0it3rs Link to install it via apt-get. But I think its not uptodate (SFML 2.0 instead of 2.1)

Thenightfoe

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: SFML download help
« Reply #9 on: January 03, 2014, 01:13:20 am »
One last question: Should I move the contents of the SFML-2.1/lib to /usr/local/lib or just the lib file itself?

Thenightfoe

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: SFML download help
« Reply #10 on: January 03, 2014, 01:46:14 am »
Ok so I moved the lib contents to /usr/local/lib but when I run a program using sfml it gives me errors that say undefined references to libGLEW.so.1.5 and libjpeg.so.62. Where would I find these?

Daddi

  • Jr. Member
  • **
  • Posts: 66
    • View Profile
    • http://foxdev.de/
    • Email
Re: SFML download help
« Reply #11 on: January 03, 2014, 01:56:59 am »
These are packages you have to install before you can use SFML. ie libjpeg via "sudo apt-get install libjpeg62". GLEW might be a bit trickier (http://stackoverflow.com/questions/20256085/how-do-i-install-libglew-1-5-for-sfml-2-0)

Thenightfoe

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: SFML download help
« Reply #12 on: January 03, 2014, 02:13:22 am »
Ok so I installed libjpeg62 but when I try to install libglew1.5 it tells me that its already the newest version. So I'm confused on what to do.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 10824
    • View Profile
    • development blog
    • Email
Re: SFML download help
« Reply #13 on: January 03, 2014, 02:17:12 am »
GLEW 1.5 is already older, but it's the version the SFML builds you downloaded are build with. So you either have to get the old libraries (don't ask me, I've no idea) or (better option) build from source. ;)
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Thenightfoe

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: SFML download help
« Reply #14 on: January 03, 2014, 02:21:16 am »
If I build from source do I have to delete the SFML stuff I already have?

 

anything