-
Notifications
You must be signed in to change notification settings - Fork 1
MacOS user build guidance
Rongzhen Chen edited this page May 29, 2020
·
17 revisions
1. Install Homebrew
- gcc:
brew install gcc
- Clang:
brew install llvm
3. Download Urho3D 1.7.1 Prebuilt
- Unzip folder should be in the path where can be easily accessed later
Guidance with images is available here :)
-
Preferences
->Build, Execution, Deployment
->Toolchains
- Press the
+
sign - Select
System
in drop-down menu - Fill in config info:
- Name:
GNU GCC${GCC_VERSION}
(Example:GNU GCC9
)(Suggested) - C Compiler:
GCC-${GCC_VERSION}
(Example:gcc-9
) - C++ Compiler:
g++-${GCC_VERSION}
(Example:g++-9
)
- Name:
- For Clang, same step as above but different config info:
- Name:
Clang/LLVM10
(Suggested) - C Compiler:
/usr/local/opt/llvm/bin/clang
- C++ Compiler:
/usr/local/opt/llvm/bin/clang++
- Name:
- Click
OK
-
Preferences
->Build, Execution, Deployment
->CMake
- Press the
+
sign - Fill in config info:
- Build type: Choose
Debug
- Name:
Debug-GNU GCC${GCC_VERSION}
(Suggested) - Toolchain: Choose
GNU GCC${GCC_VERSION}
(Or other name for GCC which been added in toolchains) - CMake options:
-DURHO3D_HOME=<PathToYourUrho3Dsdk>
(Example:-DURHO3D_HOME=/Users/Bob/Downloads/Urho3D-1.7.1
)
- Build type: Choose
- For Clang, same step as above but different config info:
- Build type: Choose
Debug
- Name:
Debug-Clang/LLVM10
(Suggested) - Toolchain: Choose
Clang/LLVM10
(Or other name for Clang which been added in toolchains) - CMake options:
-DURHO3D_HOME=${PATH_TO_URHO3D}
(Example:-DURHO3D_HOME=/Users/Bob/Downloads/Urho3D-1.7.1
)
- Build type: Choose
- Click
OK
- Delete the
cmake-build-${CMAKE_CONFIG_NAME}
folders - Click
CMake
tab in the bottom - Click the first icon on the left side to reload CMake project
- Choose target
-
smartcar_emul
for the emulator - Several Test target if you need them
-
- Choose CMake config
-
Debug-GNU GCC${GCC_VERSION}
orDebug-Clang/LLVM10
-
- Click
Build
,Run
orDebug
ItJustWorks™