You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
macOS Sonoma 14.6.1, Linux debian testing kernel 6.9.10
Describe Bug
gfortran fails to link the OpenMP library at the final compilation stage, with all references to OpenMP primitives unresolved.
This problem was confirmed on mac OS X arm64 and Linux AMD 64.
program test_openmp
integer, external :: omp_get_num_threads
!$omp parallel
print '("Number of threads: ",i0)', omp_get_num_threads()
!$omp end parallel
end program test_openmp
Additional Information and Error Logs
It seems that the problem is in the use of result.fcldflags = "-fopenmp" on l.77.
Replacing it with result.ldflags = "-fopenmp" fixes the problem (the "shared" case was not tested).
The text was updated successfully, but these errors were encountered:
Xmake Version
2.9.5
Operating System Version and Architecture
macOS Sonoma 14.6.1, Linux debian testing kernel 6.9.10
Describe Bug
gfortran fails to link the OpenMP library at the final compilation stage, with all references to OpenMP primitives unresolved.
This problem was confirmed on mac OS X arm64 and Linux AMD 64.
Expected Behavior
The compilation should work
Project Configuration
xmake.lua
test_openmp.f90
Additional Information and Error Logs
It seems that the problem is in the use of
result.fcldflags = "-fopenmp"
on l.77.Replacing it with
result.ldflags = "-fopenmp"
fixes the problem (the "shared" case was not tested).The text was updated successfully, but these errors were encountered: