☠ Buildbot (Sourceware): binutils-gdb-autoregen - failed 'git diff ...' (failure) (master)
builder@sourceware.org
builder@sourceware.org
Thu Sep 25 04:42:09 GMT 2025
A new failure has been detected on builder binutils-gdb-autoregen while building binutils-gdb.
Full details are available at:
https://builder.sourceware.org/buildbot/#/builders/270/builds/7169
Build state: failed 'git diff ...' (failure)
Revision: 10deea6e2fc1b9ec5818b5fa1bc510c63ff5b2e2
Worker: bbo1-2
Build Reason: (unknown)
Blamelist: H.J. Lu <hjl.tools@gmail.com>
Steps:
- 0: worker_preparation ( success )
- 1: git checkout ( success )
Logs:
- stdio: https://builder.sourceware.org/buildbot/#/builders/270/builds/7169/steps/1/logs/stdio
- 2: autoregen.py ( success )
Logs:
- stdio: https://builder.sourceware.org/buildbot/#/builders/270/builds/7169/steps/2/logs/stdio
- 3: git diff ( failure )
Logs:
- stdio: https://builder.sourceware.org/buildbot/#/builders/270/builds/7169/steps/3/logs/stdio
-------------- next part --------------
hgit --version
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'--version']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
ogit version 2.47.3
hprogram finished with exit code 0
helapsedTime=0.011477
hprogram finished with exit code 2
hstat: No such file or directory: /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/.buildbot-patched
hprogram finished with exit code 0
hgit clean -f -f -d -x
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'clean', b'-f', b'-f', b'-d', b'-x']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
oRemoving autom4te.cache/
oRemoving bfd/autom4te.cache/
oRemoving bfd/config.in~
oRemoving binutils/autom4te.cache/
oRemoving binutils/config.in~
oRemoving etc/autom4te.cache/
oRemoving gas/autom4te.cache/
oRemoving gas/config.in~
oRemoving gdb/autom4te.cache/
oRemoving gdb/config.in~
oRemoving gdb/testsuite/autom4te.cache/
oRemoving gdbserver/autom4te.cache/
oRemoving gdbserver/config.in~
oRemoving gdbsupport/autom4te.cache/
oRemoving gdbsupport/config.in~
oRemoving gnulib/autom4te.cache/
oRemoving gnulib/config.in~
oRemoving gold/autom4te.cache/
oRemoving gold/config.in~
oRemoving gprof/autom4te.cache/
oRemoving gprof/gconfig.in~
oRemoving gprofng/autom4te.cache/
oRemoving gprofng/common/config.h.in~
oRemoving gprofng/common/lib-config.h.in~
oRemoving gprofng/libcollector/autom4te.cache/
oRemoving ld/autom4te.cache/
oRemoving ld/config.in~
oRemoving libbacktrace/autom4te.cache/
oRemoving libbacktrace/config.h.in~
oRemoving libctf/autom4te.cache/
oRemoving libctf/config.h.in~
oRemoving libdecnumber/autom4te.cache/
oRemoving libdecnumber/config.in~
oRemoving libiberty/$libiberty_topdir/
oRemoving libiberty/autom4te.cache/
oRemoving libiberty/config.in~
oRemoving libsframe/autom4te.cache/
oRemoving libsframe/config.h.in~
oRemoving opcodes/autom4te.cache/
oRemoving opcodes/config.in~
oRemoving sim/autom4te.cache/
oRemoving sim/config.h.in~
oRemoving zlib/autom4te.cache/
hprogram finished with exit code 0
helapsedTime=0.102396
hgit cat-file -e 10deea6e2fc1b9ec5818b5fa1bc510c63ff5b2e2
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'cat-file', b'-e', b'10deea6e2fc1b9ec5818b5fa1bc510c63ff5b2e2']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
hprogram finished with exit code 1
helapsedTime=0.011822
hgit fetch -f -t https://sourceware.org/git/binutils-gdb.git master --progress
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'fetch', b'-f', b'-t', b'https://sourceware.org/git/binutils-gdb.git', b'master', b'--progress']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
eremote: Enumerating objects: 161, done.
eremote: Counting objects: 0% (1/161)
eremote: Counting objects: 1% (2/161)
eremote: Counting objects: 2% (4/161)
eremote: Counting objects: 3% (5/161)
eremote: Counting objects: 4% (7/161)
eremote: Counting objects: 5% (9/161)
eremote: Counting objects: 6% (10/161)
eremote: Counting objects: 7% (12/161)
eremote: Counting objects: 8% (13/161)
eremote: Counting objects: 9% (15/161)
eremote: Counting objects: 10% (17/161)
eremote: Counting objects: 11% (18/161)
eremote: Counting objects: 12% (20/161)
eremote: Counting objects: 13% (21/161)
eremote: Counting objects: 14% (23/161)
eremote: Counting objects: 15% (25/161)
eremote: Counting objects: 16% (26/161)
eremote: Counting objects: 17% (28/161)
eremote: Counting objects: 18% (29/161)
eremote: Counting objects: 19% (31/161)
eremote: Counting objects: 20% (33/161)
eremote: Counting objects: 21% (34/161)
eremote: Counting objects: 22% (36/161)
eremote: Counting objects: 23% (38/161)
eremote: Counting objects: 24% (39/161)
eremote: Counting objects: 25% (41/161)
eremote: Counting objects: 26% (42/161)
eremote: Counting objects: 27% (44/161)
eremote: Counting objects: 28% (46/161)
eremote: Counting objects: 29% (47/161)
eremote: Counting objects: 30% (49/161)
eremote: Counting objects: 31% (50/161)
eremote: Counting objects: 32% (52/161)
eremote: Counting objects: 33% (54/161)
eremote: Counting objects: 34% (55/161)
eremote: Counting objects: 35% (57/161)
eremote: Counting objects: 36% (58/161)
eremote: Counting objects: 37% (60/161)
eremote: Counting objects: 38% (62/161)
eremote: Counting objects: 39% (63/161)
eremote: Counting objects: 40% (65/161)
eremote: Counting objects: 41% (67/161)
eremote: Counting objects: 42% (68/161)
eremote: Counting objects: 43% (70/161)
eremote: Counting objects: 44% (71/161)
eremote: Counting objects: 45% (73/161)
eremote: Counting objects: 46% (75/161)
eremote: Counting objects: 47% (76/161)
eremote: Counting objects: 48% (78/161)
eremote: Counting objects: 49% (79/161)
eremote: Counting objects: 50% (81/161)
eremote: Counting objects: 51% (83/161)
eremote: Counting objects: 52% (84/161)
eremote: Counting objects: 53% (86/161)
eremote: Counting objects: 54% (87/161)
eremote: Counting objects: 55% (89/161)
eremote: Counting objects: 56% (91/161)
eremote: Counting objects: 57% (92/161)
eremote: Counting objects: 58% (94/161)
eremote: Counting objects: 59% (95/161)
eremote: Counting objects: 60% (97/161)
eremote: Counting objects: 61% (99/161)
eremote: Counting objects: 62% (100/161)
eremote: Counting objects: 63% (102/161)
eremote: Counting objects: 64% (104/161)
eremote: Counting objects: 65% (105/161)
eremote: Counting objects: 66% (107/161)
eremote: Counting objects: 67% (108/161)
eremote: Counting objects: 68% (110/161)
eremote: Counting objects: 69% (112/161)
eremote: Counting objects: 70% (113/161)
eremote: Counting objects: 71% (115/161)
eremote: Counting objects: 72% (116/161)
eremote: Counting objects: 73% (118/161)
eremote: Counting objects: 74% (120/161)
eremote: Counting objects: 75% (121/161)
eremote: Counting objects: 76% (123/161)
eremote: Counting objects: 77% (124/161)
eremote: Counting objects: 78% (126/161)
eremote: Counting objects: 79% (128/161)
eremote: Counting objects: 80% (129/161)
eremote: Counting objects: 81% (131/161)
eremote: Counting objects: 82% (133/161)
eremote: Counting objects: 83% (134/161)
eremote: Counting objects: 84% (136/161)
eremote: Counting objects: 85% (137/161)
eremote: Counting objects: 86% (139/161)
eremote: Counting objects: 87% (141/161)
eremote: Counting objects: 88% (142/161)
eremote: Counting objects: 89% (144/161)
eremote: Counting objects: 90% (145/161)
eremote: Counting objects: 91% (147/161)
eremote: Counting objects: 92% (149/161)
eremote: Counting objects: 93% (150/161)
eremote: Counting objects: 94% (152/161)
eremote: Counting objects: 95% (153/161)
eremote: Counting objects: 96% (155/161)
eremote: Counting objects: 97% (157/161)
eremote: Counting objects: 98% (158/161)
eremote: Counting objects: 99% (160/161)
eremote: Counting objects: 100% (161/161)
eremote: Counting objects: 100% (161/161), done.
eremote: Compressing objects: 1% (1/90)
eremote: Compressing objects: 2% (2/90)
eremote: Compressing objects: 3% (3/90)
eremote: Compressing objects: 4% (4/90)
eremote: Compressing objects: 5% (5/90)
eremote: Compressing objects: 6% (6/90)
eremote: Compressing objects: 7% (7/90)
eremote: Compressing objects: 8% (8/90)
eremote: Compressing objects: 10% (9/90)
eremote: Compressing objects: 11% (10/90)
eremote: Compressing objects: 12% (11/90)
eremote: Compressing objects: 13% (12/90)
eremote: Compressing objects: 14% (13/90)
eremote: Compressing objects: 15% (14/90)
eremote: Compressing objects: 16% (15/90)
eremote: Compressing objects: 17% (16/90)
eremote: Compressing objects: 18% (17/90)
eremote: Compressing objects: 20% (18/90)
eremote: Compressing objects: 21% (19/90)
eremote: Compressing objects: 22% (20/90)
eremote: Compressing objects: 23% (21/90)
eremote: Compressing objects: 24% (22/90)
eremote: Compressing objects: 25% (23/90)
eremote: Compressing objects: 26% (24/90)
eremote: Compressing objects: 27% (25/90)
eremote: Compressing objects: 28% (26/90)
eremote: Compressing objects: 30% (27/90)
eremote: Compressing objects: 31% (28/90)
eremote: Compressing objects: 32% (29/90)
eremote: Compressing objects: 33% (30/90)
eremote: Compressing objects: 34% (31/90)
eremote: Compressing objects: 35% (32/90)
eremote: Compressing objects: 36% (33/90)
eremote: Compressing objects: 37% (34/90)
eremote: Compressing objects: 38% (35/90)
eremote: Compressing objects: 40% (36/90)
eremote: Compressing objects: 41% (37/90)
eremote: Compressing objects: 42% (38/90)
eremote: Compressing objects: 43% (39/90)
eremote: Compressing objects: 44% (40/90)
eremote: Compressing objects: 45% (41/90)
eremote: Compressing objects: 46% (42/90)
eremote: Compressing objects: 47% (43/90)
eremote: Compressing objects: 48% (44/90)
eremote: Compressing objects: 50% (45/90)
eremote: Compressing objects: 51% (46/90)
eremote: Compressing objects: 52% (47/90)
eremote: Compressing objects: 53% (48/90)
eremote: Compressing objects: 54% (49/90)
eremote: Compressing objects: 55% (50/90)
eremote: Compressing objects: 56% (51/90)
eremote: Compressing objects: 57% (52/90)
eremote: Compressing objects: 58% (53/90)
eremote: Compressing objects: 60% (54/90)
eremote: Compressing objects: 61% (55/90)
eremote: Compressing objects: 62% (56/90)
eremote: Compressing objects: 63% (57/90)
eremote: Compressing objects: 64% (58/90)
eremote: Compressing objects: 65% (59/90)
eremote: Compressing objects: 66% (60/90)
eremote: Compressing objects: 67% (61/90)
eremote: Compressing objects: 68% (62/90)
eremote: Compressing objects: 70% (63/90)
eremote: Compressing objects: 71% (64/90)
eremote: Compressing objects: 72% (65/90)
eremote: Compressing objects: 73% (66/90)
eremote: Compressing objects: 74% (67/90)
eremote: Compressing objects: 75% (68/90)
eremote: Compressing objects: 76% (69/90)
eremote: Compressing objects: 77% (70/90)
eremote: Compressing objects: 78% (71/90)
eremote: Compressing objects: 80% (72/90)
eremote: Compressing objects: 81% (73/90)
eremote: Compressing objects: 82% (74/90)
eremote: Compressing objects: 83% (75/90)
eremote: Compressing objects: 84% (76/90)
eremote: Compressing objects: 85% (77/90)
eremote: Compressing objects: 86% (78/90)
eremote: Compressing objects: 87% (79/90)
eremote: Compressing objects: 88% (80/90)
eremote: Compressing objects: 90% (81/90)
eremote: Compressing objects: 91% (82/90)
eremote: Compressing objects: 92% (83/90)
eremote: Compressing objects: 93% (84/90)
eremote: Compressing objects: 94% (85/90)
eremote: Compressing objects: 95% (86/90)
eremote: Compressing objects: 96% (87/90)
eremote: Compressing objects: 97% (88/90)
eremote: Compressing objects: 98% (89/90)
eremote: Compressing objects: 100% (90/90)
eremote: Compressing objects: 100% (90/90), done.
eremote: Total 90 (delta 81), reused 0 (delta 0), pack-reused 0
eFrom https://sourceware.org/git/binutils-gdb
e * branch master -> FETCH_HEAD
hprogram finished with exit code 0
helapsedTime=3.374462
hgit checkout -f 10deea6e2fc1b9ec5818b5fa1bc510c63ff5b2e2
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'checkout', b'-f', b'10deea6e2fc1b9ec5818b5fa1bc510c63ff5b2e2']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
eNote: switching to '10deea6e2fc1b9ec5818b5fa1bc510c63ff5b2e2'.
e
eYou are in 'detached HEAD' state. You can look around, make experimental
echanges and commit them, and you can discard any commits you make in this
estate without impacting any branches by switching back to a branch.
e
eIf you want to create a new branch to retain commits you create, you may
edo so (now or later) by using -c with the switch command. Example:
e
e git switch -c <new-branch-name>
e
eOr undo this operation with:
e
e git switch -
e
eTurn off this advice by setting config variable advice.detachedHead to false
e
eHEAD is now at 10deea6e2fc Binutils/GCC: Add clang LTO support to AR, NM and RANLIB
hprogram finished with exit code 0
helapsedTime=0.142284
hgit checkout -B master
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'checkout', b'-B', b'master']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
eSwitched to and reset branch 'master'
oYour branch is ahead of 'origin/master' by 6936 commits.
o (use "git push" to publish your local commits)
hprogram finished with exit code 0
helapsedTime=0.253021
hgit rev-parse HEAD
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'rev-parse', b'HEAD']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
o10deea6e2fc1b9ec5818b5fa1bc510c63ff5b2e2
hprogram finished with exit code 0
helapsedTime=0.010772
hgit describe --always --tags HEAD
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'describe', b'--always', b'--tags', b'HEAD']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
ogdb-17-branchpoint-262-g10deea6e2fc
hprogram finished with exit code 0
helapsedTime=0.999249
-------------- next part --------------
hautoregen.py
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: b'autoregen.py'
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
o+ autoconf-2.69 --version
oautoconf (GNU Autoconf) 2.69
oCopyright (C) 2012 Free Software Foundation, Inc.
oLicense GPLv3+/Autoconf: GNU GPL version 3 or later
o<http://gnu.org/licenses/gpl.html>, <http://gnu.org/licenses/exceptions.html>
oThis is free software: you are free to change and redistribute it.
oThere is NO WARRANTY, to the extent permitted by law.
o
oWritten by David J. MacKenzie and Akim Demaille.
o+ automake-1.15.1 --version
oautomake (GNU automake) 1.15.1
oCopyright (C) 2017 Free Software Foundation, Inc.
oLicense GPLv2+: GNU GPL version 2 or later <http://gnu.org/licenses/gpl-2.0.html>
oThis is free software: you are free to change and redistribute it.
oThere is NO WARRANTY, to the extent permitted by law.
o
oWritten by Tom Tromey <tromey@redhat.com>
o and Alexandre Duret-Lutz <adl@gnu.org>.
o+ aclocal-1.15.1 --version
oaclocal (GNU automake) 1.15.1
oCopyright (C) 2017 Free Software Foundation, Inc.
oLicense GPLv2+: GNU GPL version 2 or later <http://gnu.org/licenses/gpl-2.0.html>
oThis is free software: you are free to change and redistribute it.
oThere is NO WARRANTY, to the extent permitted by law.
o
oWritten by Tom Tromey <tromey@redhat.com>
o and Alexandre Duret-Lutz <adl@gnu.org>.
o+ autoheader-2.69 --version
oautoheader (GNU Autoconf) 2.69
oCopyright (C) 2012 Free Software Foundation, Inc.
oLicense GPLv3+/Autoconf: GNU GPL version 3 or later
o<http://gnu.org/licenses/gpl.html>, <http://gnu.org/licenses/exceptions.html>
oThis is free software: you are free to change and redistribute it.
oThere is NO WARRANTY, to the extent permitted by law.
o
oWritten by Roland McGrath and Akim Demaille.
oExtra environment: {'WANT_AUTOCONF': '2.69', 'WANT_AUTOMAKE': '1.15.1', 'AUTOCONF': 'autoconf-2.69', 'ACLOCAL': 'aclocal-1.15.1', 'AUTOMAKE': 'automake-1.15.1', 'AUTOGEN': 'autogen'}
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
o+ autogen Makefile.def
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
o+ autoconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/bfd
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/binutils
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/etc
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gas
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gdb
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gdb/testsuite
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gdbserver
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gdbsupport
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gnulib
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gold
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gprof
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gprofng
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/gprofng/libcollector
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/ld
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/libbacktrace
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/libctf
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/libdecnumber
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/libiberty
o+ autoreconf-2.69 -f
econfigure.ac:814: warning: GCC_AC_FUNC_MMAP is m4_require'd but not m4_defun'd
eacinclude.m4:21: libiberty_AC_FUNC_STRNCMP is expanded from...
econfigure.ac:814: the top level
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/libsframe
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/opcodes
o+ autoreconf-2.69 -f
eautoreconf-2.69: configure.ac: AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_VERSION
oSkipping directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/readline
oSkipping directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/readline/readline
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/sim
o+ autoreconf-2.69 -f
oEntering directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/zlib
o+ autoreconf-2.69 -f
oSkipping directory /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build/zlib/contrib/minizip
hprogram finished with exit code 0
helapsedTime=185.946347
-------------- next part --------------
hgit diff --exit-code
h in dir /home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build (timeout 1200 secs)
h watching logfiles {}
h argv: [b'git', b'diff', b'--exit-code']
h environment:
h BUILDMASTER=builder.sourceware.org
h BUILDMASTER_PORT=9989
h CCACHE_DIR=/home/builder/shared/autotools/ccache
h CCACHE_LIBDIR=/usr/lib/ccache
h HOME=/home/builder
h HOSTNAME=ebb7ac2d9d6f
h IMAGE_NAME=autotools
h LC_CTYPE=C.UTF-8
h PATH=/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
h PWD=/home/builder/shared/bbo1-2/worker/binutils-gdb-autoregen/build
h WORKERNAME=bbo1-2
h using PTY: False
odiff --git a/bfd/Makefile.in b/bfd/Makefile.in
oindex 4c259682fd0..6d1944c2664 100644
o--- a/bfd/Makefile.in
o+++ b/bfd/Makefile.in
o@@ -113,7 +113,9 @@ target_triplet = @target@
o subdir = .
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../config/acx.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/gettext-sister.m4 \
o $(top_srcdir)/../config/gettext.m4 \
o $(top_srcdir)/../config/iconv.m4 \
o@@ -372,6 +374,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBICONV = @LTLIBICONV@
o LTLIBINTL = @LTLIBINTL@
odiff --git a/bfd/aclocal.m4 b/bfd/aclocal.m4
oindex 4d1b7baebb2..4975bdd44d2 100644
o--- a/bfd/aclocal.m4
o+++ b/bfd/aclocal.m4
o@@ -1168,7 +1168,9 @@ AC_SUBST([am__untar])
o ]) # _AM_PROG_TAR
o
o m4_include([../config/acx.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/depstand.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/gettext-sister.m4])
o m4_include([../config/gettext.m4])
o m4_include([../config/iconv.m4])
odiff --git a/bfd/configure b/bfd/configure
oindex ee588238500..d07f9e926e4 100755
o--- a/bfd/configure
o+++ b/bfd/configure
o@@ -710,6 +710,7 @@ OTOOL
o LIPO
o NMEDIT
o DSYMUTIL
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -6201,8 +6202,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -6213,7 +6472,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -6308,17 +6679,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -6525,9 +6894,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -11153,7 +11528,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11156 "configure"
o+#line 11531 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -11259,7 +11634,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11262 "configure"
o+#line 11637 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/binutils/Makefile.in b/binutils/Makefile.in
oindex 549b5a361c8..a374e805576 100644
o--- a/binutils/Makefile.in
o+++ b/binutils/Makefile.in
o@@ -139,8 +139,10 @@ subdir = .
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../bfd/acinclude.m4 \
o $(top_srcdir)/../bfd/warning.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o $(top_srcdir)/../config/enable.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/gettext-sister.m4 \
o $(top_srcdir)/../config/gettext.m4 \
o $(top_srcdir)/../config/iconv.m4 \
o@@ -533,6 +535,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBICONV = @LTLIBICONV@
o LTLIBINTL = @LTLIBINTL@
odiff --git a/binutils/aclocal.m4 b/binutils/aclocal.m4
oindex eb1433a68bd..ebefc41ea85 100644
o--- a/binutils/aclocal.m4
o+++ b/binutils/aclocal.m4
o@@ -1187,8 +1187,10 @@ AC_SUBST([am__untar])
o
o m4_include([../bfd/acinclude.m4])
o m4_include([../bfd/warning.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/depstand.m4])
o m4_include([../config/enable.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/gettext-sister.m4])
o m4_include([../config/gettext.m4])
o m4_include([../config/iconv.m4])
odiff --git a/binutils/configure b/binutils/configure
oindex 6f54be99066..71c52a399aa 100755
o--- a/binutils/configure
o+++ b/binutils/configure
o@@ -706,6 +706,7 @@ NMEDIT
o DSYMUTIL
o RANLIB
o AR
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -6098,8 +6099,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -6110,7 +6369,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -6205,17 +6576,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -6422,9 +6791,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -11081,7 +11456,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11084 "configure"
o+#line 11459 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -11187,7 +11562,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11190 "configure"
o+#line 11565 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/gas/Makefile.in b/gas/Makefile.in
oindex 1f24d4a5bbc..76e633d5298 100644
o--- a/gas/Makefile.in
o+++ b/gas/Makefile.in
o@@ -132,7 +132,9 @@ subdir = .
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../bfd/acinclude.m4 \
o $(top_srcdir)/../bfd/warning.m4 $(top_srcdir)/../config/acx.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/gettext-sister.m4 \
o $(top_srcdir)/../config/gettext.m4 \
o $(top_srcdir)/../config/iconv.m4 \
o@@ -419,6 +421,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBICONV = @LTLIBICONV@
o LTLIBINTL = @LTLIBINTL@
odiff --git a/gas/aclocal.m4 b/gas/aclocal.m4
oindex 5f8b996abc0..db15767f946 100644
o--- a/gas/aclocal.m4
o+++ b/gas/aclocal.m4
o@@ -1188,7 +1188,9 @@ AC_SUBST([am__untar])
o m4_include([../bfd/acinclude.m4])
o m4_include([../bfd/warning.m4])
o m4_include([../config/acx.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/depstand.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/gettext-sister.m4])
o m4_include([../config/gettext.m4])
o m4_include([../config/iconv.m4])
odiff --git a/gas/configure b/gas/configure
oindex c6d27fb29d0..f2cdd77b1fb 100755
o--- a/gas/configure
o+++ b/gas/configure
o@@ -694,6 +694,7 @@ NMEDIT
o DSYMUTIL
o RANLIB
o AR
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -5796,8 +5797,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -5808,7 +6067,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -5903,17 +6274,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -6120,9 +6489,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -10779,7 +11154,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 10782 "configure"
o+#line 11157 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -10885,7 +11260,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 10888 "configure"
o+#line 11263 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/gdb/aclocal.m4 b/gdb/aclocal.m4
oindex 99714239668..cae09708e01 100644
o--- a/gdb/aclocal.m4
o+++ b/gdb/aclocal.m4
o@@ -202,9 +202,11 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
o m4_include([../config/acx.m4])
o m4_include([../config/ax_pthread.m4])
o m4_include([../config/bfd64.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/debuginfod.m4])
o m4_include([../config/depstand.m4])
o m4_include([../config/enable.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/gettext-sister.m4])
o m4_include([../config/gettext.m4])
o m4_include([../config/intlmacosx.m4])
odiff --git a/gdb/configure b/gdb/configure
oindex d0bdba6eb36..db63481b1c6 100755
o--- a/gdb/configure
o+++ b/gdb/configure
o@@ -821,6 +821,7 @@ DSYMUTIL
o AWK
o RANLIB
o AR
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -6487,8 +6488,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -6499,7 +6758,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -6594,17 +6965,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -6811,9 +7180,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -11513,7 +11888,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11516 "configure"
o+#line 11891 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -11619,7 +11994,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11622 "configure"
o+#line 11997 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/gprof/Makefile.in b/gprof/Makefile.in
oindex 719e1810bcd..c32a9457f0b 100644
o--- a/gprof/Makefile.in
o+++ b/gprof/Makefile.in
o@@ -112,7 +112,9 @@ bin_PROGRAMS = gprof$(EXEEXT)
o subdir = .
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../bfd/warning.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/gettext-sister.m4 \
o $(top_srcdir)/../config/gettext.m4 \
o $(top_srcdir)/../config/iconv.m4 \
o@@ -357,6 +359,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBICONV = @LTLIBICONV@
o LTLIBINTL = @LTLIBINTL@
odiff --git a/gprof/aclocal.m4 b/gprof/aclocal.m4
oindex 36ccc3e81ed..b5cb63396f3 100644
o--- a/gprof/aclocal.m4
o+++ b/gprof/aclocal.m4
o@@ -1168,7 +1168,9 @@ AC_SUBST([am__untar])
o ]) # _AM_PROG_TAR
o
o m4_include([../bfd/warning.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/depstand.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/gettext-sister.m4])
o m4_include([../config/gettext.m4])
o m4_include([../config/iconv.m4])
odiff --git a/gprof/configure b/gprof/configure
oindex 22d4cc535dc..1c70f82bd14 100755
o--- a/gprof/configure
o+++ b/gprof/configure
o@@ -673,6 +673,7 @@ NMEDIT
o DSYMUTIL
o RANLIB
o AR
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -5672,8 +5673,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -5684,7 +5943,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -5779,17 +6150,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -5996,9 +6365,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -10655,7 +11030,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 10658 "configure"
o+#line 11033 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -10761,7 +11136,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 10764 "configure"
o+#line 11139 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/gprof/testsuite/Makefile.in b/gprof/testsuite/Makefile.in
oindex ab8a2cbb16e..77cecd153b1 100644
o--- a/gprof/testsuite/Makefile.in
o+++ b/gprof/testsuite/Makefile.in
o@@ -96,7 +96,9 @@ target_triplet = @target@
o subdir = testsuite
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../bfd/warning.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/gettext-sister.m4 \
o $(top_srcdir)/../config/gettext.m4 \
o $(top_srcdir)/../config/iconv.m4 \
o@@ -399,6 +401,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBICONV = @LTLIBICONV@
o LTLIBINTL = @LTLIBINTL@
odiff --git a/gprofng/configure b/gprofng/configure
oindex 9ad1def7cba..a1499b8e45c 100755
o--- a/gprofng/configure
o+++ b/gprofng/configure
o@@ -7295,19 +7295,15 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o-plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o-for plugin in $plugin_names; do
o- plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o- if test x$plugin_so = x$plugin; then
o- plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
o- fi
o- if test x$plugin_so != x$plugin; then
o- plugin_option="--plugin $plugin_so"
o- break
o- fi
o-done
o
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+CLANG_PLUGIN_FILE(plugin_file)
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ GCC_PLUGIN_OPTION(plugin_option)
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -7402,17 +7398,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -7619,9 +7613,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
odiff --git a/gprofng/libcollector/Makefile.in b/gprofng/libcollector/Makefile.in
oindex 4448745f17e..b6906f67391 100644
o--- a/gprofng/libcollector/Makefile.in
o+++ b/gprofng/libcollector/Makefile.in
o@@ -109,7 +109,9 @@ host_triplet = @host@
o target_triplet = @target@
o subdir = .
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o-am__aclocal_m4_deps = $(top_srcdir)/../../config/depstand.m4 \
o+am__aclocal_m4_deps = $(top_srcdir)/../../config/clang-plugin.m4 \
o+ $(top_srcdir)/../../config/depstand.m4 \
o+ $(top_srcdir)/../../config/gcc-plugin.m4 \
o $(top_srcdir)/../../config/lead-dot.m4 \
o $(top_srcdir)/../../config/override.m4 \
o $(top_srcdir)/../../config/warnings.m4 \
o@@ -337,6 +339,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBOBJS = @LTLIBOBJS@
o MAINT = @MAINT@
odiff --git a/gprofng/libcollector/aclocal.m4 b/gprofng/libcollector/aclocal.m4
oindex 2d13dba8c20..b269df7b75c 100644
o--- a/gprofng/libcollector/aclocal.m4
o+++ b/gprofng/libcollector/aclocal.m4
o@@ -1227,7 +1227,9 @@ AC_SUBST([am__tar])
o AC_SUBST([am__untar])
o ]) # _AM_PROG_TAR
o
o+m4_include([../../config/clang-plugin.m4])
o m4_include([../../config/depstand.m4])
o+m4_include([../../config/gcc-plugin.m4])
o m4_include([../../config/lead-dot.m4])
o m4_include([../../config/override.m4])
o m4_include([../../config/warnings.m4])
odiff --git a/gprofng/libcollector/configure b/gprofng/libcollector/configure
oindex ecd15427054..6e2429a815e 100755
o--- a/gprofng/libcollector/configure
o+++ b/gprofng/libcollector/configure
o@@ -640,6 +640,7 @@ OTOOL
o LIPO
o NMEDIT
o DSYMUTIL
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -7110,8 +7111,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -7122,7 +7381,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -7217,17 +7588,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -7434,9 +7803,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -12094,7 +12469,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 12097 "configure"
o+#line 12472 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -12200,7 +12575,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 12203 "configure"
o+#line 12578 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/ld/Makefile.in b/ld/Makefile.in
oindex 3e8f2872a47..0acf5f473e2 100644
o--- a/ld/Makefile.in
o+++ b/ld/Makefile.in
o@@ -113,8 +113,10 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../bfd/acinclude.m4 \
o $(top_srcdir)/../bfd/warning.m4 $(top_srcdir)/../config/acx.m4 \
o $(top_srcdir)/../config/bfd64.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o $(top_srcdir)/../config/enable.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/gettext-sister.m4 \
o $(top_srcdir)/../config/gettext.m4 \
o $(top_srcdir)/../config/iconv.m4 \
o@@ -439,6 +441,7 @@ LIBTOOL = @LIBTOOL@
o # when the linker is configured via the --with-lib-path configure switch.
o LIB_PATH = @LIB_PATH@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBICONV = @LTLIBICONV@
o LTLIBINTL = @LTLIBINTL@
odiff --git a/ld/aclocal.m4 b/ld/aclocal.m4
oindex 01c2dc2694d..77cc09814f1 100644
o--- a/ld/aclocal.m4
o+++ b/ld/aclocal.m4
o@@ -1189,8 +1189,10 @@ m4_include([../bfd/acinclude.m4])
o m4_include([../bfd/warning.m4])
o m4_include([../config/acx.m4])
o m4_include([../config/bfd64.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/depstand.m4])
o m4_include([../config/enable.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/gettext-sister.m4])
o m4_include([../config/gettext.m4])
o m4_include([../config/iconv.m4])
odiff --git a/ld/configure b/ld/configure
oindex fe23178cd29..11c17f21ee4 100755
o--- a/ld/configure
o+++ b/ld/configure
o@@ -705,6 +705,7 @@ NMEDIT
o DSYMUTIL
o RANLIB
o AR
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -6535,8 +6536,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -6547,7 +6806,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -6642,17 +7013,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -6859,9 +7228,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -11519,7 +11894,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11522 "configure"
o+#line 11897 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -11625,7 +12000,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11628 "configure"
o+#line 12003 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/libctf/Makefile.in b/libctf/Makefile.in
oindex 5d9587766dc..7c309b1fc04 100644
o--- a/libctf/Makefile.in
o+++ b/libctf/Makefile.in
o@@ -134,8 +134,10 @@ subdir = .
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../bfd/acinclude.m4 \
o $(top_srcdir)/../config/acx.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o $(top_srcdir)/../config/enable.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/gettext-sister.m4 \
o $(top_srcdir)/../config/gettext.m4 \
o $(top_srcdir)/../config/iconv.m4 \
o@@ -475,6 +477,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBICONV = @LTLIBICONV@
o LTLIBINTL = @LTLIBINTL@
odiff --git a/libctf/aclocal.m4 b/libctf/aclocal.m4
oindex fc2b7d7ddcc..de7db772d18 100644
o--- a/libctf/aclocal.m4
o+++ b/libctf/aclocal.m4
o@@ -1229,8 +1229,10 @@ AC_SUBST([am__untar])
o
o m4_include([../bfd/acinclude.m4])
o m4_include([../config/acx.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/depstand.m4])
o m4_include([../config/enable.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/gettext-sister.m4])
o m4_include([../config/gettext.m4])
o m4_include([../config/iconv.m4])
odiff --git a/libctf/configure b/libctf/configure
oindex 89c99c2ddbf..becb131103a 100755
o--- a/libctf/configure
o+++ b/libctf/configure
o@@ -669,6 +669,7 @@ OTOOL
o LIPO
o NMEDIT
o DSYMUTIL
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -8643,8 +8644,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -8655,7 +8914,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -8750,17 +9121,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -8967,9 +9336,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -13596,7 +13971,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 13599 "configure"
o+#line 13974 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -13702,7 +14077,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 13705 "configure"
o+#line 14080 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/libsframe/Makefile.in b/libsframe/Makefile.in
oindex e0f09acedc1..c3135064754 100644
o--- a/libsframe/Makefile.in
o+++ b/libsframe/Makefile.in
o@@ -124,8 +124,10 @@ subdir = .
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../bfd/acinclude.m4 \
o $(top_srcdir)/../config/acx.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/dejagnu.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/jobserver.m4 \
o $(top_srcdir)/../config/lead-dot.m4 \
o $(top_srcdir)/../config/mmap.m4 \
o@@ -419,6 +421,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBOBJS = @LTLIBOBJS@
o MAINT = @MAINT@
odiff --git a/libsframe/aclocal.m4 b/libsframe/aclocal.m4
oindex 8804d9fb42b..c47bb616185 100644
o--- a/libsframe/aclocal.m4
o+++ b/libsframe/aclocal.m4
o@@ -1229,8 +1229,10 @@ AC_SUBST([am__untar])
o
o m4_include([../bfd/acinclude.m4])
o m4_include([../config/acx.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/dejagnu.m4])
o m4_include([../config/depstand.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/jobserver.m4])
o m4_include([../config/lead-dot.m4])
o m4_include([../config/mmap.m4])
odiff --git a/libsframe/configure b/libsframe/configure
oindex 4727eff533a..715ce58f700 100755
o--- a/libsframe/configure
o+++ b/libsframe/configure
o@@ -658,6 +658,7 @@ OTOOL
o LIPO
o NMEDIT
o DSYMUTIL
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -6610,8 +6611,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -6622,7 +6881,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -6717,17 +7088,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -6934,9 +7303,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -11563,7 +11938,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11566 "configure"
o+#line 11941 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -11669,7 +12044,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11672 "configure"
o+#line 12047 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/opcodes/Makefile.in b/opcodes/Makefile.in
oindex 662ee5deb9d..ed61dfcf435 100644
o--- a/opcodes/Makefile.in
o+++ b/opcodes/Makefile.in
o@@ -115,7 +115,9 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../bfd/acinclude.m4 \
o $(top_srcdir)/../bfd/warning.m4 $(top_srcdir)/../config/acx.m4 \
o $(top_srcdir)/../config/bfd64.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/gettext-sister.m4 \
o $(top_srcdir)/../config/gettext.m4 \
o $(top_srcdir)/../config/iconv.m4 \
o@@ -330,6 +332,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBICONV = @LTLIBICONV@
o LTLIBINTL = @LTLIBINTL@
odiff --git a/opcodes/aclocal.m4 b/opcodes/aclocal.m4
oindex dc5967a169c..e153440f7ee 100644
o--- a/opcodes/aclocal.m4
o+++ b/opcodes/aclocal.m4
o@@ -1171,7 +1171,9 @@ m4_include([../bfd/acinclude.m4])
o m4_include([../bfd/warning.m4])
o m4_include([../config/acx.m4])
o m4_include([../config/bfd64.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/depstand.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/gettext-sister.m4])
o m4_include([../config/gettext.m4])
o m4_include([../config/iconv.m4])
odiff --git a/opcodes/configure b/opcodes/configure
oindex 7dc7b49ca2b..df9f63d1031 100755
o--- a/opcodes/configure
o+++ b/opcodes/configure
o@@ -686,6 +686,7 @@ OTOOL
o LIPO
o NMEDIT
o DSYMUTIL
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -5950,8 +5951,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -5962,7 +6221,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -6057,17 +6428,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -6274,9 +6643,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -10903,7 +11278,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 10906 "configure"
o+#line 11281 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -11009,7 +11384,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 11012 "configure"
o+#line 11387 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
odiff --git a/sim/Makefile.in b/sim/Makefile.in
oindex f99f1551296..7403e908cec 100644
o--- a/sim/Makefile.in
o+++ b/sim/Makefile.in
o@@ -328,7 +328,9 @@ TESTS = testsuite/common/bits32m0$(EXEEXT) \
o subdir = .
o ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
o am__aclocal_m4_deps = $(top_srcdir)/../config/acx.m4 \
o+ $(top_srcdir)/../config/clang-plugin.m4 \
o $(top_srcdir)/../config/depstand.m4 \
o+ $(top_srcdir)/../config/gcc-plugin.m4 \
o $(top_srcdir)/../config/lead-dot.m4 \
o $(top_srcdir)/../config/override.m4 \
o $(top_srcdir)/../config/pkg.m4 $(top_srcdir)/../libtool.m4 \
o@@ -1686,6 +1688,7 @@ LIBOBJS = @LIBOBJS@
o LIBS = @LIBS@
o LIBTOOL = @LIBTOOL@
o LIPO = @LIPO@
o+LLVM_CONFIG = @LLVM_CONFIG@
o LN_S = @LN_S@
o LTLIBOBJS = @LTLIBOBJS@
o MAINT = @MAINT@
odiff --git a/sim/aclocal.m4 b/sim/aclocal.m4
oindex d7db9e46b58..e6e62f7dab9 100644
o--- a/sim/aclocal.m4
o+++ b/sim/aclocal.m4
o@@ -1168,7 +1168,9 @@ AC_SUBST([am__untar])
o ]) # _AM_PROG_TAR
o
o m4_include([../config/acx.m4])
o+m4_include([../config/clang-plugin.m4])
o m4_include([../config/depstand.m4])
o+m4_include([../config/gcc-plugin.m4])
o m4_include([../config/lead-dot.m4])
o m4_include([../config/override.m4])
o m4_include([../config/pkg.m4])
odiff --git a/sim/configure b/sim/configure
oindex db0eaa662bc..b6c6d658b7d 100755
o--- a/sim/configure
o+++ b/sim/configure
o@@ -897,6 +897,7 @@ NMEDIT
o DSYMUTIL
o AWK
o STRIP
o+LLVM_CONFIG
o OBJDUMP
o LN_S
o NM
o@@ -6864,8 +6865,266 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
o
o
o
o-plugin_option=
o+
o+# Try CLANG_PLUGIN_FILE first since GCC_PLUGIN_OPTION may return the
o+# wrong plugin_option with clang.
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5
o+$as_echo_n "checking for clang... " >&6; }
o+if ${clang_cv_is_clang+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+
o+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
o+/* end confdefs.h. */
o+
o+#ifdef __clang__
o+ yes
o+#endif
o+
o+_ACEOF
o+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
o+ $EGREP "yes" >/dev/null 2>&1; then :
o+ clang_cv_is_clang=yes
o+else
o+ clang_cv_is_clang=no
o+fi
o+rm -f conftest*
o+
o+fi
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $clang_cv_is_clang" >&5
o+$as_echo "$clang_cv_is_clang" >&6; }
o+ plugin_file=
o+ if test $clang_cv_is_clang = yes; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang plugin file" >&5
o+$as_echo_n "checking for clang plugin file... " >&6; }
o+ plugin_names="LLVMgold.so"
o+ for plugin in $plugin_names; do
o+ plugin_file=`${CC} ${CFLAGS} --print-file-name $plugin`
o+ if test x$plugin_file = x$plugin; then
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}llvm-config", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$LLVM_CONFIG"; then
o+ ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_LLVM_CONFIG="${ac_tool_prefix}llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
o+if test -n "$LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
o+$as_echo "$LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_LLVM_CONFIG"; then
o+ ac_ct_LLVM_CONFIG=$LLVM_CONFIG
o+ # Extract the first word of "llvm-config", so it can be a program name with args.
o+set dummy llvm-config; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_LLVM_CONFIG+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_LLVM_CONFIG"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="$ac_ct_LLVM_CONFIG" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_LLVM_CONFIG="llvm-config"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_LLVM_CONFIG=$ac_cv_prog_ac_ct_LLVM_CONFIG
o+if test -n "$ac_ct_LLVM_CONFIG"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LLVM_CONFIG" >&5
o+$as_echo "$ac_ct_LLVM_CONFIG" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_LLVM_CONFIG" = x; then
o+ LLVM_CONFIG=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ LLVM_CONFIG=$ac_ct_LLVM_CONFIG
o+ fi
o+else
o+ LLVM_CONFIG="$ac_cv_prog_LLVM_CONFIG"
o+fi
o+
o+ if test "$?" != 0; then
o+ as_fn_error $? "Required tool 'llvm-config' not found on PATH." "$LINENO" 5
o+ fi
o+ clang_lib_dir=`$LLVM_CONFIG --libdir`
o+ if test -f $clang_lib_dir/$plugin; then
o+ plugin_file=$clang_lib_dir/$plugin
o+ fi
o+ if test x$plugin_file != x$plugin; then
o+ break;
o+ fi
o+ fi
o+ done
o+ if test -z $plugin_file; then
o+ as_fn_error $? "Couldn't find clang plugin file for $CC." "$LINENO" 5
o+ fi
o+ if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+ if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+ fi
o+ plugin_option="--plugin $plugin_file"
o+ touch conftest.c
o+ ${AR} $plugin_option rc conftest.a conftest.c
o+ if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_file=
o+ fi
o+ rm -f conftest.*
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_file" >&5
o+$as_echo "$plugin_file" >&6; }
o+ fi
o+ plugin_file="$plugin_file"
o+
o+if test -n "$plugin_file"; then
o+ plugin_option="--plugin $plugin_file"
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
o+$as_echo_n "checking for -plugin option... " >&6; }
o+
o plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
o+plugin_option=
o for plugin in $plugin_names; do
o plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
o if test x$plugin_so = x$plugin; then
o@@ -6876,7 +7135,119 @@ for plugin in $plugin_names; do
o break
o fi
o done
o+if test -n "$ac_tool_prefix"; then
o+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o+set dummy ${ac_tool_prefix}ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$AR"; then
o+ ac_cv_prog_AR="$AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_AR="${ac_tool_prefix}ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o
o+fi
o+fi
o+AR=$ac_cv_prog_AR
o+if test -n "$AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
o+$as_echo "$AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+
o+fi
o+if test -z "$ac_cv_prog_AR"; then
o+ ac_ct_AR=$AR
o+ # Extract the first word of "ar", so it can be a program name with args.
o+set dummy ar; ac_word=$2
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
o+$as_echo_n "checking for $ac_word... " >&6; }
o+if ${ac_cv_prog_ac_ct_AR+:} false; then :
o+ $as_echo_n "(cached) " >&6
o+else
o+ if test -n "$ac_ct_AR"; then
o+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
o+else
o+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
o+for as_dir in $PATH
o+do
o+ IFS=$as_save_IFS
o+ test -z "$as_dir" && as_dir=.
o+ for ac_exec_ext in '' $ac_executable_extensions; do
o+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
o+ ac_cv_prog_ac_ct_AR="ar"
o+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
o+ break 2
o+ fi
o+done
o+ done
o+IFS=$as_save_IFS
o+
o+fi
o+fi
o+ac_ct_AR=$ac_cv_prog_ac_ct_AR
o+if test -n "$ac_ct_AR"; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
o+$as_echo "$ac_ct_AR" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+ if test "x$ac_ct_AR" = x; then
o+ AR=""
o+ else
o+ case $cross_compiling:$ac_tool_warned in
o+yes:)
o+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
o+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
o+ac_tool_warned=yes ;;
o+esac
o+ AR=$ac_ct_AR
o+ fi
o+else
o+ AR="$ac_cv_prog_AR"
o+fi
o+
o+if test "${AR}" = "" ; then
o+ as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
o+fi
o+touch conftest.c
o+${AR} $plugin_option rc conftest.a conftest.c
o+if test "$?" != 0; then
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o+$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o+ plugin_option=
o+fi
o+rm -f conftest.*
o+if test -n "$plugin_option"; then
o+ plugin_option="$plugin_option"
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
o+$as_echo "$plugin_option" >&6; }
o+else
o+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
o+$as_echo "no" >&6; }
o+fi
o+
o+fi
o if test -n "$ac_tool_prefix"; then
o # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
o set dummy ${ac_tool_prefix}ar; ac_word=$2
o@@ -6971,17 +7342,15 @@ fi
o
o test -z "$AR" && AR=ar
o if test -n "$plugin_option"; then
o- if $AR --help 2>&1 | grep -q "\--plugin"; then
o- touch conftest.c
o- $AR $plugin_option rc conftest.a conftest.c
o- if test "$?" != 0; then
o- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
o-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
o- else
o+ case "$AR" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $AR --help 2>&1 | grep -q "\--plugin"; then
o AR="$AR $plugin_option"
o fi
o- rm -f conftest.*
o- fi
o+ ;;
o+ esac
o fi
o test -z "$AR_FLAGS" && AR_FLAGS=cru
o
o@@ -7188,9 +7557,15 @@ fi
o
o test -z "$RANLIB" && RANLIB=:
o if test -n "$plugin_option" && test "$RANLIB" != ":"; then
o- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o- RANLIB="$RANLIB $plugin_option"
o- fi
o+ case "$RANLIB" in
o+ *"$plugin_option"*)
o+ ;;
o+ *)
o+ if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
o+ RANLIB="$RANLIB $plugin_option"
o+ fi
o+ ;;
o+ esac
o fi
o
o
o@@ -12799,7 +13174,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 12802 "configure"
o+#line 13177 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
o@@ -12905,7 +13280,7 @@ else
o lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
o lt_status=$lt_dlunknown
o cat > conftest.$ac_ext <<_LT_EOF
o-#line 12908 "configure"
o+#line 13283 "configure"
o #include "confdefs.h"
o
o #if HAVE_DLFCN_H
hprogram finished with exit code 1
helapsedTime=0.606283
More information about the Binutils
mailing list