Use QT to develop iOS apps in MacOS

Source: Internet
Author: User

QT is chosen as a development tool because part of the project contract specifies that some of the business content is to be implemented on the phone, including Andro and Macs. The program has been running flawlessly on Win10 and Android, and these days it's starting to build an iOS build and release environment, because you've never used MacOS before, and it's not familiar. Should be the most popular in the internet, blue thin, shiitake mushrooms. Okay, step into the chase, pits process is recorded as followsDevelopment Environment Physical machine:Windows Server virtual machines:VMware? Workstation Pro 12.5.0 build-4352439MacOS 10.12QT 5.7

Xcode 8.1

1, the physical machine also open Microsoft's virtual machine Hyper-V, when creating a new virtual machine in VMware will be error. First off all theHyper-V relatedservice, and then uninstallHyper-V will work with VMware.. The installation process can be consulted: HTTP://WWW.TH7.CN/PROGRAM/IOS/201407/231980.SHTML2, installing MacOS in VMware, installing from the storeXCode, the first 10.9 of the system, the download prompts to upgrade the system, so installed the latest MacOS, of course, can also download the low version of Xcode from the Internet. 3, QT5.7 from the official QT website to download the installation, after the installation of the QT project, the compiler prompts the following errorError:xcode not set up properly. Need to confirm the license agreement by Running/usr/bin/xcodebuild. Solution: http://blog.csdn.net/l241002209/ Article/details/52891070?locationnum=2&fps=14, starting from XCode7 can be exempt from certificatesReal Machine debugging, no developer account, configuration process reference the following article, in this process, to ensure that the phone has been plugged in the computer. Http://www.jianshu.com/p/62c5393022ca5, I'm inThe Apple phone is always missing from the VM's MacOS system, and the following article addresses the issue by changing the USB compatibility to "USB 2.0"http://blog.csdn.net/yagerfgcs/article/details/514067416, continue compiling QT code, and also prompt the following error: Project error:current iphoneos SDK Version (10.1) is too old. Please upgrade Xcode.follow this piece of paper (http://blog.csdn.net/willib/article/details/52829317) Delete the file (QT_INSTALL_FOLDER/5.7/IOS/MKSPECS/MACX-IOS-CLANG/FEATURES/SDK.PRF) Two lines of code
  1. LessThan (qmake_mac_sdk_version,  " 8.0 "
  2. Error ("Current # #QMAKE_MAC_SDK SDK version (# #QMAKE_MAC_SDK_VERSION) are too old. Please upgrade Xcode. " ) 
7.qt code generates iOS apps, starting with compiling QT source code, generating Xcode projects, then running the Xcode project directly, deploying to an Apple phone or virtual device. http://blog.csdn.net/wsj18808050/article/details/422984098. Immediately after using Xcode, the following problems are encountered:= = = BUILD TARGET farmer of PROJECT farmer with CONFIGURATION Debug = = =
Check Dependencies
Signing for "farmer" requires a development team. Select a development team in the project editor.Code signing is required to product type ' application ' in SDK ' IOS 10.1 ' * * BUILD FAILED * *
The following build commands failed:
Check Dependencies(1 failure)Make : * * * [Xcodebuild-debug-iphoneos] Error16:42:06: Process "/usr/bin/make" exits, exit code 2. Error while building/deploying project Farmer (Kit:iphoneos-clang Qt 5.7.0 for IOS)When executing step ' make '16:42:06:elapsed time:00:24.This is because I didn't put iphone6s on the computer. 9, and found that my source code in QT directly error, this time I have smashed the computer impulseArguments:-nonrelocatable QtQuick 2.7/users/wang/qt5.7.0/5.7/ios/qmlThis plugin does not support createplatformopenglcontext!qqmlcomponent:component is isn't readyfile:///Users/wang/Qt5.7.0/5.7/ios/qml/loaddependencies.qml:2:1:module "QtQuick" plugin "Qtquick2plugin" not FoundError hints in QT:module "QtQuick.Controls.Styles" is not installed
Search the Internet for a long time, the reason is unexpectedlyQML2 does not support iOS development, this is to tease me to play, not claiming that the whole platform is OK. Http://qtcn.org/bbs/simple/?t55713.html still honestly use QML1 to develop it. Listen, mu Jongxiaoxia singing "Finally know the truth of my tears fall down." 10, there is a point to note that I initially only allocated 15G space for the virtual machine, and then increased to 30G, not enough, and then increased to 50G, and finally increased to 70G. Here to remindat least 50G more space is reserved. Method for extending space (http://www.cnblogs.com/atree/p/MacOSX_diskutil_xcode.html):1, first extended in VMware, 2, and then into the virtual machine MacOS operating system using the Diskutil command

(1). Open terminal, enter Diskutil list

(2). Find the partition you need to expand from the list that appears, such as. My disk has 107.4G, but the system partition is 42.1GB. (The ID of the partition is usually DISKXSX, my id is disk0s2);

(3). Then enter Diskutil resizevolume disk0s2 100GB, where DISK0S2 is the target size for the ID,100GB of the corresponding partition (the target size cannot exceed the total of this disk); Enter, and wait for the completion to be used.

Toss for three days, summarize: using QT to develop cross-platform applications, if the conditions allow, it is best to develop in the MacOS environment, can be guaranteed to debug both Android and iOS. On November 7, 2016 from Jinan to Luoyang on the train wind up clouds + +



From for notes (Wiz)



Use QT to develop iOS apps in MacOS

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.