Workaround to install MAGMA on macOS Sierra

Open discussion for MAGMA library (Matrix Algebra on GPU and Multicore Architectures)
Post Reply
joecon
Posts: 1
Joined: Wed Nov 23, 2016 4:42 pm

Workaround to install MAGMA on macOS Sierra

Post by joecon » Wed Nov 23, 2016 4:55 pm

I recently had to install MAGMA on macOS 10.12 Sierra, but ran into a few compatibility issues when trying to build it. I'm posting the workaround here in case anyone else is having trouble getting it built on Sierra.

The problem is that nvcc, which is used to compile some parts of MAGMA, requires an older version of clang to work, and other components seem to require features (OpenMP for example) that this version of clang doesn't support.

The first step is to downgrade your version of clang so that nvcc will work. I used the instructions here to do that: http://stackoverflow.com/questions/3625 ... 0#36590330

Next, you'll have to install GNU GCC to compile the rest of MAGMA; The easiest way to do that is with brew, which can be installed from here: http://brew.sh/

Once you've installed brew, you can install GNU GCC 6 with the following command:

Code: Select all

brew install gcc
This should install GNU GCC 6 as "gcc-6"

Finally, change your make.inc file to specify to use GNU GCC:

Code: Select all

# programs

CC        = gcc-6
CXX       = g++-6
NVCC      = nvcc
FORT      = gfortran
After this everything should build!

mgates3
Posts: 842
Joined: Fri Jan 06, 2012 2:13 pm

Re: Workaround to install MAGMA on macOS Sierra

Post by mgates3 » Tue Nov 29, 2016 10:59 am

Thanks. While MAGMA supports OpenMP, it shouldn't require it.
-mark

Post Reply