Comments (12)
Yes of course!
Untick OGRE_BUILD_RENDERSYSTEM_GL3PLUS from the CMake GUI tool, or run with -DOGRE_BUILD_RENDERSYSTEM_GL3PLUS=0 from the command line
from ogre-next.
I am extremely busy but managed to get quick peek at the build issues. Unfortunately I could not run my own samples because I had trouble (I always did) setting up SDL2 from source:
- Remotery build issues fixed
- OIS bugs do not happen in XCode 9.4; looks like 10 complains. Nonetheless, OIS is not used by Ogre 2.1; and I think it's already getting removed from 1.11 as well, so it may as well be thought as deprecated and should be removed. Just build ogredeps without OIS support
- GL3+ bugs, I could not repro in 9.4; looks like a problem with XCode 10
- Your final error while running the samples indicates the Metal library was either not built or not copied correctly to the intended location (or its missing the .dylib extension from what I can see in the error msg). I noticed the macOS version of the XCode project for some reason does not setup all build dependencies correctly, thus if you hit "Run" at one of the samples, it's possible XCode just skipped building Metal. Try compiling the target "ALL_BUILD" which builds everything (or select Metal RenderSystem target explicitly and build it). If after that it still complaints, then 99% sure it wasn't copied correctly. Try locatling RenderSystem_Metal inside the CMake folder and manually pasting into the location the message tells you its looking for.
I'm sorry you're having so many troubles to build Ogre 2.1 on Mac. As you may have noticed, building for macOS (not iOS) is our least polished experience, but usually you don't run into this many errors.
I will look into this again once I have more time
from ogre-next.
I get these errors when using Xcode > File> Project settings > Legacy Build system.
If I use New Build system (Default) I get other errors:
error: Multiple commands produce '/Users/dkr/Documents/Bitbucket/ogre/ogre2.1/build/lib/macosx/Debug/RenderSystem_GL3Plus.framework/Versions/2.1.0/Headers/OgreGL3PlusVertexArrayObject.h':
- Target 'RenderSystem_GL3Plus' has copy command from '/Users/dkr/Documents/Bitbucket/ogre/ogre2.1/RenderSystems/GL3Plus/include/OgreGL3PlusVertexArrayObject.h' to '/Users/dkr/Documents/Bitbucket/ogre/ogre2.1/build/lib/macosx/Debug/RenderSystem_GL3Plus.framework/Versions/2.1.0/Headers/OgreGL3PlusVertexArrayObject.h'
- Target 'RenderSystem_GL3Plus' has copy command from '/Users/dkr/Documents/Bitbucket/ogre/ogre2.1/RenderSystems/GL3Plus/include/Vao/OgreGL3PlusVertexArrayObject.h' to '/Users/dkr/Documents/Bitbucket/ogre/ogre2.1/build/lib/macosx/Debug/RenderSystem_GL3Plus.framework/Versions/2.1.0/Headers/OgreGL3PlusVertexArrayObject.h'
from ogre-next.
Takes a deep breath ....aaahhh Apple breaking things again.
I'm going to guess this sounds like XCode 10 Beta? I have XCode 9.4, I will try compiling there, it's been a while since I've tried.
The error you're getting "expected function body after function declarator" is inside one of XCode's own headers which is confusing me a little.
The only few ways this could happen is if:
- Apple headers are broken (has happened in the past...)
- OPENGL_DEPRECATED is literally causing this (or is broken or missing an include header)
- We (or one of our headers) are defining a macro with the same name as either GLAPI, APIENTRY or OPENGL_DEPRECATED and it is conflicting with Apple's
- Our code, before including the header contains a syntax error, like an extra { or a missing semi-colon. If this is the case then the XCode 9.4 version should have the error too.
I will have to google what the multiple command error is, but it looks weird that XCode is basically saying that two RenderSystem_GL3Plus targets are conflicting with each other
from ogre-next.
Correct, I am using XCode 10 Beta on Macbook 12.
Is it possible to configure cmake so it would generate just metal renderer, without GL3PLUS?
from ogre-next.
Without GL3PLUS I still get a lot of build errors when building with Xcode...
OISInputManager.cpp Line 123
id obj = (id)strtoul(i->second.c_str(), 0, 10);
Cast of 'unsigned long' to 'id' is disallowed with ARC
Ogre 2.1 needs changes to work on macOS. And better guides how to build the source so it would work with xcode.
from ogre-next.
Also:
-- Configuring done
CMake Error at Dependencies/src/Remotery/CMakeLists.txt:12 (add_library):
Cannot find source file:
src/Remotery.mm
Tried extensions .c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp
.hxx .in .txx
CMake Error: CMake can not determine linker language for target: Remotery
I managed to fix this by editing: Dependencies/src/Remotery/CMakeList.txt Line 6
from:
set( Remotery_SOURCES ${Remotery_SOURCES} src/Remotery.mm )
to:
set( Remotery_SOURCES ${Remotery_SOURCES} src/RemoteryMetal.mm )
but then I get a different error:
-- Configuring done
CMake Warning (dev):
Policy CMP0042 is not set: MACOSX_RPATH is enabled by default. Run "cmake
--help-policy CMP0042" for policy details. Use the cmake_policy command to
set the policy and suppress this warning.
MACOSX_RPATH is not specified for the following targets:
Remotery
--
Undefined symbols for architecture x86_64:
"rmtMetal_usGetTime()", referenced from:
SetTimestamp(void*) in RemoteryMetal.o
"_rmtMetal_MeasureCommandBuffer", referenced from:
_MetalTimestamp_Begin in Remotery.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
from ogre-next.
And I have problems building OIS...
from ogre-next.
When running Samples_Tutorial01_Initialization
I get this error:
Loading library RenderSystem_Metal
An exception has occured: OGRE EXCEPTION(7:InternalErrorException):
Could not load dynamic library RenderSystem_Metal. System Error:
dlopen(/Users/dkr/Documents/Bitbucket/ogre/Build/bin/Debug/Sample_Tutorial01_Initialization.app/Contents/Frameworks//RenderSystem_Metal.framework/RenderSystem_Metal, 9):
image not found in DynLib::load at /Users/dkr/Documents/Bitbucket/ogre/OgreMain/src/OgreDynLib.cpp (line 112)
Program ended with exit code: 255
from ogre-next.
We (or one of our headers) are defining a macro with the same name as either GLAPI, APIENTRY or OPENGL_DEPRECATED and it is conflicting with Apple's
I see #define APIENTRY
and #define GLAPI
in the following header:
https://github.com/OGRECave/ogre/blob/master/RenderSystems/GL3Plus/include/GL/glcorearb.h#L46-L54
from ogre-next.
- OPENGL_DEPRECATED is literally causing this (or is broken or missing an include header)
I think this is the problem; the fix for us is to include <OpenGL/OpenGLAvailability.h>
before <OpenGL/gl3ext.h>
in OgreGL3PlusPrerequisites.h.
https://bitbucket.org/sinbad/ogre/pull-requests/857/include-openglavailabilityh-before-gl3exth/diff
from ogre-next.
I'm closing it since Ogre-Next is building with XCode 13 now.
from ogre-next.
Related Issues (20)
- Red only specular for some new exported objects HOT 2
- MeshV2 not buildTangentVector
- Add sample on how to render on top (e.g. FPS) HOT 1
- Scene Manager unexpected behavior, returns NULL instead of new node ptr, no warnings/errors HOT 7
- Is there a C API? HOT 2
- Why not read mesh in obj format? HOT 1
- Build error for NEON HOT 10
- EmptyProject script is broken for macOS
- Build script fails on Ubuntu 23.10 with error: ISO C++17 does not allow dynamic exception specifications HOT 3
- Investigate Vulkan commit b85e1a64bbb9d539042a08924990235aaa5e825f HOT 21
- Rendering different videos at different frame rates in multiple windows
- [Urgent security issue] FreeImage arbitrary code execution vulnerability HOT 1
- Camera rendering specified visible mask object crash HOT 1
- Pose Animation not working correctly with Skeleton Animation HOT 2
- [Question] Billboards2 HOT 9
- HLMS Unlit Datablock HLMS OgreTextureAnimationController
- The Metal rendering API is 120FPS regardless of whether vsync is set. HOT 2
- Multiple Leaks
- Multi window rendering of different texts? HOT 1
- Sample_Tutorial02_VariableFramerate not rendering correctly on VM with OpenGL 4.3 support HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ogre-next.