从安装程序在 Mountain Lion 上安装 Qt

Posted

技术标签:

【中文标题】从安装程序在 Mountain Lion 上安装 Qt【英文标题】:Qt installation on Mountain Lion from installer 【发布时间】:2012-11-01 12:05:46 【问题描述】:

我想在 Mountain Lion 上安装 Qt。为此,我去了http://qt-project.org/downloads 并下载了最新的Qt 库安装程序(4.8.3)。然后我按照说明进行操作,在安装过程结束时,我收到一条消息说“安装失败”。有人在Mountain Lion 下遇到这个版本的Qt 问题吗?

非常感谢!

托马斯。

P.S.:这是安装程序的完整日志:

Nov  1 10:48:43 Macintosh.local Installer[99200]: @(#)PROGRAM:Install  PROJECT:Install-735
Nov  1 10:48:43 Macintosh.local Installer[99200]: @(#)PROGRAM:Installer  PROJECT:Installer-614
Nov  1 10:48:43 Macintosh.local Installer[99200]: Hardware: MacBookPro9,1 @ 2.60 GHz (x 8), 8192 MB RAM
Nov  1 10:48:43 Macintosh.local Installer[99200]: Running OS Build: Mac OS X 10.8.2 (12C60)
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: PATH=/usr/bin:/bin:/usr/sbin:/sbin
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: TMPDIR=/var/folders/3x/1w64hbq54698swps28n102q00000gp/T/
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: SHELL=/bin/bash
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: HOME=/Users/twalter
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: USER=twalter
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: LOGNAME=twalter
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: SSH_AUTH_SOCK=/tmp/launch-yL5eiv/Listeners
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: Apple_Ubiquity_Message=/tmp/launch-kEy9gO/Apple_Ubiquity_Message
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: Apple_PubSub_Socket_Render=/tmp/launch-gkJ0hE/Render
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: DISPLAY=/tmp/launch-WODr77/org.macosforge.xquartz:0
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: COMMAND_MODE=unix2003
Nov  1 10:48:43 Macintosh.local Installer[99200]: Env: __CF_USER_TEXT_ENCODING=0x1F6:0:0
Nov  1 10:48:43 Macintosh.local Installer[99200]: Qt  Installation Log
Nov  1 10:48:43 Macintosh.local Installer[99200]: Opened from: /Volumes/Qt 4.8.3/Qt.mpkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/Qt.mpkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/Qt.mpkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/packages/Qt_tools.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/packages/Qt_tools.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/packages/Qt_libraries.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/packages/Qt_libraries.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/packages/Qt_docs.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/packages/Qt_docs.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/packages/Qt_examples.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/packages/Qt_examples.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/packages/Qt_headers.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/packages/Qt_headers.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/packages/Qt_imports.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/packages/Qt_imports.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/packages/Qt_plugins.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/packages/Qt_plugins.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = x-disc://Qt%204.8.3/packages/Qt_translations.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: fileURLForURL = file://localhost/Volumes/Qt%204.8.3/packages/Qt_translations.pkg
Nov  1 10:48:44 Macintosh.local Installer[99200]: Product archive /Volumes/Qt 4.8.3/Qt.mpkg trustLevel=100
Nov  1 10:48:44 Macintosh.local Installer[99200]: Referenced component packages (8) trustLevel=100
Nov  1 10:49:58 Macintosh.local Installer[99200]: InstallerStatusNotifications plugin loaded
Nov  1 10:50:09 Macintosh.local runner[99252]: Administrator authorization granted.
Nov  1 10:50:09 Macintosh.local Installer[99200]: ================================================================================
Nov  1 10:50:09 Macintosh.local Installer[99200]: User picked Standard Install
Nov  1 10:50:09 Macintosh.local Installer[99200]: Choices selected for installation:
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Upgrade: "Qt"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt.mpkg : Qt Packages : 0.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Upgrade: "Qt Tools"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt_tools.pkg : com.trolltech.qt4.tools : 4.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Upgrade: "Qt Libraries"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt_libraries.pkg : com.trolltech.qt4.libs : 4.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Install: "Qt Documentation"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt_docs.pkg : com.trolltech.qt4.docs : 4.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Install: "Qt Examples"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt_examples.pkg : com.trolltech.qt4.examples : 4.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Upgrade: "Qt Headers"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt_headers.pkg : com.trolltech.qt4.headers : 4.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Upgrade: "Qt Imports"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt_imports.pkg : com.trolltech.qt4.imports : 4.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Upgrade: "Qt Plugins"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt_plugins.pkg : com.trolltech.qt4.plugins : 4.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]:   Upgrade: "Qt Translations"
Nov  1 10:50:09 Macintosh.local Installer[99200]:       Qt_translations.pkg : com.trolltech.qt4.translations : 4.8.0.4.8
Nov  1 10:50:09 Macintosh.local Installer[99200]: ================================================================================
Nov  1 10:50:09 Macintosh.local Installer[99200]: It took 0.00 seconds to summarize the package selections.
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFPKGDerivedDocument sortedPackageLocations]: result = (
        "file://localhost"
    )
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: location = file://localhost
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/Qt.mpkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/packages/Qt_tools.pkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/packages/Qt_libraries.pkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/packages/Qt_docs.pkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/packages/Qt_examples.pkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/packages/Qt_headers.pkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/packages/Qt_imports.pkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/packages/Qt_plugins.pkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/packages/Qt_translations.pkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: -[IFDInstallController(Private) _buildInstallPlan]: file://localhost/Volumes/Qt%204.8.3/Qt.mpkg
Nov  1 10:50:09 Macintosh.local Installer[99200]: Set authorization level to root for session
Nov  1 10:50:09 Macintosh.local runner[99252]: Administrator authorization granted.
Nov  1 10:50:09 Macintosh.local Installer[99200]: Will use PK session
Nov  1 10:50:09 Macintosh.local Installer[99200]: Starting installation:
Nov  1 10:50:09 Macintosh.local Installer[99200]: Configuring volume "Macintosh HD"
Nov  1 10:50:09 Macintosh.local Installer[99200]: Preparing disk for local booted install.
Nov  1 10:50:09 Macintosh.local Installer[99200]: Free space on "Macintosh HD": 700.85 GB (700845834240 bytes).
Nov  1 10:50:09 Macintosh.local Installer[99200]: Create temporary directory "/var/folders/3x/1w64hbq54698swps28n102q00000gp/T//Install.992003AWHIN"
Nov  1 10:50:09 Macintosh.local Installer[99200]: IFPKInstallElement (10 packages)
Nov  1 10:50:09 Macintosh.local Installer[99200]: Using authorization level of root for IFPKInstallElement
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: ----- Begin install -----
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: request=PKInstallRequest <10 packages, destination=/>
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: packages=(
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/Qt.mpkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/packages/Qt_tools.pkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/packages/Qt_libraries.pkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/packages/Qt_docs.pkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/packages/Qt_examples.pkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/packages/Qt_headers.pkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/packages/Qt_imports.pkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/packages/Qt_plugins.pkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/packages/Qt_translations.pkg>",
        "PKJaguarPackage <file://localhost/Volumes/Qt%204.8.3/Qt.mpkg>"
    )
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: Will do receipt-based obsoleting for package identifier com.trolltech.qt4.tools (prefix path=)
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: Will do receipt-based obsoleting for package identifier com.trolltech.qt4.libs (prefix path=)
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: Will do receipt-based obsoleting for package identifier com.trolltech.qt4.headers (prefix path=)
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: Will do receipt-based obsoleting for package identifier com.trolltech.qt4.imports (prefix path=)
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: Will do receipt-based obsoleting for package identifier com.trolltech.qt4.plugins (prefix path=)
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: Will do receipt-based obsoleting for package identifier com.trolltech.qt4.translations (prefix path=)
Nov  1 10:50:09 Macintosh.local installd[38810]: PackageKit: Extracting file://localhost/Volumes/Qt%204.8.3/packages/Qt_tools.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root, uid=0)
Nov  1 10:50:10 Macintosh.local installd[38810]: PackageKit: Extracting file://localhost/Volumes/Qt%204.8.3/packages/Qt_libraries.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root, uid=0)
Nov  1 10:50:11 Macintosh.local installd[38810]: PackageKit: Extracting file://localhost/Volumes/Qt%204.8.3/packages/Qt_docs.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root, uid=0)
Nov  1 10:50:16 Macintosh.local installd[38810]: PackageKit: Extracting file://localhost/Volumes/Qt%204.8.3/packages/Qt_examples.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root, uid=0)
Nov  1 10:50:20 Macintosh.local installd[38810]: PackageKit: Extracting file://localhost/Volumes/Qt%204.8.3/packages/Qt_headers.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root, uid=0)
Nov  1 10:50:21 Macintosh.local installd[38810]: PackageKit: Extracting file://localhost/Volumes/Qt%204.8.3/packages/Qt_imports.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root, uid=0)
Nov  1 10:50:21 Macintosh.local installd[38810]: PackageKit: Extracting file://localhost/Volumes/Qt%204.8.3/packages/Qt_plugins.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root, uid=0)
Nov  1 10:50:21 Macintosh.local installd[38810]: PackageKit: Extracting file://localhost/Volumes/Qt%204.8.3/packages/Qt_translations.pkg (destination=/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root, uid=0)
Nov  1 10:50:21 Macintosh.local installd[38810]: PackageKit: update_dyld_shared_cache -overlay /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root
Nov  1 10:50:25 Macintosh.local installd[38810]: PackageKit: prevent user idle system sleep
Nov  1 10:50:25 Macintosh.local installd[38810]: PackageKit: suspending backupd
Nov  1 10:50:25 Macintosh.local installd[38810]: PackageKit: Shoving /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/Cleanup At Startup/PKInstallSandboxManager/1.sandbox/Root (3 items) to /
Nov  1 10:50:26 Macintosh.local install_monitor[99260]: Temporarily excluding: /Applications, /Developer, /Library, /System, /bin, /private, /sbin, /usr
Nov  1 10:50:33 Macintosh.local installd[38810]: PackageKit: Executing script "./postflight" in /Volumes/Qt 4.8.3/packages/Qt_docs.pkg/Contents/Resources
Nov  1 10:50:33 Macintosh.local installd[38810]: PackageKit: Executing script "./postflight" in /Volumes/Qt 4.8.3/packages/Qt_examples.pkg/Contents/Resources
Nov  1 10:50:33 Macintosh.local installd[38810]: ./postflight: env: python: No such file or directory
Nov  1 10:50:33 Macintosh.local install_monitor[99260]: Re-included: /Applications, /Developer, /Library, /System, /bin, /private, /sbin, /usr
Nov  1 10:50:34 Macintosh.local installd[38810]: PackageKit: releasing backupd
Nov  1 10:50:34 Macintosh.local installd[38810]: PackageKit: allow user idle system sleep
Nov  1 10:50:34 Macintosh.local installd[38810]: PackageKit: Install Failed: Error Domain=PKInstallErrorDomain Code=112 "An error occurred while running scripts from the package “Qt_examples.pkg”." UserInfo=0x7feaaa815be0 NSFilePath=./postflight, NSURL=file://localhost/Volumes/Qt%204.8.3/packages/Qt_examples.pkg, PKInstallPackageIdentifier=com.trolltech.qt4.examples, NSLocalizedDescription=An error occurred while running scripts from the package “Qt_examples.pkg”. 
        NSFilePath = "./postflight";
        NSLocalizedDescription = "An error occurred while running scripts from the package \U201cQt_examples.pkg\U201d.";
        NSURL = "file://localhost/Volumes/Qt%204.8.3/packages/Qt_examples.pkg";
        PKInstallPackageIdentifier = "com.trolltech.qt4.examples";
    
Nov  1 10:50:34 Macintosh.local Installer[99200]: install:didFailWithError:Error Domain=PKInstallErrorDomain Code=112 "An error occurred while running scripts from the package “Qt_examples.pkg”." UserInfo=0x7f9cd43c6ca0 NSFilePath=./postflight, NSURL=file://localhost/Volumes/Qt%204.8.3/packages/Qt_examples.pkg, PKInstallPackageIdentifier=com.trolltech.qt4.examples, NSLocalizedDescription=An error occurred while running scripts from the package “Qt_examples.pkg”.
Nov  1 10:50:35 Macintosh.local Installer[99200]: Install failed: The Installer encountered an error that caused the installation to fail. Contact the software manufacturer for assistance.
Nov  1 10:50:35 Macintosh.local Installer[99200]: IFDInstallController D4020140 state = 7
Nov  1 10:50:35 Macintosh.local Installer[99200]: Displaying 'Install Failed' UI.
Nov  1 10:50:35 Macintosh.local Installer[99200]: 'Install Failed' UI displayed message:'The Installer encountered an error that caused the installation to fail. Contact the software manufacturer for assistance.'.

【问题讨论】:

一条评论:我安装了 XCode 4.5.1,包括命令行工具。我还从r.research.att.com/tools 安装了 gcc-42-5666.3-darwin11.pkg(因为我需要不再附带 XCode 命令行工具的 fortran 编译器)。 【参考方案1】:

我之前安装在 Lion 上。也许您可以尝试在 Mac 上编译 Qt 或尝试安装 Qt 4.7。

此链接可能会有所帮助:http://doc.qt.digia.com/latest/install-mac.html

【讨论】:

非常感谢您的回答。编译工作没有问题。现在,我将测试,我是否可以安装 PyQt ... 对不起...... Stack Overflow 的新手。

以上是关于从安装程序在 Mountain Lion 上安装 Qt的主要内容,如果未能解决你的问题,请参考以下文章

在 Mountain Lion 上运行 4.3 版的 iOS 应用程序

无法在 Mountain Lion 上安装 therubyracer -v '0.10.0'

在 Mountain Lion 上使用 Homebrew 安装 mcrypt 支持 php54 的问题

为啥在我安装 Mountain Lion 时 OpenGL 会降级?

OpenCV可以安装在Mac Mountain Lion上的python virtualenv中吗

在 Mountain Lion 上卸载 Xcode 3.2 的问题