Skip to content

Commit 4901e5e

Browse files
committed
Generalizing configure openmp treatment following data.table: part 7
1 parent cf672e5 commit 4901e5e

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

configure

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3290,6 +3290,7 @@ printf %s "checking whether R CMD SHLIB can compile OpenMP via -fopenmp... " >&6
32903290
if test x"$?" = x"0"; then
32913291
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32923292
printf "%s\n" "yes" >&6; }
3293+
can_use_openmp="yes"
32933294
# keep any entries user may have set
32943295
PKG_CXXFLAGS="${PKG_CXXFLAGS} -fopenmp"
32953296
PKG_LIBS="${PKG_LIBS} -fopenmp"
@@ -3373,7 +3374,7 @@ printf "%s\n" "no" >&6; }
33733374
can_use_openmp="no"
33743375
fi
33753376
fi
3376-
fi
3377+
fi
33773378
else
33783379
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
33793380
printf "%s\n" "no" >&6; }

configure.ac

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ if test x"${SYSKERNEL}" = x"Linux"; then
8080
PKG_CXXFLAGS="${PKG_CXXFLAGS} -fopenmp" PKG_LIBS="${PKG_LIBS} -fopenmp" "${R_HOME}/bin/R" CMD SHLIB -fopenmp test-omp.cpp >/dev/null 2>&1
8181
if test x"$?" = x"0"; then
8282
AC_MSG_RESULT([yes])
83+
can_use_openmp="yes"
8384
# keep any entries user may have set
8485
PKG_CXXFLAGS="${PKG_CXXFLAGS} -fopenmp"
8586
PKG_LIBS="${PKG_LIBS} -fopenmp"
@@ -150,7 +151,7 @@ if test x"${SYSKERNEL}" = x"Darwin"; then
150151
can_use_openmp="no"
151152
fi
152153
fi
153-
fi
154+
fi
154155
else
155156
AC_MSG_RESULT([no])
156157
fi # if macOS

0 commit comments

Comments
 (0)