https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125324

--- Comment #5 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jerry DeLisle <[email protected]>:

https://gcc.gnu.org/g:ee7d0c7b4102b8ef0bcaa725c75e141248b774cb

commit r17-1234-gee7d0c7b4102b8ef0bcaa725c75e141248b774cb
Author: Jerry DeLisle <[email protected]>
Date:   Wed May 27 09:24:26 2026 -0700

    fortran: also link -lpthread when -fcoarray=shared is used [PR125324]

    When the driver auto-links -lcaf_shmem for -fcoarray=shared it must also
    link -lpthread because the shmem CAF runtime uses POSIX threads internally.

    Assisted by: Claude Sonnet 4.6

            PR fortran/125324

    gcc/fortran/ChangeLog:

            * gfortranspec.cc (lang_specific_driver): Also append -lpthread
            when need_caf_shmem is set.

    (cherry picked from commit 8e2b89e87d195409ba1690e2f732431dc4b7305e)

Reply via email to