You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: BUILD.macOS.md
+24-8Lines changed: 24 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -3,37 +3,48 @@ Build instructions for Mac OS
3
3
4
4
Environment Setup
5
5
-----------------
6
+
6
7
### XCode
7
-
Can be installed via the App Store. Once this is done, you may need to install the command line tooling too, to do this run:
8
+
9
+
Can be installed via the App Store. Once this is done, you may need to install the command line tooling too, to do this
10
+
run:
8
11
9
12
xcode-select --install
10
13
11
-
Ensure you have development Frameworks for at least OS X 10.8 installed, with the typical compiler toolchain and "git". Avoid the version of cmake supplied, we need a newer one (see later).
14
+
Ensure you have development Frameworks for at least OS X 10.8 installed, with the typical compiler toolchain and "git".
15
+
Avoid the version of cmake supplied, we need a newer one (see later).
12
16
13
17
### Qt6
18
+
14
19
#### Option 1: Using Qt official sources
20
+
15
21
Install the latest stable version of Qt6 LTS (6.2.4 at the moment): <http://www.qt.io/download-open-source/>.
16
22
17
-
If it tells you that XCode 5.0.0 needs to be installed, go to XCode > Preferences > Locations and make a selection in the _Command Line Tools_ box.
23
+
If it tells you that XCode 5.0.0 needs to be installed, go to XCode > Preferences > Locations and make a selection in
24
+
the _Command Line Tools_ box.
18
25
19
26
Add Qt6 to your PATH environment variable, adding to your `.bash_profile` file the following line:
20
27
21
28
export PATH=$PATH:~/Qt/6.2.4/clang_64/bin
22
29
23
30
Adjust accordingly if you customized the Qt install directory.
24
31
25
-
#### Option 2: Using Homebrew
32
+
#### Option 2: Using Homebrew
33
+
26
34
Install Qt6:
27
35
28
36
brew install qt6
29
37
30
38
### Cmake/OpenSSL
31
-
Building a Multipass package requires cmake 3.9 or greater. OpenSSL is also necessary at build time. The most convenient means to obtain these dependencies is with Homebrew <https://brew.sh/>.
39
+
40
+
Building a Multipass package requires cmake 3.9 or greater. OpenSSL is also necessary at build time. The most convenient
41
+
means to obtain these dependencies is with Homebrew <https://brew.sh/>.
32
42
33
43
brew install cmake openssl@3
34
44
35
45
Building
36
46
---------------------------------------
47
+
37
48
cd <multipass>
38
49
git submodule update --init --recursive
39
50
@@ -45,7 +56,8 @@ Alternatively if using Qt6 from Homebrew, do
or, if on Apple silicon, brew will store the Qt binaries in a different location. Additionally, OpenSSL will be in a similar location; `/opt/homebrew/Cellar/openssl@3`, which can be set in the project level `CMakeLists.txt` file.
59
+
or, if on Apple silicon, brew will store the Qt binaries in a different location. Additionally, OpenSSL will be in a
60
+
similar location; `/opt/homebrew/Cellar/openssl@3`, which can be set in the project level `CMakeLists.txt` file.
Take care to adjust the `CMAKE_PREFIX_PATH` to the location you installed Qt above, or else cmake will complain about missing Qt6.
69
+
Take care to adjust the `CMAKE_PREFIX_PATH` to the location you installed Qt above, or else cmake will complain about
70
+
missing Qt6.
58
71
59
72
Building in QtCreator
60
73
---------------------
61
-
QtCreator will be missing all the environment adjustments made above. To get cmake to successfully configure, open the project and adjust the Build Environment (click the "Projects" icon of the left pane, scroll down). Then add the entries to the $PATH as above, and add the variables reported by `opem config env`. CMake should now succeed, and QtCreator allow you to edit the project files.
74
+
QtCreator will be missing all the environment adjustments made above. To get cmake to successfully configure, open the
75
+
project and adjust the Build Environment (click the "Projects" icon of the left pane, scroll down). Then add the entries
76
+
to the $PATH as above, and add the variables reported by `opem config env`. CMake should now succeed, and QtCreator
Install the latest stable version of Qt6 (6.2.4 at the moment): <https://www.qt.io/download-thank-you?os=windows/>.
27
34
28
35
In the online installer, under Qt, select MSVC 2019 64-bit.
29
36
30
37
If you already have Qt installed, run the MaintenanceTool included in the Qt directory to update to the latest version.
31
38
32
-
Alternatively, download the [qtbase archive](https://download.qt.io/online/qtsdkrepository/windows_x86/desktop/qt6_624/qt.qt6.624.win64_msvc2019_64/6.2.4-0-202203140926qtbase-Windows-Windows_10_21H2-MSVC2019-Windows-Windows_10_21H2-X86_64.7z) and extract it to `C:\Qt` (so it ends up in `C:\Qt\6.2.4`).
0 commit comments