-
Notifications
You must be signed in to change notification settings - Fork 0
Installation on macOS with Apple Silicon chip from source code
Tested on MacBook Pro with M1 chip and macOS Ventura.
Xcode developer tools are needed for installing Homebrew and MacPort. Homebrew is needed for isntalling addtional libraries: jpeg-turbo, libtiff, gsl. MacPort is needed for installing clang15 which has OpenMP and other funcionality required by this project.
- Download and install latest Xcode from Apple developer website
- Installing from Mac App Store is sometimes malfunctioning
- In shell (Terminal) run:
xcode-select --install
More info here: website with instructions to install Xcode
Homebrew is package manager for macOS (needs Xcode).
- In shell (Terminal) run:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
More info here: website with instruction to install Homebrew
ColorScreen requires several packages:
-
jpeg-turbo –
brew install jpeg-turbo(run in shell) -
libtiff –
brew install libtiff(run in shell) -
gsl –
brew install gsl(run in shell)
On Mac with Apple Silicon chip Homebrew installs packages into folder /opt/homebrew/Cellar/ Note: During configuration it can be handy to see mac’s hidden folders (⇧⌘.)
From MacPorts website download and open installer for macOS Ventura (needs Xcode).
For running ColorScreen on Mac with Apple Silicon chip you need a different clang than default. You need a compiler that support OpenMP and -march=native.
After installing MacPorts run in shell (Terminal): sudo port install clang-15
More info here: clang-15 MacPort website
Hugin is software used by colorscreen-stich for stiching multiple shots into one image. Download and install Hugin.
For using colorscreen-stich you need to export cpfind command to your shell.
You can do that temporarily from shell (Terminal): export PATH=/Applications/Hugin/tools_mac:$PATH.
To do this permanently, you have to edit the shell profile.
For macOS Catalina and newer the default shell is zsh. You can edit it's config file (~/.zshrc or ~/.zsh_profile) by:
nano ~/.zshrc
This creates the file and opens it, if it wasn't created before, or opens the already existing one. Add an export line to the file:
export PATH=/Applications/Hugin/tools_mac:$PATH
Confirm the change by ⌃O, hit Return and close the editor by ⌃X.
Then reopen shell (Terminal) to apply the changes. If everything went good, echo $PATH should contain path to cpfind. You can also check it by typing cpfind in shell (Terminal). If cpfind was not found, you can try edit the ~/.zsh_profile, or you have bash (or other) shell and you need to apply this method on bash (or other) config files.
More info here: Setting PATH variable.
- Clone (or download) ColorScreen repository.
- From shell (Terminal) in the folder with source code (git repository) run following:
- replace
<path where to build>with your custom destination, where you want to have ColorScreen
- replace
CC="/opt/local/bin/clang-mp-15" CXX="/opt/local/bin/clang++-mp-15" CXXFLAGS="-I/opt/homebrew/include" LDFLAGS="-L/opt/homebrew/lib" ./configure --prefix=<path where to build>
make install