Mac m2pro homebrew 安装qt5

brew install qt@5

apple@appledeMBP qt-everywhere-src-5.14.2 % brew install qt@5

==> Fetching dependencies for qt@5: libpng , freetype , pcre2 , python-packaging , openssl@3 , sqlite , glib , jpeg-turbo , libtiff , md4c , giflib and webp

==> Fetching libpng

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/libpng-1.6.46.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching freetype

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/freetype-2.13.3.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching pcre2

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/pcre2-10.44.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching python-packaging

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/python-packaging-24.2.all.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching openssl@3

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/openssl%403-3.4.1.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching sqlite

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/sqlite-3.49.0.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching glib

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/glib-2.82.4.arm64_ventura.bottle.1.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching jpeg-turbo

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/jpeg-turbo-3.1.0.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching libtiff

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/libtiff-4.7.0.arm64_ventura.bottle.1.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching md4c

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/md4c-0.5.2.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching giflib

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/giflib-5.2.2.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching webp

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/webp-1.5.0.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Fetching qt@5

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/qt%405-5.15.16.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Installing dependencies for qt@5: libpng , freetype , pcre2 , python-packaging , openssl@3 , sqlite , glib , jpeg-turbo , libtiff , md4c , giflib and webp

==> Installing qt@5 dependency: libpng

==> Pouring libpng-1.6.46.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/libpng/1.6.46: 28 files, 1.4MB

==> Installing qt@5 dependency: freetype

==> Pouring freetype-2.13.3.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/freetype/2.13.3: 68 files, 2.5MB

==> Installing qt@5 dependency: pcre2

==> Pouring pcre2-10.44.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/pcre2/10.44: 237 files, 6.3MB

==> Installing qt@5 dependency: python-packaging

==> Pouring python-packaging-24.2.all.bottle.tar.gz

🍺 /opt/homebrew/Cellar/python-packaging/24.2: 56 files, 491.3KB

==> Installing qt@5 dependency: openssl@3

==> Pouring openssl@3-3.4.1.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/openssl@3/3.4.1: 7,236 files, 33.5MB

==> Installing qt@5 dependency: sqlite

==> Pouring sqlite-3.49.0.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/sqlite/3.49.0: 13 files, 4.7MB

==> Installing qt@5 dependency: glib

==> Pouring glib-2.82.4.arm64_ventura.bottle.1.tar.gz

🍺 /opt/homebrew/Cellar/glib/2.82.4: 504 files, 36.3MB

==> Installing qt@5 dependency: jpeg-turbo

==> Pouring jpeg-turbo-3.1.0.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/jpeg-turbo/3.1.0: 47 files, 3.5MB

==> Installing qt@5 dependency: libtiff

==> Pouring libtiff-4.7.0.arm64_ventura.bottle.1.tar.gz

🍺 /opt/homebrew/Cellar/libtiff/4.7.0: 486 files, 8.5MB

==> Installing qt@5 dependency: md4c

==> Pouring md4c-0.5.2.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/md4c/0.5.2: 20 files, 301.9KB

==> Installing qt@5 dependency: giflib

==> Pouring giflib-5.2.2.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/giflib/5.2.2: 20 files, 547.0KB

==> Installing qt@5 dependency: webp

==> Pouring webp-1.5.0.arm64_ventura.bottle.tar.gz

🍺 /opt/homebrew/Cellar/webp/1.5.0: 64 files, 2.5MB

==> Installing qt@5

==> Pouring qt@5-5.15.16.arm64_ventura.bottle.tar.gz

==> Caveats

We agreed to the Qt open source license for you.

If this is unacceptable you should uninstall.

You can add Homebrew's Qt to QtCreator's "Qt Versions" in:

Preferences > Qt Versions > Link with Qt...

pressing "Choose..." and selecting as the Qt installation path:

/opt/homebrew/opt/qt@5

qt@5 is keg-only, which means it was not symlinked into /opt/homebrew,

because this is an alternate version of another formula.

If you need to have qt@5 first in your PATH, run:

echo 'export PATH="/opt/homebrew/opt/qt@5/bin:$PATH"' >> ~/.zshrc

For compilers to find qt@5 you may need to set:

export LDFLAGS="-L/opt/homebrew/opt/qt@5/lib"

export CPPFLAGS="-I/opt/homebrew/opt/qt@5/include"

==> Summary

🍺 /opt/homebrew/Cellar/qt@5/5.15.16: 10,849 files, 341.1MB

==> Running `brew cleanup qt@5`...

Disable this behaviour by setting HOMEBREW_NO_INSTALL_CLEANUP.

Hide these hints with HOMEBREW_NO_ENV_HINTS (see `man brew`).

==> Caveats

==> qt@5

We agreed to the Qt open source license for you.

If this is unacceptable you should uninstall.

You can add Homebrew's Qt to QtCreator's "Qt Versions" in:

Preferences > Qt Versions > Link with Qt...

pressing "Choose..." and selecting as the Qt installation path:

/opt/homebrew/opt/qt@5

qt@5 is keg-only, which means it was not symlinked into /opt/homebrew,

because this is an alternate version of another formula.

If you need to have qt@5 first in your PATH, run:

echo 'export PATH="/opt/homebrew/opt/qt@5/bin:$PATH"' >> ~/.zshrc

For compilers to find qt@5 you may need to set:

export LDFLAGS="-L/opt/homebrew/opt/qt@5/lib"

export CPPFLAGS="-I/opt/homebrew/opt/qt@5/include"

查看已安装的qt:brew info qt

apple@appledeMBP qt-everywhere-src-5.14.2 % brew info qt

==> qt: stable 6.8.2 (bottled), HEAD

Cross-platform application and UI framework

https://www.qt.io/

Not installed

From: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/q/qt.rb

License: BSD-3-Clause AND GFDL-1.3-no-invariants-only AND GPL-2.0-only AND (GPL-3.0-only WITH Qt-GPL-exception-1.0) AND LGPL-3.0-only

==> Dependencies

Build: cmake , ninja , node , pkgconf , python@3.13 , vulkan-headers , vulkan-loader , molten-vk

Required: assimp , brotli , dbus , double-conversion , freetype , glib , harfbuzz , hunspell , icu4c@76 , jasper , jpeg-turbo , libb2 , libmng , libpng , libtiff , md4c , openssl@3 , pcre2 , sqlite , webp , zstd

==> Requirements

Build: macOS <= 14 (or Linux) , Xcode (on macOS)

==> Options

--HEAD

Install HEAD version

==> Caveats

You can add Homebrew's Qt to QtCreator's "Qt Versions" in:

Preferences > Qt Versions > Link with Qt...

pressing "Choose..." and selecting as the Qt installation path:

/opt/homebrew

==> Analytics

install: 24,085 (30 days), 74,169 (90 days), 338,534 (365 days)

install-on-request: 14,779 (30 days), 47,672 (90 days), 222,323 (365 days)

build-error: 143 (30 days)

apple@appledeMBP qt-everywhere-src-5.14.2 % brew info qt@5

==> qt@5: stable 5.15.16 (bottled) [keg-only]

Cross-platform application and UI framework

https://www.qt.io/

Installed

/opt/homebrew/Cellar/qt@5/5.15.16 (10,849 files, 341.1MB)

Poured from bottle using the formulae.brew.sh API on 2025-02-13 at 14:11:38

From: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/q/qt@5.rb

License: GFDL-1.3-only AND GPL-2.0-only AND GPL-3.0-only AND LGPL-2.1-only AND LGPL-3.0-only

==> Dependencies

Build: node , pkgconf , python@3.12

Required: freetype , glib , jpeg-turbo , libpng , libtiff , md4c , pcre2 , sqlite , webp , zstd , gettext

==> Requirements

Build: Xcode (on macOS)

Required: macOS >= 10.12 (or Linux)

==> Caveats

We agreed to the Qt open source license for you.

If this is unacceptable you should uninstall.

You can add Homebrew's Qt to QtCreator's "Qt Versions" in:

Preferences > Qt Versions > Link with Qt...

pressing "Choose..." and selecting as the Qt installation path:

/opt/homebrew/opt/qt@5

qt@5 is keg-only, which means it was not symlinked into /opt/homebrew,

because this is an alternate version of another formula.

If you need to have qt@5 first in your PATH, run:

echo 'export PATH="/opt/homebrew/opt/qt@5/bin:$PATH"' >> ~/.zshrc

For compilers to find qt@5 you may need to set:

export LDFLAGS="-L/opt/homebrew/opt/qt@5/lib"

export CPPFLAGS="-I/opt/homebrew/opt/qt@5/include"

==> Analytics

install: 9,948 (30 days), 41,078 (90 days), 193,144 (365 days)

install-on-request: 6,554 (30 days), 28,290 (90 days), 127,998 (365 days)

build-error: 47 (30 days)

安装qtcreator

apple@appledeMBP qt-everywhere-src-5.14.2 % brew install --cask qt-creator

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/api/cask.jws.json

==> Downloading https://download.qt.io/official_releases/qtcreator/15.0/15.0.1/qt-creator-opensource-mac-x86_64-15.0.1.dmg

==> Downloading from https://mirrors.sau.edu.cn/qt/official_releases/qtcreator/15.0/15.0.1/qt-creator-opensource-mac-x86_64-15.0.1.dmg

######################################################################################################################################################################################################################################################### 100.0%

==> Installing Cask qt-creator

==> Moving App 'Qt Creator.app' to '/Applications/Qt Creator.app'

🍺 qt-creator was successfully installed!

如果使用cmake

apple@appledeMBP qt-everywhere-src-5.14.2 % brew install cmake

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/api/formula.jws.json

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/api/cask.jws.json

Warning: Treating cmake as a formula. For the cask, use homebrew/cask/cmake or specify the `--cask` flag. To silence this message, use the `--formula` flag.

==> Fetching cmake

==> Downloading https://mirrors.aliyun.com/homebrew/homebrew-bottles/cmake-3.31.5.arm64_ventura.bottle.tar.gz

######################################################################################################################################################################################################################################################### 100.0%

==> Pouring cmake-3.31.5.arm64_ventura.bottle.tar.gz

==> Caveats

To install the CMake documentation, run:

brew install cmake-docs

Emacs Lisp files have been installed to:

/opt/homebrew/share/emacs/site-lisp/cmake

==> Summary

🍺 /opt/homebrew/Cellar/cmake/3.31.5: 3,767 files, 56.8MB

==> Running `brew cleanup cmake`...

Disable this behaviour by setting HOMEBREW_NO_INSTALL_CLEANUP.

Hide these hints with HOMEBREW_NO_ENV_HINTS (see `man brew`).

apple@appledeMBP qt-everywhere-src-5.14.2 % cmake -v

CMake Error: Unknown argument -v

CMake Error: Run 'cmake --help' for all supported options.

apple@appledeMBP qt-everywhere-src-5.14.2 % cmake --version

cmake version 3.31.5

CMake suite maintained and supported by Kitware (kitware.com/cmake).

如果使用gcc

brew install gcc

相关推荐
二十七剑14 分钟前
jvm中各个参数的理解
java·jvm
Macdo_cn3 小时前
Infuse Pro for Mac v8.1 全能视频播放器 支持M、Intel芯片
macos·音视频
七禾页话4 小时前
垃圾回收知识点
java·开发语言·jvm
软件技术NINI6 小时前
Deepseek本地部署指南:在linux服务器部署,在mac远程web-ui访问
linux·服务器·macos
进击ing小白7 小时前
QSplashScreen --软件启动前的交互
qt
清风细雨_林木木11 小时前
Mac 清理缓存,提高内存空间
macos·缓存
Macdo_cn11 小时前
Screen Wonders for Mac v3.3.1 3D屏保应用 支持M、Intel芯片
macos·音视频
终极定律12 小时前
qt:输入控件操作
开发语言·qt
道剑剑非道16 小时前
QT开发技术 【opencv图片裁剪,平均哈希相似度判断,以及获取游戏窗口图片】
qt·opencv·哈希算法
年轮不改16 小时前
ARM Linux平台下 OpenCV Camera 实验
linux·arm开发·qt