Fixed compilation for MacOS with Xcode 5 (edited premake files only).

This commit is contained in:
Ivan Goremykin 2014-08-23 15:24:39 +04:00
parent 660f86065f
commit 90b8b41d95
4 changed files with 29 additions and 2 deletions

View File

@ -329,6 +329,15 @@ Visual Studio 2008 IDE:
start .build/projects/vs2008/bgfx.sln
Xcode 5 IDE:
open .build/projects/xcode4/bgfx.xcworkspace
Due to [inability](http://industriousone.com/debugdir) to set working directory for an Xcode project from premake configuration file, it has to be set manually for each example project:
1. Open *"Edit scheme..."* dialog for a given project.
2. Select *"Run"* settings.
3. Check *"Use custom working directory"* and enter following path: `${PROJECT_DIR}/../../../examples/runtime`.
Linux 64-bit:
make linux-release64

View File

@ -43,7 +43,7 @@ function bgfxProject(_name, _uuid, _kind, _defines)
"gdi32",
}
configuration { "osx or ios*" }
configuration { "xcode4 or osx or ios*" }
files {
BGFX_DIR .. "src/**.mm",
}
@ -53,7 +53,7 @@ function bgfxProject(_name, _uuid, _kind, _defines)
"Cocoa.framework",
}
configuration { "vs* or linux or mingw or osx or ios*" }
configuration { "vs* or linux or mingw or osx or xcode4 or ios*" }
includedirs {
--nacl has GLES2 headers modified...
BGFX_DIR .. "3rdparty/khronos",

View File

@ -21,3 +21,8 @@ project ("example-common")
BGFX_DIR .. "examples/common/**.cpp",
BGFX_DIR .. "examples/common/**.h",
}
configuration { "xcode4" }
includedirs {
BX_DIR .. "include/compat/osx",
}

View File

@ -134,6 +134,19 @@ function exampleProject(_name, _uuid)
-- "SDL2",
}
configuration { "xcode4" }
platforms {
"Universal"
}
files {
BGFX_DIR .. "examples/common/**.mm",
}
links {
"Cocoa.framework",
"Foundation.framework",
"OpenGL.framework",
}
configuration { "ios*" }
kind "ConsoleApp"
files {