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

Author Topic: SFML and V8  (Read 1994 times)

0 Members and 1 Guest are viewing this topic.

Caleb P

  • Newbie
  • *
  • Posts: 4
    • View Profile
SFML and V8
« on: May 28, 2014, 06:12:13 pm »
I'm trying to use SFML as my graphics backbone for a C++ game engine. I'm also using the V8 JavaScript engine. The problem is, to get V8 to compile, I've got to use -stdlib=libstdc++, and to get SFML to compile, I've got to use -stdlib=libc++. Obviously, I can't use both, so how can I work around this?

I'm using Xcode on a Mac Mini, by the way, but it doesn't work through the terminal either.

- C
« Last Edit: May 28, 2014, 06:40:45 pm by Caleb P »

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Re: SFML and V8
« Reply #1 on: May 29, 2014, 11:27:46 am »
Why do you need a specific standard library for each library, what exactly is the constraint here?
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

select_this

  • Full Member
  • ***
  • Posts: 130
  • Current mood: just ate a pinecone
    • View Profile
    • darrenferrie.com
Re: SFML and V8
« Reply #2 on: May 29, 2014, 11:37:17 am »
libc++ is currently not feature-complete on several platforms, so I'd be quite surprised if SFML relied on it.
Follow me on Twitter, why don'tcha? @select_this

Hiura

  • SFML Team
  • Hero Member
  • *****
  • Posts: 4321
    • View Profile
    • Email
Re: SFML and V8
« Reply #3 on: May 29, 2014, 11:41:20 am »
If you really need to post the same message across the Internet, at least add a reference to it... I'm not going to copy past my answer here. http://stackoverflow.com/questions/23916911/building-sfml-and-v8

@select_this: On OS X, if you want C++11 support you have to play with Apple's rules or face nightmares. In this case, you'd better use libc++ since the provided libstdc++ binary is really old. But SFML works with both anyway.
SFML / OS X developer

select_this

  • Full Member
  • ***
  • Posts: 130
  • Current mood: just ate a pinecone
    • View Profile
    • darrenferrie.com
Re: SFML and V8
« Reply #4 on: May 29, 2014, 11:45:19 am »
Ah okay, my ignorance of all things Apple once again shines through. Thanks for the correction!

EDIT: found some literature from someone who got libv8 to compile with libc++ here - it might be useful info for you.
« Last Edit: May 29, 2014, 12:27:39 pm by select_this »
Follow me on Twitter, why don'tcha? @select_this

Caleb P

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: SFML and V8
« Reply #5 on: May 30, 2014, 12:33:13 pm »
Thanks to everyone - at the moment, @Hiura's answer works, but I think I'll try compiling V8 with libc++ and see where that takes me.

Thanks again :)

- C

 

anything