clang+openMP

Joined
Jun 11, 2015
Messages
6
Reaction score
0
Points
1
I am struggling to install openMP with clang.. I also tried to do it via gcc but vtk installation using gcc throws error: Objective-C++ compiler not installed on this system
 

vansmith

Senior Member
Joined
Oct 19, 2008
Messages
19,924
Reaction score
559
Points
113
Location
Queensland
Your Mac's Specs
Mini (2014, 2018, 2020), MBA (2020), iPad Pro (2018), iPhone 13 Pro Max, Watch (S6)
Have you installed Apple's dev tools? From the sounds of the error, you haven't yet installed them.
 
OP
P
Joined
Jun 11, 2015
Messages
6
Reaction score
0
Points
1
I believe u are asking for Xcode... it is installed and it uses clang as default compiler.. using that I am not able to integrate openMP with it...
 

vansmith

Senior Member
Joined
Oct 19, 2008
Messages
19,924
Reaction score
559
Points
113
Location
Queensland
Your Mac's Specs
Mini (2014, 2018, 2020), MBA (2020), iPad Pro (2018), iPhone 13 Pro Max, Watch (S6)
Do you get an error message? You only note the problems with using GCC.
 
OP
P
Joined
Jun 11, 2015
Messages
6
Reaction score
0
Points
1
I am not able to build OpenMP Runtime Library which is required for openMP+clang ( https://clang-omp.github.io )... I get following error while trying to build using clang

make compiler=clang
omp_root=.
omp_os=macos
arch=intel64
compiler=clang
mic=no
mode=release
jobs=1
Created ./tmp directory
./tools/build.pl --arch=intel64 --mode=release lib inc common -- -j1
./tools/build.pl --arch=intel64 --mode=release lib inc common -- -j1
build.pl: (i) Goals : lib inc common -j1
build.pl: (i) Configurations : 1
build.pl: (i) Making : 1 of 1 : mac_32e-rtl_5_nor_dyn.rel.41.c0.s0...-dhcp205
-------------------------------------------------------------------------------
Started : 2015-06-11 21:31:51 UTC
Root dir : /Users/prafulag/Downloads/openmp/runtime
Build dir : tmp/src/makefile.mk
-------------------------------------------------------------------------------
----- 1/1 --- making lib inc common -----
Build : 20140926
Tools : perl=5.18.2 make=3.81 clang=3.5 clang++=3.5
Config : CPLUSPLUS=on COVERAGE=off DEBUG_INFO=off DIAG=off LIB_TYPE=norm LINK_TYPE=dyna OMP_VERSION=41 OPTIMIZATION=on VERSION=5 CPPFLAGS= CFLAGS= CXXFLAGS= FFLAGS= LDFLAGS= OMPT_SUPPORT=off OMPT_BLAME=on OMPT_TRACE=on
make[1]: *** No rule to make target `dlfcn.h', needed by `ittnotify_static.o'. Stop.
-------------------------------------------------------------------------------
Finished : 2015-06-11 21:31:51 UTC
Elapsed : 00:00:00
Result : --- Failure ---
-------------------------------------------------------------------------------

build.pl: (i) --- Failure --- : mac_32e-rtl_5_nor_dyn.rel.41.c0.s0...-dhcp205
build.pl: (i) Successes : 0 of 1
build.pl: (i) Failures : 1 of 1
build.pl: (i) Time elapsed : 00:00:00
build.pl: (i) Overall result : --- Failure ---
make: *** [omp] Error 3
 

vansmith

Senior Member
Joined
Oct 19, 2008
Messages
19,924
Reaction score
559
Points
113
Location
Queensland
Your Mac's Specs
Mini (2014, 2018, 2020), MBA (2020), iPad Pro (2018), iPhone 13 Pro Max, Watch (S6)
According to their website, you can install it using Homebrew which would be magnitudes easier than doing it manually. Give that route a try.
 
OP
P
Joined
Jun 11, 2015
Messages
6
Reaction score
0
Points
1
I have installed it using brew instructions... did it earlier... the issue was I had to change the paths for clang++/clang to new clang-omp/++ which I did not.. openMP is found now.. but the issue is that building says linker not found... Out for the following instructions, I am not able to find how to do the last step.. should I change CMAKE_LINKER to the given path or add some other environment variable...

Add a new user-defined setting CC with the value /usr/local/bin/clang-omp
Add -fopenmp to Other C Flags
Add /usr/local/include to Header Search Paths
Set Enable Modules (C and Objective-C) to No.
Under Build Phases
Add /usr/local/lib/libiomp5.dylib to Link Binary With Libraries
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top