Hi,
I’m building an IOS/Android mobile game and it’s mostly a content only project but with a small amount of native code (so we’ve had to build our own binaries).
I’m aware that you can’t build IOS binaries on windows though, so purchased a Mac mini to generate the IOS binaries on (the idea is not to work on the Mac, just to generate the binaries once and return to deploying on PC; we almost never change the code). The Mac is running OS X Yosemite (10.10.4) and is a 2.4GHz Intel core 2 Duo, 4GB of ram and an Nvidia GeForce 320M (256MB). I also installed Xcode on it.
I managed to generate the certificate, mobile provision and key outside of Xcode and that all works fine (plugging them into the IOS project settings on PC). But I have NO idea how to go about generating an IOS binary. I’ve been doing some reading and there’s a lot of material out there about downloading the engine source and doing a remote build of the whole thing on the Mac (which is overkill here), but I can’t find a straight forward solution for just building the game code specifically.
I installed Unreal 4.8.3 on the Mac and ran the editor (which worked fine and I could create a new project). I also managed to connect to our SVN server in Xcode and download our project onto the Mac. When I open up the .uproject though, it immediately says that “UE4Editor-Game.dylib does not exist”, I allow it to compile it (it opens up a console and I can see it building our game module), but then the editor immediately crashes:
MachineId:9B49FA777C473D610F584EA537A82146
EpicAccountId:f8e99177c497485e9a95ff9299be87c5
Generating report for minidump
Application version 4.8.3-0
... built from changelist 2634408
OS version 10.10.4.20038
Running 1 x64 processors
Exception was " BUS_ADRERR at 0x1236b38bc"
Source context from ""
<SOURCE START>
<SOURCE END>
<CALLSTACK START>
FTextFormatHelper::Format(FText const&, int, TBaseDelegate<FFormatArgumentValue const*, FString const&, int>, TSharedPtr<FTextHistory, (ESPMode)1> const&, bool, bool) Address = 0x10598de54 (filename not found) [in UE4Editor-Core.dylib]
FText::FormatInternal(FText const&, TArray<FFormatArgumentValue, FDefaultAllocator> const&, bool, bool) Address = 0x10593f96f (filename not found) [in UE4Editor-Core.dylib]
FText::Format(FText const&, FText const&) Address = 0x10593df3c (filename not found) [in UE4Editor-Core.dylib]
LoadPackageInternal(UPackage*, wchar_t const*, unsigned int, FLinkerLoad*) Address = 0x1063b291d (filename not found) [in UE4Editor-CoreUObject.dylib]
FLinkerLoad::VerifyImportInner(int, FString&) Address = 0x10622d3a1 (filename not found) [in UE4Editor-CoreUObject.dylib]
FLinkerLoad::VerifyImport(int) Address = 0x10622782f (filename not found) [in UE4Editor-CoreUObject.dylib]
FLinkerLoad::VerifyImportInner(int, FString&) Address = 0x10622b529 (filename not found) [in UE4Editor-CoreUObject.dylib]
...
I’ve also tried moving this compiled .dylib to the PC to see if I can use it to run the game on IOS, but it just crashes the IOS run tool too.
I’m presuming if it didn’t crash on the Mac, I could run the game on IOS there and then check in the resulting binaries? If so, I need to work out why the Mac is crashing and I’ll hopefully have a working solution.
If not, is there a way to simply compile the project on the Mac, check some files in and be done with it? Or do I HAVE to get the entire engine first and build it remotely on the Mac?
Cheers,
- Phil
Update: I suddenly realised that I could generate an Xcode project from the uproject. That seems to be taking me in the correct direction. Except now I’m suffering from a build error:
Setting up Mono
Building DefendyRocket...
Directories : System.String[] /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk
Compiling with IOS SDK 8.4
Compiling with these architectures: armv7
Unzipping: /Users/Shared/UnrealEngine/4.8/Engine/Plugins/Runtime/Advertising/IOSTapJoy/ThirdPartyFrameworks/Tapjoy.embeddedframework.zip -> /Users/macuser/Desktop/XCode Projects/Defendy Rocket/Intermediate/UnzippedFrameworks/ThirdPartyFrameworks/Tapjoy.embeddedframework
unzip: cannot find or open /Users/Shared/UnrealEngine/4.8/Engine/Plugins/Runtime/Advertising/IOSTapJoy/ThirdPartyFrameworks/Tapjoy.embeddedframework.zip, /Users/Shared/UnrealEngine/4.8/Engine/Plugins/Runtime/Advertising/IOSTapJoy/ThirdPartyFrameworks/Tapjoy.embeddedframework.zip.zip or /Users/Shared/UnrealEngine/4.8/Engine/Plugins/Runtime/Advertising/IOSTapJoy/ThirdPartyFrameworks/Tapjoy.embeddedframework.zip.ZIP.
Performing 5 actions (2 in parallel)
[1/5] clang++ DefendyRocket.generated.cpp
[2/5] clang++ DR_GameMode.cpp
[3/5] clang++ DefendyRocket.cpp
[4/5] clang++ UELinkerFixups.cpp
[5/5] clang++ /Users/macuser/Desktop/XCode Projects/Defendy Rocket/Binaries/IOS/DefendyRocket
ld: framework not found TapJoy
clang: error: linker command failed with exit code 1 (use -v to see invocation)
-------- End Detailed Actions Stats -----------------------------------------------------------
ERROR: UBT ERROR: Failed to produce item: /Users/macuser/Desktop/XCode Projects/Defendy Rocket/Binaries/IOS/DefendyRocket
Total build time: 58.40 seconds
Command /Users/Shared/UnrealEngine/4.8/Engine/Build/BatchFiles/Mac/RocketBuild.sh failed with exit code 5
Looking into this at the moment. Will report back if I make any more progress.
Update #2: Fixed the TapJoy issue by booting the project up on PC and disabling the TapJoy plugin in the plugin manager. Actually managed to build various builds now on the Mac, although building (what I think is) a mac editor build doesn’t solve the crash on when running the game’s editor project on the Mac, and I seemed to be able to make an IOS build (tried various ones) but the game crashes on iPhone at startup (not sure why). Been playing around with the Xcode configurations trying to see if there’s anything obviously wrong, but can’t find anything at this point. Will continue looking/trying.