[Scons-users] scons and openmp problem
mohammed shambakey
shambakey1 at gmail.com
Thu May 5 13:10:46 EDT 2016
Hi
I'm trying to compile a c++ program that has openmp reduction clause. When
running scons, it gives me the following error:
scons: Building targets ...
g++ -o etc/section.o -c -Wall -fopenmp -O2 -Ietc -Ilib etc/section.cc
etc/section.cc: In function 'int data_location(Section*, char*)':
etc/section.cc:18: error: expected '+', '*', '-', '&', '^', '|', '&&', or
'||' before 'min'
scons: *** [etc/section.o] Error 1
scons: building terminated because of errors.
I tried to compile the etc/section.cc file with g++ only as indicated in
the second line in the above error as follows:
g++ -o etc/section.o -c -Wall -fopenmp -O2 -Ietc -Ilib etc/section.cc
and it compiled correctly.
The g++ version is g++ (GCC) 5.3.0, with support for openmp 4.0. I tried
simple example for "reduction" with "min" operation and it worked correctly
when compiled with g++ (I haven't tried it with scons)
I don't know what is wrong?
Thanks
--
Mohammed
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist4.pair.net/pipermail/scons-users/attachments/20160505/0d86d0bb/attachment.html>
More information about the Scons-users
mailing list