Giter Club home page Giter Club logo

Comments (12)

bkaradzic avatar bkaradzic commented on May 22, 2024

Thanks for update, I'm still on 10.8.6 here. I'll add this (or if you have changes already you can just send pull request).

I don't use Xcode at all. I use only gmake on OSX/iOS/Android/etc. Did you try to build thru command line?

$ make osx-release64

Anyhow bgfx project files are there just as an example, I assume if anyone is using bgfx that they will just switch to their build system anyway.

For example, building it with CMake:
https://github.com/LoomSDK/LoomSDK/blob/master/loom/graphics/CMakeLists.txt and stripping down library to minimum needed: https://github.com/LoomSDK/LoomSDK/tree/master/loom/graphics/internal

At some point I'll probably provide compiled libs for all targets, but currently I don't have automated way to do it.

from bgfx.

meshula avatar meshula commented on May 22, 2024

I saw you pushed the latest from Kronos - I stashed my changes and tried again. glext.h is good now :)

Gor bx, I had to delete unordered_map entirely to get it out of the search path, as well as removing the include of malloc.h.

I've shifted to a command line build strategy as you suggest, with the bx mods, the library builds fine. Trying to get the samples building now, for some reason it's hung up on not finding the SDL2 headers (which I've currently got in /Library/Frameworks.) I'm sure it'll be easy enough to resolve at my end.

Maybe the premake script could generate the unordered_map header on pre 10.9 installations?

from bgfx.

meshula avatar meshula commented on May 22, 2024

Solved SDL2 with
cd 3rdparty
ln -s /Library/Frameworks/SDL2.framework/Versions/A/Headers SDL2
mkdir lib; cd lib; mkdir osx64_gcc; cd osx64_gcc
ln -s /Library/Frameworks/SDL2.framework/Versions/A/SDL2 libSDL2.a

I think maybe you were assuming that SDL2 would be installed by people into /usr/local instead of as a framework? A few notes in the readme might be helpful.

After a command line build, the examples are working (i.e., they run properly) up to the stencil shadow sample, which doesn't build because for an obvious reason -

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/cmath:1242:46: fatal error: declaration conflicts
with target of using declaration already in scope
inline _LIBCPP_INLINE_VISIBILITY float fmax(float __x, float __y) _NOEXCEPT {return fmaxf(__x, __y);}
^
../../../examples/common/fpumath.h:20:14: note: target of using declaration
inline float fmax(float _a, float _b)
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/cmath:1239:9: note: using declaration
using ::fmax;
^

Getting close!

from bgfx.

bkaradzic avatar bkaradzic commented on May 22, 2024

I had to delete unordered_map entirely

Yeah I was wondering about that. Since it would include itself.

Btw, can you try deleting whole bx/include/compat/osx. Based on your changes it might work that way, and then I'll figure out how to remove include path from 10.9 in Premake script instead.

from bgfx.

bkaradzic avatar bkaradzic commented on May 22, 2024

I've been wanting to disable SDL2 build for OSX anyway. Someone requested SDL2 integration and I left it enabled mostly for testing reasons. Setting ENTRY_CONFIG_USE_SDL to 0 build with native entry path.

from bgfx.

bkaradzic avatar bkaradzic commented on May 22, 2024

What's using cmath?

from bgfx.

bkaradzic avatar bkaradzic commented on May 22, 2024

Btw, SDL2 path is just what SDL2 uses when building from source. I just did make && make install. How did you obtain SDL2? Is it part of Xcode/SDK now?

from bgfx.

bkaradzic avatar bkaradzic commented on May 22, 2024

Fixed this fmin/fmax name collision (a4df646). It seems defined everywhere except MSVC. Not sure why this never caused any issues?!

from bgfx.

meshula avatar meshula commented on May 22, 2024
  1. deleting compat/osx. FTW - it's good.
  2. unordered_map > hash_table > math
  3. http://www.libsdl.org/download-2.0.php has SDL2 prebuilt binaries as a .dmg file
  4. with a4df646, the build succeeds all the way through.

All of the demos I tried look good, except the SDF font demo is quite glitched around the edges of some letters.

from bgfx.

bkaradzic avatar bkaradzic commented on May 22, 2024

All of the demos I tried look good, except the SDF font demo is quite glitched around the edges of some letters.

Probably would be the best to create screenshot and open new issue specifically for it.

from bgfx.

bkaradzic avatar bkaradzic commented on May 22, 2024

deleting compat/osx. FTW - it's good.

Ok, I don't have solution yet how to make it work with 10.8.4 and 10.9 but good to know.

from bgfx.

meshula avatar meshula commented on May 22, 2024

LOL, okay, I'll learn how to add screenshots to issue reports.

from bgfx.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.