1
General / SFML 1.6 On Ubuntu
« on: December 04, 2014, 01:37:19 am »
Hello!
Wow! It has been a while since I was here last! Whats up ? I wonder if there are any other old SFMLers here, give me a shout if you used SFML back in 2009/2010 XD ? Anyway, I decided if I may just want to port an old project to linux http://gcggames.webs.com/WSL/Site/main.html, and I also wanted to use the new release for future proejcts (or port the project over to SFML 2.1). So I made a few switch scripts to switch from SFML 2.1, and SFML 1.6 on my system:
It works fine when I am using SFML 2.1 where the library .so files are in /usr/lib/SFML21 and have a symbolic link to /usr/lib/SFML, and where the include files are in /usr/include/SFMLInclude/SFML21 with another symbolic link to /usr/include/SFML
However while the symbolic links and such work with SFML 1.6 (i.e ls /usr/lib/SFML shows the 1.6 files), the linker cant seem to find the files when I try
The 1.6 files are in /usr/lib/SFML16 and /usr/include/SFMLInclude/SFML16 and the symbolic links seem to work, I tried running ldcondfig but it did nothing.
Any help is appreciated!
Thanks :-)
- TFB
Wow! It has been a while since I was here last! Whats up ? I wonder if there are any other old SFMLers here, give me a shout if you used SFML back in 2009/2010 XD ? Anyway, I decided if I may just want to port an old project to linux http://gcggames.webs.com/WSL/Site/main.html, and I also wanted to use the new release for future proejcts (or port the project over to SFML 2.1). So I made a few switch scripts to switch from SFML 2.1, and SFML 1.6 on my system:
Code: [Select]
#!/bin/bash
if [ $1 = "-h" ] || [ $1 = "--help" ]; then
echo "-h This help diolouge."
echo "-sfml16 Set up SFML 1.6"
echo "-sfml21 Set up SFML 2.1"
echo "-clean Clean all links, do not set up a SFML"
else
echo "Dont mind the clean up errors."
sudo unlink /usr/include/SFML/SFML16
sudo unlink /usr/include/SFML/SFML21
sudo unlink /usr/include/SFML
sudo unlink /usr/lib/SFML16
sudo unlink /usr/lib/SFML21
sudo unlink /usr/lib/SFML/SFML16
sudo unlink /usr/lib/SFML/SFML21
sudo unlikn /usr/lib/SFML
sudo rm /usr/include/SFML
sudo rm /usr/lib/SFML
echo "Clean up complete, starting link."
if [ $1 = "-sfml16" ]; then
sudo ln -s /usr/include/SFMLInclude/SFML16 /usr/include/SFML
sudo ln -s /usr/lib/SFML16 /usr/lib/SFML
else
if [ $1 = "-sfml21" ]; then
sudo ln -s /usr/include/SFMLInclude/SFML21 /usr/include/SFML
sudo ln -s /usr/lib/SFML21 /usr/lib/SFML
fi
fi
fi
It works fine when I am using SFML 2.1 where the library .so files are in /usr/lib/SFML21 and have a symbolic link to /usr/lib/SFML, and where the include files are in /usr/include/SFMLInclude/SFML21 with another symbolic link to /usr/include/SFML
However while the symbolic links and such work with SFML 1.6 (i.e ls /usr/lib/SFML shows the 1.6 files), the linker cant seem to find the files when I try
Code: [Select]
g++ -std=c++11 -L /usr/lib/SFML -m64 -l sfml-graphics -l sfml-window -l sfml-system test.cpp
(I have tried rearranging the commands and omitting the -std=c++11 flag).The 1.6 files are in /usr/lib/SFML16 and /usr/include/SFMLInclude/SFML16 and the symbolic links seem to work, I tried running ldcondfig but it did nothing.
Any help is appreciated!
Thanks :-)
- TFB