## [DEPRECATED] Experimental iOS port (LÖVE 0.9.2)

Discuss any ports of LÖVE to different platforms.
slime
Solid Snayke
Posts: 2871
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

### Re: Experimental iOS port (LÖVE 0.9.x)

SiENcE wrote:I use a VM with XCode 3.2.6 on MacOSX 10.6.8.
It requires Xcode 4.3 and Mac OS 10.7+ or so to build, I think. Mac OS 10.9 is free, so you might be able to upgrade directly to that via the Mac App Store and get Xcode 5 too.

gianmichele
Citizen
Posts: 51
Joined: Tue Jan 14, 2014 11:03 pm

### Re: Experimental iOS port (LÖVE 0.9.x)

WOW, just WOW!

I'm going to test it ASAP.

One workflow enhancer would be to create a "player" version of the runtime that can get a .love file through wi-fi, that way you can cut the xcode part and also have windows/linux users develop for it (at least until they need to publish. Apple does not allow for that in the store)

Once everything works, you can easily create a fused version of the game for inclusion in the App Store.

Way to go!

SiENcE
Party member
Posts: 783
Joined: Thu Jul 24, 2008 2:25 pm
Location: Berlin/Germany
Contact:

### Re: Experimental iOS port (LÖVE 0.9.x)

slime wrote:
SiENcE wrote:I use a VM with XCode 3.2.6 on MacOSX 10.6.8.
It requires Xcode 4.3 and Mac OS 10.7+ or so to build, I think. Mac OS 10.9 is free, so you might be able to upgrade directly to that via the Mac App Store and get Xcode 5 too.
Hm sadly not possible to update the vm with mac 10.9. The installation breaks my VM :-/. I need a mac .

Fayer
Prole
Posts: 26
Joined: Tue Jan 07, 2014 5:48 pm
Location: Mexico City

### Re: Experimental iOS port (LÖVE 0.9.x)

I have a mac if you need me to test something.

Jasoco
Inner party member
Posts: 3650
Joined: Mon Jun 22, 2009 9:35 am
Location: Pennsylvania, USA
Contact:

### Re: Experimental iOS port (LÖVE 0.9.x)

slime wrote:I would assume so, since he said "you" when referring to me.
Only who can create an iOS version of Löve?

You have pressed "you" referring to "me". That is incorrect.

The correct answer is "you".

Mom, can we play outside? You know, away from the bear?

Keep it up! My hope is one day Löve can be on the iOS App Store with the ability to sync .love files right to the device and play them right on the iPad and iPhone with full touch API. (Alternatively, I would consider Jailbreaking my iPad when a full featured iOS Löve is available if not on the App Store.)

Someday..

Far in the future..

But hopefully not too far.

Ranguna259
Party member
Posts: 911
Joined: Tue Jun 18, 2013 10:58 pm
Location: I'm right next to you

### Re: Experimental iOS port (LÖVE 0.9.x)

I get an error when I try to build the project:

Code: Select all

ld: warning: directory not found for option '-L/Users/alex/Documents/hg/love-experiments/platform/ios/libraries/SDL'
ld: warning: directory not found for option '-L/Users/alex/Documents/hg/love-experiments/platform/ios/libraries/lua'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Built on OS X 10.9 with the Xcode 5.0.1 (I believe, it's the latest Xcode). The include and the libraries folder are inside the iOS folder.

EDIT:
And whenever I try to debug without building Xcode crashes.
LoveDebug- A library that will help you debug your game with an on-screen fully interactive lua console, you can even do code hotswapping

Check out my twitter.

slime
Solid Snayke
Posts: 2871
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

### Re: Experimental iOS port (LÖVE 0.9.x)

Thanks, it looks like I accidentally made some paths absolute instead of relative.

Ranguna259
Party member
Posts: 911
Joined: Tue Jun 18, 2013 10:58 pm
Location: I'm right next to you

### Re: Experimental iOS port (LÖVE 0.9.x)

How would I change the paths ?
EDIT: Changed them, I had to go to: Build Settings - Search Paths - And changed Library Search Paths
LoveDebug- A library that will help you debug your game with an on-screen fully interactive lua console, you can even do code hotswapping

Check out my twitter.

vlag
Prole
Posts: 6
Joined: Sun Feb 09, 2014 4:16 pm

### Re: Experimental iOS port (LÖVE 0.9.x)

Hi !

I just compiled this iOS port, and I'd like to share some modifications that I have to do or that you can do to simplify the configuration, mostly on the XCode project.
I build with Xcode 5.0.2 on OSX 10.9 .

* Replacing absolute path by relative path (or \$(SRCROOT)/"the_relative_path") to find headers and libraries.
* Maybe check in /usr/local/include/"the_lib" for Header search path since it's usually the default destination of third-libraries installation (with makefile configuration). It can avoid to manually copy include directories.
* Add header guards for libraries/luasocket/libluasocket/lua.h (and maybe rename this file to avoid confusion)
* I didn't checked why, but I had to remove

Code: Select all

extern "C" { // Also called from luasocket
int luax_typerror(lua_State *L, int narg, const char *tname);
}
from common/runtime.h, line 389

Boring pedantic mode :
* Replace "SDL" name/mentions to "SDL2" and maybe "lua" to "lua5.2" to avoid confusion (I still work with projects using SDL1.2 and lua5.1 ).
* Maybe replace all #include <lua.h> by #include "lua.h" for consistency since these libraries may not be copied in standard path (I don't know if there is default or standard path for iOS libraries) or the opposite since Xcode Header Path seems to work, or if you'll use the /usr/local/include/ path, the point is to use the same coding style :p
* I've got some warnings (unused variables and implicit cast), nothing grave

Thank you again for your work

slime
Solid Snayke
Posts: 2871
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

### Re: Experimental iOS port (LÖVE 0.9.x)

Ranguna259 wrote:I get an error when I try to build the project:
Fixed.
vlag wrote:* Add header guards for libraries/luasocket/libluasocket/lua.h
Done.
vlag wrote:* Replace "SDL" name/mentions to "SDL2" and maybe "lua" to "lua5.2" to avoid confusion (I still work with projects using SDL1.2 and lua5.1 ).
Well, LÖVE currently uses LuaJIT (or just Lua 5.1 in the iOS port for now, since I haven't built LuaJIT for iOS yet.)
vlag wrote:* Maybe replace all #include <lua.h> by #include "lua.h" for consistency since these libraries may not be copied in standard path (I don't know if there is default or standard path for iOS libraries) or the opposite since Xcode Header Path seems to work, or if you'll use the /usr/local/include/ path, the point is to use the same coding style :p
The "lua.h" is only in the luasocket code (which we try not to modify if we don't have to.) In LÖVE's own code, everything compiled in src/ is #included with quotes, and external libraries are #included with angle-brackets. The #include "lua.h" in the luasocket code also has the benefit of making it a bit more clear that it's #including the local lua.h instead of the external one.
vlag wrote:* I've got some warnings (unused variables and implicit cast), nothing grave
I fixed a couple of the warnings, but some of them are from libraries which I can't fix.

### Who is online

Users browsing this forum: No registered users and 10 guests