Skip to content

Build Instructions for OS X

Simon Fuhrmann edited this page Apr 25, 2022 · 33 revisions

Wiki HomeMVE Users GuideBuild Instructions for OS X

General build instructions

  • Run xcode-select --install to install the macOS Command Line Tools
  • Install homebrew (from http://mxcl.github.com/homebrew/)
  • Make sure brew doctor doesn't show any errors
  • brew install git libpng jpeg libtiff qt@5
  • brew link --force qt@5
  • Clone MVE repository
  • git clone git://github.com/simonfuhrmann/mve.git
  • Build MVE and UMVE
  • cd mve; make
  • cd apps/umve; qmake; make; ./umve

Toubleshooting

  • libgomp not found?
  • Remove the OPENMP=-fopenmp line from Makefile.inc
  • Alternative: Temporary export OPENMP="" in your shell
  • Problems with qmake?
  • Add /usr/local/bin and/or /usr/local/opt/qt/bin to /etc/paths
  • Maybe add /usr/local/opt/qt/lib to your LIBRARY_PATH

For Apple m1 chip users

  • In homebrew of new version, packages are installed in /opt/homebrew/... instead of /usr/local/..., which is the default path.
  • Execute export CPATH=/opt/homebrew/include and export LIBRARY_PATH=/opt/homebrew/lib to set environmental variable.
  • -march=native not found? Edit Makefile.inc and change it. Starting with clang 13, -mcpu=apple-m1 is available. Starting with clang 15, -march=native is available for M1.
  • undeclared identifier '__builtin_ia32_emms'... for using mmintrin.h, a header for x86 intrinsics. Comment line 42, 43 in libs/sfm/nearest_neighbor.cc.