Apple LLVM 9.0 Error

Hi,


I been using Xcode for a while to develope parallel computing programs in C/C++.

Unfortunately, since I upgraded the Xcode to the latest version (v9.0), I get an error saying:


"Apple LLVM 9.0 Error, Cannot specify -o when generating multiple output files."


In order to use OpenMP and OpenMPI, I apply the following changes to the project:


Add user defines:

CC = /usr/local/Cellar/llvm/4.0.1/bin/clang

CXX = /usr/local/Cellar/llvm/4.0.1/bin/clang++

MPI = /usr/local/opt/openmpi/bin/mpic++


Add Other C Flag:

-fopenmp


Add the following paths to Header Search Path:

/usr/local/Cellar/open-mpi/2.1.1/include

/usr/local/opt/llvm/lib/clang/4.0.1/include


Add the following paths to Library Search Path:

/usr/local/Cellar/open-mpi/2.1.1/lib

/usr/local/Cellar/llvm/4.0.1/lib


Add these libs to the Build Phase at section Link Binary..:

/usr/local/Cellar/llvm/4.0.1/lib/libiomp5.dylib

/usr/local/Cellar/open-mpi/2.1.1/lib/libmpi.dylib


Set Enable Modules to NO.

I would really appreciate it if someone knows how to fix that.

Regards,

Almog.

Answered by liwoog in 267502022

Set "Enable Index-While-Building Functionality" to "No"

Accepted Answer

Set "Enable Index-While-Building Functionality" to "No"

Apple LLVM 9.0 Error
 
 
Q