This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v3] gold: Use autotools pthread macro


> The autotools library macro (AX_PTHREAD) is now used to detect if
> pthreads is present and multi-threaded linking in gold is automatically
> enabled if it is found. This enables multi-threaded gold on platforms
> where pthreads is enabled via other methods than just -lpthread (e.g.
> MinGW)

I made some additional adjustments in Makefile.am and
testsuite/Makefile.am to use PTHREAD_CFLAGS and PTHREAD_LIBS
appropriately. Here's what I committed...

-cary


2018-06-19  Joshua Watt  <jpewhacker@gmail.com>
            Cary Coutant  <ccoutant@gmail.com>

gold/
        * configure.ac: Replace manual thread configuration with AX_PTHREAD.
        Add --enable-threads=auto.
        * Makefile.am (THREADFLAGS, THREADLIBS): New defines.
        (AM_CFLAGS, AM_CXXFLAGS): Add $(THREADFLAGS.
        (THREADSLIB): Remove; change all references to THREADLIBS.
        * Makefile.in: Regenerate.
        * aclocal.m4: Regenerate.
        * config.in: Regenerate.
        * configure: Regenerate.
        * testsuite/Makefile.am (THREADSLIB): Replace with...
        (THREADFLAGS, THREADLIBS): ... these.
        (LDADD): Remove; add as individual defines for...
        (object_unittest, binary_unittest, leb128_unittest)
        (overflow_unittest): ... these tests.
        (tls_test, tls_pic_test, tls_pie_test, tls_pie_pic_test)
        (tls_shared_test, tls_shared_ie_test, tls_shared_gd_to_ie_test)
        (tls_shared_gnu2_gd_to_ie_test, tls_shared_gnu2_test_LDFLAGS)
        (tls_shared_nonpic_test_LDFLAGS): Add $(THREADFLAGS) and ($THREADLIBS).
        * testsuite/Makefile.in: Regenerate.

Attachment: configure-pthread.patch
Description: Binary data


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]