Jump to content


Photo

TUTORIAL: Compile iMame4All for Xcode

imame xcode icontrolpad

  • Please log in to reply
11 replies to this topic

#1 OFFLINE   Menneisyys

Menneisyys

    Advanced Member

  • Members
  • PipPipPip
  • 50 posts
  • Local time: 02:39 AM

Posted 29 September 2011 - 04:53 PM

Generally, all you need to compile iMame4All for Xcode for your iPad is:

1, create a /Projects/mame/iMame4All-iOS4 directory in the root of your Mac OS X drive

2, copy all the subdirectories from the ZIP file there (first, download it from http://www.lesbird.c...me4All-iOS4.zip , of course)

3, download and install Xcode 4. (The rest of my tutorial discusses only Xcode 4+ it so that you can also compile for iOS 5. Previous Xcode versions, while, personally, I prefer them to the new version, can't compile for iOS 5.) Start it; load /Projects/mame/iMame4All-iOS4/Xcode/iMAME/iMAME.xcodeproj

4, double-click the project name in the upper left corner and navigate to the “Build Settings” pane (third from the left):

Posted Image
5, enter “sign” in the search field:
Posted Image
6, in turn, click all of the three rows containing “Les Bird” and change the values to “iPhone Developer” (highlighted in the next screenshot):
Posted Image
If you do re-set all these, the results will be something like this (with a different name after “iPhone Developer (currently matches iPhone Developer”, in the parentheses, of course):
Posted Image
7, congratulations, you can now compile (just click the arrow in the upper left corner) and deploy the project! Just remember to copy the game ROM ZIP files via iTunes File Transfer, as you would do with AppStore games.

#2 OFFLINE   goldenegg

goldenegg

    Member

  • Members
  • PipPip
  • 20 posts

Posted 05 October 2011 - 03:59 AM

This doesn't work anymore with Xcode 4.2 GM. You get a compile error that it can't find corevideo\corevideo.h. Haven't played around with it past that yet. I should note that it still compiles and runs on iOS 5 devices when using Xcode 4.1.1.

This is my own fault for not adequately following the changes implemented in Xcode 4.2. Now I guess it's time to read the docs.

#3 OFFLINE   Spacemonkey

Spacemonkey

    Newbie

  • Members
  • Pip
  • 1 posts
  • Local time: 12:39 AM

Posted 07 October 2011 - 08:21 PM

I got it working on mine. The issue is the search paths in build settings.

What I did was delete the settings within this area, apart from library search paths, in library search paths you need the lib directory (/Projects/mame/iMame4All-iOS4/lib in my case).

Now it compiles fine and deploys to my iPad. Make sure you don't target the simulator, it won't work for that.

#4 OFFLINE   matthew.e

matthew.e

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 14 October 2011 - 03:34 AM

I got it working on mine. The issue is the search paths in build settings.

What I did was delete the settings within this area, apart from library search paths, in library search paths you need the lib directory (/Projects/mame/iMame4All-iOS4/lib in my case).

Now it compiles fine and deploys to my iPad. Make sure you don't target the simulator, it won't work for that.



Anyone have a guide to get this to compile in Xcode 4.2 and iOS 5?

Much appreciated.

Thanks.

#5 OFFLINE   mastergizmo

mastergizmo

    Newbie

  • Members
  • Pip
  • 1 posts
  • Local time: 01:39 AM

Posted 20 October 2011 - 10:01 AM

I had the same problem compiling the Project in Xcode 4.2 (missing corevideo.h file)

in Xcode go to: TARGET --> iMAME --> Build Settings --> Search Paths --> Framework Search Paths

Set it to:

$(inherited) "$(DEVELOPER_DIR)/Platform/DeviceSupport/5.0 (9A334)/Symbols/System/Library/PrivateFrameworks" "$(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks" "$(DEVELOPER_DIR)/Platforms/iPhoneOS.platform/DeviceSupport/5.0/Symbols/System/Library/PrivateFrameworks"

#6 OFFLINE   Menneisyys

Menneisyys

    Advanced Member

  • Members
  • PipPipPip
  • 50 posts
  • Local time: 02:39 AM

Posted 09 November 2011 - 04:22 PM

Posted a longer article on iMAME to http://www.iphonelif...es-your-idevice . For some reason, I haven't been able to reproduce the corevideo.h error, not even with the latest Xcode version. Dunno why.

#7 OFFLINE   RandyInLA

RandyInLA

    Newbie

  • Members
  • Pip
  • 4 posts
  • Local time: 04:39 PM

Posted 08 December 2011 - 01:10 AM

I had the same problem compiling the Project in Xcode 4.2 (missing corevideo.h file)

in Xcode go to: TARGET --> iMAME --> Build Settings --> Search Paths --> Framework Search Paths

Set it to:

$(inherited) "$(DEVELOPER_DIR)/Platform/DeviceSupport/5.0 (9A334)/Symbols/System/Library/PrivateFrameworks" "$(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks" "$(DEVELOPER_DIR)/Platforms/iPhoneOS.platform/DeviceSupport/5.0/Symbols/System/Library/PrivateFrameworks"


MasterGizmo: I tried putting the above in my Framework Search Paths and it still does not find CoreVideo.h. I do not have a "/Platform" dir, as referenced in the first line, "$(DEVELOPER_DIR)/Platform". I changed it to "$(DEVELOPER_DIR)/Platforms/iPhoneOS.platform/" and that didn't help. Any other suggestions?

It seems to be looking for CoreVideo.h inside the CoreImage.framework instead of the CoreVideo.framework. The actual message re:CoreVideo.h is as follows:
'CoreVideo/CoreVideo.h' file not found in /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk/System/Library/Frameworks/Headers/CIImage.h"
The highlighted error is inside CIImage.h. I feel so close to compiling, but might as well be miles away. Thanks for any help.

#8 OFFLINE   RandyInLA

RandyInLA

    Newbie

  • Members
  • Pip
  • 4 posts
  • Local time: 04:39 PM

Posted 08 December 2011 - 01:33 AM

I changed the first path to:

"$(DEVELOPER_DIR)/Platforms/iPhoneOS.platform/DeviceSupport/5.0 (9A334)/Symbols/System/Library/Frameworks"

I did this because CoreVideo.framework is inside /Frameworks and not /PrivateFrameworks.

Next, I linked CoreVideo.framework under Target -> Build Phases -> Link Binary With Libraries and it still cannot find that frickin CoreVideo.h file, referenced from the CIImage.h file in CoreImage.framework.

Hate being stuck.

#9 OFFLINE   PeeZapp

PeeZapp

    Advanced Member

  • Members
  • PipPipPip
  • 161 posts
  • Local time: 08:39 AM
  • LocationPerth, Western Australia

Posted 08 December 2011 - 03:22 PM

Just quickly there is no way of doing this without paying for an apple developer licence or jailbreaking you device? I am able to get a copy of xcode but will require a licence to compile and use imame4all
I put my phone on airplane mode and threw it worst transformer ever

#10 OFFLINE   RandyInLA

RandyInLA

    Newbie

  • Members
  • Pip
  • 4 posts
  • Local time: 04:39 PM

Posted 10 December 2011 - 06:25 AM

Just quickly there is no way of doing this without paying for an apple developer licence or jailbreaking you device? I am able to get a copy of xcode but will require a licence to compile and use imame4all

I believe if you have XCode but no developer license, you can't run your code on an actual device, only the simulators.

#11 OFFLINE   RandyInLA

RandyInLA

    Newbie

  • Members
  • Pip
  • 4 posts
  • Local time: 04:39 PM

Posted 10 December 2011 - 10:30 PM

I got it to compile!
I reread the posts again and it worked after doing what Spacemonkey suggested above! (I tried his suggestion before, but I must have fudged the path)

Here's what I did:
I cleared my Framework Search Paths so it's empty
Set my Header Search Paths to: /Projects/mame/iMame4All-iOS4/Classes/** /Projects/mame/iMame4All-iOS4/src/** /Projects/mame/iMame4All-iOS4/lib/**
Set my Library Search Paths to: $(inherited) "$(SRCROOT)/../../lib" which displays as: /Projects/mame/iMame4All-iOS4/Classes/** /Projects/mame/iMame4All-iOS4/src/** /Projects/mame/iMame4All-iOS4/lib/** "/Projects/mame/iMame4All-iOS4/xcode/iMAME/../../lib"

There are 999+ warnings, but the app builds and launches on my iPad 1st gen.

#12 OFFLINE   Mosys

Mosys

    Newbie

  • Members
  • Pip
  • 1 posts
  • Local time: 07:39 PM

Posted 24 July 2012 - 11:27 PM

I had to add one more path to get it to compile.
in the source path section I had to add the following
"$(SRCROOT)/../SBGamepad/lib"

I also got 99+ warning and I am going through them one at a time to see if I can clear all them up. Quiet a few of them are "deprecated" pieces of code that eventually will not be supported and since I am learning Objective-C it seems like a good exercise to hone my skills.



0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users