How to compile for IOS 9.3.x

Getting into LiveCode for iOS? Ask your questions here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
MrFollies
Posts: 29
Joined: Tue Jul 15, 2014 8:30 am

How to compile for IOS 9.3.x

Post by MrFollies » Tue Jul 18, 2017 10:33 pm

Hello,

I'm struggling to find a way to compile for 9.3.x.
I'm running MacOS 10.12 and have LiveCode Indy 8.1.4.

I have the latest XCode as well as a 7.2 copy.
When I link in both SDKs LiveCode tells me I have access to 9.2 and 10.3 SDKs.

But if I try and compile for 9.2 it fails.
Screen Shot 2017-07-19 at 7.28.38 am.png
Compiler Error
Looking at this page: https://livecode.com/support/ask-a-ques ... -livecode/
My fear is that I need to go back to MacOS 10.10 to be able to compile for IOS 9.

Is this the case? Or is there some way I can make it work on 10.12?

Thierry
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 875
Joined: Wed Nov 22, 2006 3:42 pm

Re: How to compile for IOS 9.3.x

Post by Thierry » Wed Jul 19, 2017 8:21 am

Hi,

Just an idea:

As you have iOS-SDK 9.2, why not trying to build your application with
a LiveCode version compatible with this Sdk?

Check but LC 8.0 should do it...

And do *not* link this LC version with another Sdk.

Well, as I said, just an idea....

Good luck,

Thierry
!
SUNNY-TDZ.COM doesn't belong to me since 2021.
To contact me, use the Private messages. Merci.
!

LiveCode_Panos
Livecode Staff Member
Livecode Staff Member
Posts: 818
Joined: Fri Feb 06, 2015 4:03 pm

Re: How to compile for IOS 9.3.x

Post by LiveCode_Panos » Wed Jul 19, 2017 10:31 am

Hi all,

Just a clarification:

Those 2 are different things:

(1). Build the standalone **using** the iOS X.Y SDK --> This is controlled by the Xcode version you choose in the "Mobile Support" LiveCode Preferences
(2). Ensure the standalone can run on iOS X.Y --> This is controlled in the iOS Standalone Settings "Build for iOS X.Y or later"

I guess in this case MrFollies needs (2), so you just need to ensure you have chosen "9.3 or later" in the iOS Standalone Settings. This will work on MacOS 12.10 (and in every other Mac OS version)

Now, regarding the error you get, this will usually go away if you just try again. See this bug report: http://quality.livecode.com/show_bug.cgi?id=19080

Best,
Panos
--

MrFollies
Posts: 29
Joined: Tue Jul 15, 2014 8:30 am

Re: How to compile for IOS 9.3.x

Post by MrFollies » Thu Jul 20, 2017 12:21 am

LiveCode_Panos wrote: (1). Build the standalone **using** the iOS X.Y SDK --> This is controlled by the Xcode version you choose in the "Mobile Support" LiveCode Preferences
(2). Ensure the standalone can run on iOS X.Y --> This is controlled in the iOS Standalone Settings "Build for iOS X.Y or later"

I guess in this case MrFollies needs (2), so you just need to ensure you have chosen "9.3 or later" in the iOS Standalone Settings. This will work on MacOS 12.10 (and in every other Mac OS version)

Now, regarding the error you get, this will usually go away if you just try again. See this bug report: http://quality.livecode.com/show_bug.cgi?id=19080
Thanks for the replies guys. Panos I am replying to your as its closer to my problem, although I feel I need to explain further.
I have iPads to test with running 10.3 and 9.3. (iPad 2 cannot run 10.x so this will be an issue for me in the future).

Your point (1) above is not the issue. I've been trying to compile using 10.3 and 9.2.

XCode 7.2 has IOS SDK 9.2
XCode 8.3.3 hgas IOS SDK 10.3

On MAC OS 10.12 (you mentioned 12.10 but I think you mistyped?)
When I add *both* XCode versions to the LiveCode Mobile Support, it gives a green light. It tells me Sims and SDKs for 9.2 and 10.3 are available.
But I can only compile for 10.3 and later. 9.2 gives me the error above.

If I *just* add 7.2 to the mobile Support tab then I get a Red light.

Now last night I went to the trouble of downloading Yosemite (Mac OS 10.10) and installing into a parallels VM.
I used XCode 7.2 (8.3.3 probably wont work under 10.10 I guess).
I installed LC and was able to compile for 9.2 just fine.

So it seems the macOS version *does* matter.

Panos I'd rather have one development environment, so if you know of a way to compile for 9.2 under Mac OS 10.12, then I am interested to know how you did it.
My experience is that the OS version is important.

MrFollies
Posts: 29
Joined: Tue Jul 15, 2014 8:30 am

Re: How to compile for IOS 9.3.x

Post by MrFollies » Thu Jul 20, 2017 12:23 am

Reading the error, it probably could be because I am using external libs compiled for a certain version.
(DBSqlite and revxml)

If that's the case than perhaps all I need to do is have the other versions of these libraries available to the linker (somehow).

MrFollies
Posts: 29
Joined: Tue Jul 15, 2014 8:30 am

Re: How to compile for IOS 9.3.x

Post by MrFollies » Thu Jul 20, 2017 4:33 am

More info:

I created a new app, just a basic Naughts and Crosses game.
It compiles and runs just fine.

Until I add this code:
put revOpenDatabase("sqlite", tDBPath, , , , ) into tDatabaseID

As soon as it wants to load the sqlite external then it breaks the compile...

LiveCode_Panos
Livecode Staff Member
Livecode Staff Member
Posts: 818
Joined: Fri Feb 06, 2015 4:03 pm

Re: How to compile for IOS 9.3.x

Post by LiveCode_Panos » Thu Jul 20, 2017 8:26 am

Hi MrFollies,

Sorry if my post was not clear. What I wanted to say is that the Xcode version version you use **for building** the standalone does not restrict the iOS version needed to run the app. The later is controlled by the standalone settings, not the Xcode version.

So in your case, since you are on macOS Sierra (10.12), if you use LiveCode 8.1.5 you *have* to use Xcode 8.3.x (otherwise you will get a red box in the mobile preferences)

Xcode 8.3.x includes the iOS 10.3.x SDK, so your standalone will be built by the iOS 10.3.x SDK. If you want your app to run in your 9.3 and 10.3 iPads, you only have to select in the standalone settings a minimum target that will include those 2 versions, e.g. "9.3 or later". I usually leave the default option, which is "6.0 or later" for LC 8.x. There is no reason to change this IMO, unless you want your app to NOT run on some older iOS versions.

So with the following setup (MacOS 10.12, LiveCode 8.1.5 and Xcode 8.3.3) I cab successfully create iOS standalones running in both iOS 9.3 and iOS 10.3 devices.

Regarding the error you are getting, I have experienced this too, but it disappears if you just try building a standalone again. For some users the error disappears if they try again 3-4 times, but it does disappear.

Best regards,
Panos
--

PS: The only reason to add Xcode 7.2 would be to have the iOS 9.2 **simulators** available, but IMO this is not necessary, since you already have the 10.3 simulators (because of the Xcode 8.3.3), and you also have a 9.3 device.

MrFollies
Posts: 29
Joined: Tue Jul 15, 2014 8:30 am

Re: How to compile for IOS 9.3.x

Post by MrFollies » Thu Jul 20, 2017 11:37 am

LiveCode_Panos wrote:Hi MrFollies,

Sorry if my post was not clear. What I wanted to say is that the Xcode version version you use **for building** the standalone does not restrict the iOS version needed to run the app. The later is controlled by the standalone settings, not the Xcode version.

So in your case, since you are on macOS Sierra (10.12), if you use LiveCode 8.1.5 you *have* to use Xcode 8.3.x (otherwise you will get a red box in the mobile preferences)

Xcode 8.3.x includes the iOS 10.3.x SDK, so your standalone will be built by the iOS 10.3.x SDK. If you want your app to run in your 9.3 and 10.3 iPads, you only have to select in the standalone settings a minimum target that will include those 2 versions, e.g. "9.3 or later". I usually leave the default option, which is "6.0 or later" for LC 8.x. There is no reason to change this IMO, unless you want your app to NOT run on some older iOS versions.

So with the following setup (MacOS 10.12, LiveCode 8.1.5 and Xcode 8.3.3) I cab successfully create iOS standalones running in both iOS 9.3 and iOS 10.3 devices.

Regarding the error you are getting, I have experienced this too, but it disappears if you just try building a standalone again. For some users the error disappears if they try again 3-4 times, but it does disappear.

Best regards,
Panos
--

PS: The only reason to add Xcode 7.2 would be to have the iOS 9.2 **simulators** available, but IMO this is not necessary, since you already have the 10.3 simulators (because of the Xcode 8.3.3), and you also have a 9.3 device.
Panoz,... Thank you so much,... It took 3 goes but I was able to compile on 10.12 with XCode 8.3.3.
I've struggled with this problem off and on for about 18 months. It never really worried me too much since I was able to just bump the IOS version up and it would work. Only now with the iPad2's being forced to remain on 9.3.x was it a problem for me.

Obviously the bug has something to do with the externals, but it doesn't actually matter if the workaround is simply to compile a few times until it works.
Thanks again!

LiveCode_Panos
Livecode Staff Member
Livecode Staff Member
Posts: 818
Joined: Fri Feb 06, 2015 4:03 pm

Re: How to compile for IOS 9.3.x

Post by LiveCode_Panos » Thu Jul 20, 2017 6:10 pm

You are welcome :)

Post Reply

Return to “iOS Deployment”