-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add iOS version of Dolphin Old #3881
Conversation
The contents of this directory will be copied into the build directory post build. These files make up the user interface and also handle host messages
IGL uses a GLKView as it’s main window.
iOS needs the prepare function for IGL to know when to prepare it’s frame buffer to be drawn in to.
Since iOS does not have a default frame buffer, we must bind GL_FRAMEBUFFER. This frame buffer is tied to the GLKView used in IGL
Since iOS doe not have <asm/hwcap.h> or <sys/auxv.h>, we let hardware information remain uninitialized. This will need to be fixed
Since IOS is now used a definition, we cannot use IOS as a variable. We could undefine IOS and redefine it, but this seemed more logical
iOS does not have kAudioUnitSubType_DefaultOutput. Use kAudioUnitSubType_GenericOutput
For std::array we needed <array>. For sys_cache_control we needed <libkern/OSCacheControl.h>
On iOS pages will be mapped ANON and PRIVATE. Also map the memory arenas as if we are on a 32 bit machine due to lack of virtual memory
Since I was unable to fix MachineContext.h for iOS, I added empty implementations for iOS until a fix can be added
Use default apple context until fixed for iOS
m_flush_trigger.WaitFor() causes Dolphin to crash on iOS around every other time a game is loaded. Remove for now and discover why this causes a crash later
Added specific CMake configurations for IOS
iOS does not have <sys/disk.h>. These functions won’t be used to setting DKIOCGETBLOCKCOUNT and DKIOCGETBLOCKSIZE to arbitrary values serves as a workaround.
Updated readme to include system requirements and build steps for iOS
This is a simple game that will be included in the Roms directory for iOS builds
@dolphin-emu-bot rebuild |
@@ -0,0 +1,4 @@ | |||
<?xml version="1.0" encoding="UTF-8"?> |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
@@ -11,7 +11,7 @@ | |||
enum MACConsumer | |||
{ | |||
BBA = 0, | |||
IOS = 1 | |||
_IOS = 1 |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
Could you call the define something other than The extraction/decompression code needs to be removed completely from the PR, not committed and then reverted. |
Yea APPLE_IOS is fine. I can remove them or I can submit a new pull request when all of the changes have been made. The decompression libraries have been removed from my fork |
@@ -6,7 +6,9 @@ | |||
|
|||
#include "Common/GL/GLInterfaceBase.h" | |||
|
|||
#if defined(__APPLE__) | |||
#if defined IOS | |||
#include "Common/GL/GLInterface/IGL.h" |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
Reviewed 24 of 301 files at r1. Readme.md, line 110 [r2] (raw file):
-DENABLE_PCH should be enforced by the cmake file is required. Externals/SOIL/SOIL.c, line 25 [r2] (raw file):
What do you think about defininf APPLE on IOS? Source/Core/Common/Arm64Emitter.cpp, line 15 [r2] (raw file):
no need to hide array within IOS. It's either needed for all, or non. Source/Core/Common/ArmCPUDetect.cpp, line 66 [r2] (raw file):
I think we should try to support this. Source/Core/Common/CDUtils.cpp, line 73 [r2] (raw file):
tab vs space Source/Core/Common/CMakeLists.txt, line 74 [r2] (raw file):
Just configure USE_EGL=False within cmake Source/Core/Common/MemArena.cpp, line 105 [r2] (raw file):
maybe a comment why you've choosen this flags Source/Core/Common/Network.h, line 11 [r2] (raw file):
Will an enum class help here? Source/Core/Common/GL/GLInterface/GLInterface.cpp, line 9 [r2] (raw file):
defined(IOS) Source/Core/Common/GL/GLInterface/GLInterface.cpp, line 31 [r2] (raw file):
spaces vs tab Source/Core/Common/GL/GLInterface/IGL.h, line 26 [r2] (raw file):
please add public first, then protected, then private Source/Core/Common/GL/GLInterface/IGL.mm, line 19 [r2] (raw file):
member variables instead of static please. Source/Core/Common/GL/GLInterface/IGL.mm, line 53 [r2] (raw file):
why times 2? Source/Core/Common/Logging/ConsoleListeneriOS.cpp, line 16 [r2] (raw file):
I wouldn't call this "ios", more like a generic one. If there isn't one (I haven't checked), please just rename this one to "Generic" Source/Core/Core/PowerPC/JitArm64/JitArm64_BackPatch.cpp, line 20 [r2] (raw file):
Did this functions fail to compile, or just fail at execution? I'd like to see fastmem at some point :/ Source/Core/InputCommon/CMakeLists.txt, line 16 [r2] (raw file):
Please move this to ControllerInterface.h Source/Core/InputCommon/CMakeLists.txt, line 18 [r2] (raw file):
spaces vs tab Source/Core/VideoBackends/OGL/PostProcessing.cpp, line 52 [r2] (raw file):
GLInterface->GetDefaultFramebuffer() ? Source/Core/VideoBackends/OGL/Render.cpp, line 1340 [r2] (raw file):
Maybe within BlitScreen? Comments from Reviewable |
@WilliamLCobb It is possible to close the PR on your own. Or, you could force push the new version to this PR's branch, avoiding the need for a second PR. |
Review status: 23 of 246 files reviewed at latest revision, 46 unresolved discussions, some commit checks failed. Source/Core/Common/GL/GLInterface/IGL.mm, line 25 [r3] (raw file):
Please don't leave commented code all over the place. Source/Core/Common/GL/GLInterface/IGL.mm, line 30 [r3] (raw file):
Unnecessary whitespace (and in other places) Source/Core/InputCommon/ControllerInterface/iOS/iOS.h, line 1 [r3] (raw file):
2016 Source/Core/InputCommon/ControllerInterface/iOS/iOS.h, line 12 [r3] (raw file):
We don't put newlines for individual namespaces. Source/Core/InputCommon/ControllerInterface/iOS/iOS.h, line 15 [r3] (raw file):
Don't put spaces around parameters Source/Core/InputCommon/ControllerInterface/iOS/iOS.mm, line 1 [r3] (raw file):
2016 Source/Core/InputCommon/ControllerInterface/iOS/iOS.mm, line 16 [r3] (raw file):
No spaces around parameters Source/Core/InputCommon/ControllerInterface/iOS/iOS.mm, line 175 [r3] (raw file):
static_cast Source/Core/InputCommon/ControllerInterface/iOS/iOS.mm, line 186 [r3] (raw file):
static_cast Source/Core/InputCommon/ControllerInterface/iOS/iOSButtonManager.cpp, line 1 [r3] (raw file):
2016 Source/iOS/DolphiniOS/AppDelegate.m, line 20 [r3] (raw file):
This file could do with some spacing cleanup. Source/iOS/DolphiniOS/EmulatorViewController.mm, line 9 [r3] (raw file):
These paths should be relative like the others Source/iOS/DolphiniOS/GameTableView.h, line 6 [r3] (raw file):
We actually license under GPLv2+, so all rights actually aren't reserved. Source/iOS/DolphiniOS/GameTableView.m, line 6 [r3] (raw file):
Same here (if this is taken from somewhere else, this is problematic) Source/iOS/DolphiniOS/GameTableView.m, line 9 [r3] (raw file):
Paths should be relative. Source/iOS/DolphiniOS/GCAdapteriOS.cpp, line 1 [r3] (raw file):
This source file needs to be cleaned up. Source/iOS/DolphiniOS/MainiOS.mm, line 1 [r3] (raw file): Uh? Source/iOS/DolphiniOS/RomTableViewController.h, line 6 [r3] (raw file):
Again, we don't reserve all rights. Source/iOS/DolphiniOS/RomTableViewController.m, line 6 [r3] (raw file):
Ditto Source/iOS/DolphiniOS/Controller/GCControllerView.m, line 6 [r3] (raw file):
Ditto about not reserving all rights Source/iOS/DolphiniOS/Controller/GCControllerView.m, line 11 [r3] (raw file):
Don't leave uncommented code around. Also imports/includes should be relative. Source/iOS/DolphiniOS/Controller/WCButtonControl.h, line 6 [r3] (raw file):
Ditto about rights being reserved. Source/iOS/DolphiniOS/Controller/WCButtonControl.m, line 6 [r3] (raw file):
Ditto Source/iOS/DolphiniOS/Controller/WCDirectionalControl.h, line 6 [r3] (raw file):
Ditto Source/iOS/DolphiniOS/Controller/WCDirectionalControl.m, line 6 [r3] (raw file):
Ditto Source/iOS/DolphiniOS/Roms/starfield.dol, line 0 [r3] (raw file): Comments from Reviewable |
Review status: 23 of 246 files reviewed at latest revision, 46 unresolved discussions, some commit checks failed. Source/Core/Common/Arm64Emitter.cpp, line 15 [r2] (raw file):
|
Well I rebased the repo and now it's showing unknown repo in this pr and pushes from my fork aren't being updated. I'll close this and open a new pull request and only use force push from now on, unless someone knows how a way to fix this |
Review status: 23 of 246 files reviewed at latest revision, 46 unresolved discussions, some commit checks failed. Source/Core/Core/PowerPC/JitArm64/JitArm64_BackPatch.cpp, line 20 [r2] (raw file):
|
Review status: 23 of 246 files reviewed at latest revision, 46 unresolved discussions, some commit checks failed. Source/Core/Core/PowerPC/JitArm64/JitArm64_BackPatch.cpp, line 20 [r2] (raw file):
|
Commits stopped updating to this PR. Moved to #3885 |
The pull request has moved here: #3885
Most of the changes are pretty straightforward.
Added iOS directory in Source.
Added new IOS definition when building for iOS
Added build steps for in readme.
Cmake will generate an Xcode project in the build directory and copy in the Xcode project and workspace from the iOS directory. The workspace will combine these two projects, allowing full compatibility with future cmake and source changes while also giving control of all of the build settings for iOS. Since iOS is not inherently supported by cmake, this would have been very hard if not impossible without this step. The iOS app can be built in the Xcode GUI and also built from the command line.
Only one commit has a chance of affecting other builds: "IOS macro workaround" (0a22fb7). IOS was being used as a variable in a struct in Network.cpp and Network.h. Since I was using this as a definition for building iOS, i changed all instances of this variable to _IOS. This probably needs to be changed to something else, I just wasn't sure what
This change is