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

Author Topic: Building the SFML aplication on MAC - sfml-system-d not found  (Read 1946 times)

0 Members and 1 Guest are viewing this topic.

falconmick

  • Newbie
  • *
  • Posts: 17
    • View Profile
Building the SFML aplication on MAC - sfml-system-d not found
« on: November 27, 2012, 02:47:47 pm »
Xcode can't find any of the sfml-system' stuff and I have no idea how to use mac's (well no idea compaired to linux or windows) I had to use terminal just so I could sniff around the back end of the hard drive looking for where it installed SFML (couldn't find it in the end)

=.= the old mac I used to use was easier to use, the explorer actually let u explore the root of the hdd

how can I fix

ld: library not found for -lsfml-system-d

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 10819
    • View Profile
    • development blog
    • Email
Re: Building the SFML aplication on MAC - sfml-system-d not found
« Reply #1 on: November 27, 2012, 03:44:53 pm »
I've no idea about Macs either, but have you been following strictly the official tutorial?
If you do it correctly with Xcode everything should work out fine. ;)
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

falconmick

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: Building the SFML aplication on MAC - sfml-system-d not found
« Reply #2 on: November 27, 2012, 07:31:26 pm »
well, i've changed to framework, add search paths and now I'm getting the following:

Quote
Undefined symbols for architecture i386:
  "sf::RenderWindow::RenderWindow(sf::VideoMode, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned int, sf::ContextSettings const&)", referenced from:
      _main in main.o
  "sf::Font::loadFromFile(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)", referenced from:
      _main in main.o
  "sf::Music::openFromFile(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)", referenced from:
      _main in main.o
  "sf::String::String(char const*, std::__1::locale const&)", referenced from:
      _main in main.o
  "sf::Texture::loadFromFile(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, sf::Rect<int> const&)", referenced from:
      _main in main.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

=.= I know nothing about xcode waah

izackp

  • Newbie
  • *
  • Posts: 5
    • View Profile
    • Email
Re: Building the SFML aplication on MAC - sfml-system-d not found
« Reply #3 on: November 27, 2012, 07:48:03 pm »
Compiling for xcode doesn't work out of the box. First you need to install the FreeType framework from http://www.kyngchaos.com/software/frameworks

Then the current xcode project uses debug libraries.. which you have to build yourself, or you can remove the -d for all of the libraries in the project settings file so it builds with the release libraries. Instead of sfml-system-d use sfml-system.

This method is if you're using the dylib libraries for sfml 2.0 . I haven't tried the .framework yet.

I can't remember anything else I did, but if you're still having problems then post them and I'll help you.
« Last Edit: November 27, 2012, 07:50:04 pm by izackp »
Meh Blog: iDevStudio

PaulTheGeek

  • Newbie
  • *
  • Posts: 3
    • View Profile
    • Email
Re: Building the SFML aplication on MAC - sfml-system-d not found
« Reply #4 on: November 28, 2012, 04:54:49 pm »
To fix this issue you will need to change the compiler settings within Xcode. This is somewhat referenced in the setup tutorial http://www.sfml-dev.org/tutorials/2.0/start-osx.php eXpl0it3r mentioned. The specific section is in the introduction section under the C++11 subsection. However I will admit it that the tutorial does not work out of the box as it seems Xcode sets the default C++ Standard Library to custom version Apple ships with Xcode. Let me know If I am wrong on this point.

Anyway, to the meat of the matter. To fix this issue please follow these steps:
1. Go to the Build Settings for you project
2. Go to the Apple LLVM compiler 4.1 - Language section
3. You will see a C++ Standard Library option. There will be three options here and you want to choose Compiler Default

I included a screenshot so you can see where this is incase you are unsure if you are on the proper screen. Let me know if this helps.

[attachment deleted by admin]

 

anything