Help required building iOS on macOS (VM)

Hi all

Over the last few months I have successfully built and then improved the Map component for Android, building it on Windows. See Add custom url for map component by petersmythe · Pull Request #3160 · mit-cml/appinventor-sources · GitHub. I am now trying my hand at improving the iOS equivalent code, for which I need macOS. I have been through all the setup steps again.

I am getting the following build error for ant ios in ios-build.xml:57 in ai.xcbuild:

Higher up in the logs, I find 39 warnings and 2 errors:

(My apologies for the screenshots, I am working on a VM, with no copy & paste functionality)

I observe that there's a disconnect in macCatalyst versions here, targetting 13.1.0, but the functionality was only introduced in 14.0.

Where is this targetting 13.1.0 set, is it in the source code (not that I could find with grep)? Is it maybe IPHONEOS_DEPLOYMENT_TARGET = 12.0?

Does it have to do with my macOS setup, which is as follows:
macOS: Sonoma 14.5
Java: OpenJDK 11.0.23
Xcode 15.4
developer tools (git, ant) also installed

(This is a VM running in docker using GitHub - sickcodes/Docker-OSX: Run macOS VM in a Docker! Run near native OSX-KVM in Docker! X11 Forwarding! CI/CD for OS X Security Research! Docker mac Containers.)

When I open the AppInventor folder in Xcode, I see that iOS 17.5 is Not Installed,

but I believe that is just the Simulator, which is not required.

Opening AIComponentKit, I see the Minimum Deployments is set to iOS 12.0. If I try setting this (IPHONEOS_DEPLOYMENT_TARGET) to 14.0 (modifying 4 project.pbxproj files), the same error occurs (but the 39 warnings are now gone.)

The error message (for Pod ZXingObjC) is: multitaskingCameraAccess Enabled|Supported is unavailable on macCatalyst

Can anyone please offer some advice on how to proceed?

Thanks

Peter

Is this problem specifically with ZXingObjC, which appears to have been archived 5 years ago, or is this a general build problem? How can I best disable ZXingObjC, comment it out of the Podfile?

I also see Xcode 15.4 is relatively new, should I attempt to downgrade to an earlier version of Xcode, which version is recommended?

It looks like from your screenshot that you need to install the iOS 17.5 SDK. By default Xcode only includes the macOS SDK, but many of our libraries use iOS specific functionality. If you click the GET button in the screenshot it should download the SDK and then just make sure you are using an iOS build target rather than macOS.

1 Like

Thanks Evan, that looks like it's compiling now. I made this documentation suggestion: Update README.ios.md by petersmythe · Pull Request #3186 · mit-cml/appinventor-sources · GitHub

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.